X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fpart_event%2FAction.pm;h=c0c70b1c3d1f72bb81346a162953ee0530cc19a1;hb=389b6f1116c3309c2ee57a6c295ed1a793503095;hp=45219a3215d5c2b5f79544ddefcec87fecf99d31;hpb=63a268637b2d51a8766412617724b9436439deb6;p=freeside.git diff --git a/FS/FS/part_event/Action.pm b/FS/FS/part_event/Action.pm index 45219a321..c0c70b1c3 100644 --- a/FS/FS/part_event/Action.pm +++ b/FS/FS/part_event/Action.pm @@ -51,6 +51,7 @@ sub eventtable_hashref { 'cust_bill' => 1, 'cust_pkg' => 1, 'cust_pay_batch' => 1, + 'svc_acct' => 1, }; } @@ -191,6 +192,21 @@ sub cust_main { } +=item cust_pkg OBJECT + +Return the package object (L) associated with the provided +object. The object must be either a service (L) 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.