X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fsvc_hardware.pm;h=dbb8b68293560d063916882c9655169215d4a023;hb=db5785cba180e2c210d3ab4d37064c7e61898614;hp=dc9ac59dfc07ea37b7dff3a125d6bbad77b9bc07;hpb=32072dbf59a054529f5304574c0f56f9567d14d0;p=freeside.git diff --git a/FS/FS/svc_hardware.pm b/FS/FS/svc_hardware.pm index dc9ac59df..dbb8b6829 100644 --- a/FS/FS/svc_hardware.pm +++ b/FS/FS/svc_hardware.pm @@ -75,6 +75,7 @@ sub table_info { 'name_plural' => 'Hardware', 'display_weight' => 59, 'cancel_weight' => 86, + 'manual_require' => 1, 'fields' => { 'svcnum' => { label => 'Service' }, 'typenum' => { label => 'Device type', @@ -83,6 +84,7 @@ sub table_info { disable_fixed => 1, disable_default => 1, disable_inventory => 1, + required => 1, }, 'serial' => { label => 'Serial number', %opts }, 'hw_addr' => { label => 'Hardware address', %opts }, @@ -132,7 +134,17 @@ sub search_sql { sub label { my $self = shift; - $self->serial || $self->display_hw_addr; + my @label = (); + if (my $type = $self->hardware_type) { + push @label, 'Type:' . $type->description; + } + if (my $ser = $self->serial) { + push @label, 'Serial#' . $ser; + } + if (my $mac = $self->display_hw_addr) { + push @label, 'MAC:'. $mac; + } + return join(', ', @label); } =item insert