freeside/FS/FS cust_svc.pm,1.44,1.45 Conf.pm,1.106,1.107

ivan ivan at pouncequick.420.am
Sun Oct 17 02:19:26 PDT 2004


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory pouncequick:/tmp/cvs-serv21399/FS/FS

Modified Files:
	cust_svc.pm Conf.pm 
Log Message:
add options to adjust UI for artera turbo as svc_export

Index: Conf.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/Conf.pm,v
retrieving revision 1.106
retrieving revision 1.107
diff -u -d -r1.106 -r1.107
--- Conf.pm	16 Oct 2004 10:15:00 -0000	1.106
+++ Conf.pm	17 Oct 2004 09:19:22 -0000	1.107
@@ -1298,6 +1298,14 @@
     'type'        => 'checkbox',
   },
 
+  {
+    'key'         => 'svc_external-display_type',
+    'section'     => 'UI',
+    'description' => 'Select a specific svc_external type to enable some UI changes specific to that type (i.e. artera_turbo).',
+    'type'        => 'select',
+    'select_enum' => [ 'generic', 'artera_turbo', ],
+  },
+
 );
 
 1;

Index: cust_svc.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_svc.pm,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -d -r1.44 -r1.45
--- cust_svc.pm	5 Oct 2004 16:28:28 -0000	1.44
+++ cust_svc.pm	17 Oct 2004 09:19:22 -0000	1.45
@@ -3,6 +3,7 @@
 use strict;
 use vars qw( @ISA $ignore_quantity );
 use Carp qw( cluck );
+use FS::Conf;
 use FS::Record qw( qsearch qsearchs dbh );
 use FS::cust_pkg;
 use FS::part_pkg;
@@ -303,7 +304,12 @@
   } elsif ( $svcdb eq 'svc_broadband' ) {
     $tag = $svc_x->ip_addr;
   } elsif ( $svcdb eq 'svc_external' ) {
-    $tag = $svc_x->id. ': '. $svc_x->title;
+    my $conf = new FS::Conf;
+    if ( $conf->config('svc_external-display_type') eq 'artera_turbo' ) {
+      $tag = sprintf('%010d', $svc_x->id). '-'. $svc_x->title;
+    } else {
+      $tag = $svc_x->id. ': '. $svc_x->title;
+    }
   } else {
     cluck "warning: asked for label of unsupported svcdb; using svcnum";
     $tag = $svc_x->getfield('svcnum');




More information about the freeside-commits mailing list