diff options
author | Ivan Kohler <ivan@freeside.biz> | 2014-06-02 17:01:20 -0700 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2014-06-02 17:01:20 -0700 |
commit | 31272b420c6206e82ce8b622fd14bf469fe1e126 (patch) | |
tree | 53560a7c5cba6736342f6d2e77c9923259b86ed7 /httemplate/view/elements | |
parent | ba46a6a90321490da78c764657ae19d5c6fd81f8 (diff) |
show MAC address vendors
Notes
Notes:
RT#29346
Diffstat (limited to 'httemplate/view/elements')
-rw-r--r-- | httemplate/view/elements/svc_Common.html | 11 | ||||
-rw-r--r-- | httemplate/view/elements/svc_devices.html | 4 |
2 files changed, 11 insertions, 4 deletions
diff --git a/httemplate/view/elements/svc_Common.html b/httemplate/view/elements/svc_Common.html index 65f373cb6..b12d2ddcd 100644 --- a/httemplate/view/elements/svc_Common.html +++ b/httemplate/view/elements/svc_Common.html @@ -105,9 +105,14 @@ function areyousure(href) { %> </TD> -% $value = time2str($date_format,$value) if ( $type eq 'date' && $value ); -% $value = time2str("$date_format %H:%M",$value) if ( $type eq 'datetime' && $value ); -% $value = $value eq 'Y' ? emt('Yes') : emt('No') if ( $type eq 'checkbox' ); +% $value = time2str($date_format,$value) +% if $type eq 'date' && $value; +% $value = time2str("$date_format %H:%M",$value) +% if $type eq 'datetime' && $value; +% $value = $value eq 'Y' ? emt('Yes') : emt('No') +% if $type eq 'checkbox'; +% $value .= ' ('. (Net::MAC::Vendor::lookup($value))->[0]. ')' +% if $type =~ /mac_addr$/ && $value =~ /\w/i; % #eventually more options for <SELECT>, etc. fields <TD BGCOLOR="#ffffff"><% $value %><TD> diff --git a/httemplate/view/elements/svc_devices.html b/httemplate/view/elements/svc_devices.html index c9f5eda78..899e6aa47 100644 --- a/httemplate/view/elements/svc_devices.html +++ b/httemplate/view/elements/svc_devices.html @@ -62,7 +62,9 @@ % if ( $table eq 'phone_device' || $svc_x->isa('FS::device_Common') ) { <% $td %><% $device->part_device->devicename |h %></TD> % } - <% $td %><% $device->mac_addr_pretty %></TD> + <% $td %><% $device->mac_addr_pretty %> + (<% (Net::MAC::Vendor::lookup($device->mac_addr_formatted('U',':')))->[0] %>) + </TD> <% $td %><% $export_links %></TD> <% $td %>( % unless ( $opt{'no_edit'} ) { |