agent-virtualize credit card surcharge percentage, RT#72961
[freeside.git] / FS / FS / part_export / router.pm
index 42aa51c..eee7a4e 100644 (file)
@@ -87,6 +87,7 @@ tie my %options, 'Tie::IxHash',
   'svc'     => 'svc_broadband',
   'desc'    => 'Send a command to a router.',
   'options' => \%options,
+  'no_machine' => 1,
   'notes'   => 'Installation of Net::Telnet from CPAN is required for telnet connections.  This export will execute if the following virtual fields are set on the router: admin_user, admin_password, admin_address, admin_timeout, admin_prompt.  Option virtual fields are: admin_cmd_insert, admin_cmd_replace, admin_cmd_delete, admin_cmd_suspend, admin_cmd_unsuspend.  See the module documentation for a full list of required/supported router virtual fields.',
 );
 
@@ -96,7 +97,7 @@ $DEBUG = 1;
 
 sub rebless { shift; }
 
-sub _field_prefix { 'admin'; }
+sub _field_prefix { 'cf_admin'; }
 
 sub _req_router_fields {
   map {
@@ -302,13 +303,13 @@ sub _queue {
 }
 
 sub _get_router {
-  my ($self, $svc_broadband, %args) = (shift, shift, shift, @_);
+  my ($self, $svc_broadband, %args) = (shift, shift, @_);
 
   my $router;
   if ($args{'routernum'}) {
     $router = qsearchs('router', { routernum => $args{'routernum'}});
   } else {
-    $router = $svc_broadband->addr_block->router;
+    $router = $svc_broadband->router;
   }
 
   return($router);