[freeside-commits] freeside/FS/FS cust_svc.pm, 1.71, 1.72 part_export.pm, 1.100, 1.101 svc_Common.pm, 1.42, 1.43

Jeff Finucane,420,, jeff at wavetail.420.am
Wed Mar 12 09:24:35 PDT 2008


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv2819/FS/FS

Modified Files:
	cust_svc.pm part_export.pm svc_Common.pm 
Log Message:
allow exports to add links to customer view (#1407)

Index: svc_Common.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/svc_Common.pm,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- svc_Common.pm	1 Aug 2007 22:24:37 -0000	1.42
+++ svc_Common.pm	12 Mar 2008 16:24:33 -0000	1.43
@@ -708,6 +708,19 @@
   $self->export('unsuspend', @$export_args);
 }
 
+=item export_links
+
+Runs export_links callbacks and returns the links.
+
+=cut
+
+sub export_links {
+  my $self = shift;
+  my $return = [];
+  $self->export('links', $return);
+  $return;
+}
+
 =item export HOOK [ EXPORT_ARGS ]
 
 Runs the provided export hook (i.e. "suspend", "unsuspend") for this service.

Index: part_export.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_export.pm,v
retrieving revision 1.100
retrieving revision 1.101
diff -u -d -r1.100 -r1.101
--- part_export.pm	29 Dec 2006 08:24:21 -0000	1.100
+++ part_export.pm	12 Mar 2008 16:24:33 -0000	1.101
@@ -359,6 +359,14 @@
   $self->_export_replace( $svc_x, $old );
 }
 
+=item export_links SVC_OBJECT ARRAYREF
+
+Adds a list of web elements to ARRAYREF specific to this export and SVC_OBJECT.
+The elements are displayed in the UI to lead the the operator to external
+configuration, monitoring, and similar tools.
+
+=cut
+
 =back
 
 =head1 SUBROUTINES

Index: cust_svc.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_svc.pm,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -d -r1.71 -r1.72
--- cust_svc.pm	11 Feb 2008 02:36:53 -0000	1.71
+++ cust_svc.pm	12 Mar 2008 16:24:33 -0000	1.72
@@ -392,6 +392,20 @@
 
 }
 
+=item export_links
+
+Returns a list of html elements associated with this services exports.
+
+=cut
+
+sub export_links {
+  my $self = shift;
+  my $svc_x = $self->svc_x
+    or return "can't find ". $self->part_svc->svcdb. '.svcnum '. $self->svcnum;
+
+  $svc_x->export_links;
+}
+
 =item svc_x
 
 Returns the FS::svc_XXX object for this service (i.e. an FS::svc_acct object or



More information about the freeside-commits mailing list