[freeside-commits] freeside/FS/FS/part_event Action.pm, 1.6, 1.7 Condition.pm, 1.12, 1.13
Mark Wells
mark at wavetail.420.am
Wed Aug 31 22:13:11 PDT 2011
Update of /home/cvs/cvsroot/freeside/FS/FS/part_event
In directory wavetail.420.am:/tmp/cvs-serv1936/FS/FS/part_event
Modified Files:
Action.pm Condition.pm
Log Message:
svc_acct events for usage limits, #13202
Index: Action.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_event/Action.pm,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -w -d -r1.6 -r1.7
--- Action.pm 29 Aug 2011 20:50:33 -0000 1.6
+++ Action.pm 1 Sep 2011 05:13:08 -0000 1.7
@@ -192,6 +192,21 @@
}
+=item cust_pkg OBJECT
+
+Return the package object (L<FS::cust_pkg>) associated with the provided
+object. The object must be either a service (L<FS::svc_Common>) or a
+package.
+
+=cut
+
+sub cust_pkg {
+ my( $self, $object ) = @_;
+ $object->isa('FS::cust_pkg') ? $object :
+ $object->isa('FS::svc_Common') ? $object->cust_svc->cust_pkg :
+ undef;
+}
+
=item option_label OPTIONNAME
Returns the label for the specified option name.
Index: Condition.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_event/Condition.pm,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -w -d -r1.12 -r1.13
--- Condition.pm 29 Aug 2011 20:50:33 -0000 1.12
+++ Condition.pm 1 Sep 2011 05:13:08 -0000 1.13
@@ -235,6 +235,21 @@
}
+=item cust_pkg OBJECT
+
+Return the package object (L<FS::cust_pkg>) associated with the provided
+object. The object must be either a service (L<FS::svc_Common>) or a
+package.
+
+=cut
+
+sub cust_pkg {
+ my( $self, $object ) = @_;
+ $object->isa('FS::cust_pkg') ? $object :
+ $object->isa('FS::svc_Common') ? $object->cust_svc->cust_pkg :
+ undef;
+}
+
=item option_label OPTIONNAME
Returns the label for the specified option name.
More information about the freeside-commits
mailing list