[freeside-commits] branch FREESIDE_3_BRANCH updated. 9ae9c1bf422f012cdc5c19255ec4593ea7e83163
Ivan
ivan at 420.am
Wed Nov 12 20:50:41 PST 2014
The branch, FREESIDE_3_BRANCH has been updated
via 9ae9c1bf422f012cdc5c19255ec4593ea7e83163 (commit)
from 634ed17b567157fff0b106dc2c08ed48a066eee0 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 9ae9c1bf422f012cdc5c19255ec4593ea7e83163
Author: Ivan Kohler <ivan at freeside.biz>
Date: Wed Nov 12 20:50:17 2014 -0800
add option to credit customer sales person if there is no package sales person to amount based on referred package action, RT#24086
diff --git a/FS/FS/part_event/Action/Mixin/credit_sales_pkg_class.pm b/FS/FS/part_event/Action/Mixin/credit_sales_pkg_class.pm
index fc7a3e3..5c090ef 100644
--- a/FS/FS/part_event/Action/Mixin/credit_sales_pkg_class.pm
+++ b/FS/FS/part_event/Action/Mixin/credit_sales_pkg_class.pm
@@ -11,12 +11,6 @@ sub option_fields {
delete $option_fields{'percent'};
- $option_fields{'cust_main_sales'} = {
- 'label' => "Credit the customer sales person if there is no package sales person",
- 'type' => 'checkbox',
- 'value' => 'Y',
- };
-
%option_fields;
}
diff --git a/FS/FS/part_event/Action/Mixin/pkg_sales_credit.pm b/FS/FS/part_event/Action/Mixin/pkg_sales_credit.pm
new file mode 100644
index 0000000..9e93397
--- /dev/null
+++ b/FS/FS/part_event/Action/Mixin/pkg_sales_credit.pm
@@ -0,0 +1,19 @@
+package FS::part_event::Action::Mixin::pkg_sales_credit;
+
+use strict;
+use NEXT;
+
+sub option_fields {
+ my $class = shift;
+ my %option_fields = $class->NEXT::option_fields;
+
+ $option_fields{'cust_main_sales'} = {
+ 'label' => "Credit the customer sales person if there is no package sales person",
+ 'type' => 'checkbox',
+ 'value' => 'Y',
+ };
+
+ %option_fields;
+}
+
+1;
diff --git a/FS/FS/part_event/Action/pkg_sales_credit.pm b/FS/FS/part_event/Action/pkg_sales_credit.pm
index cca123a..e7551cd 100644
--- a/FS/FS/part_event/Action/pkg_sales_credit.pm
+++ b/FS/FS/part_event/Action/pkg_sales_credit.pm
@@ -1,7 +1,8 @@
package FS::part_event::Action::pkg_sales_credit;
+use base qw( FS::part_event::Action::Mixin::pkg_sales_credit
+ FS::part_event::Action::pkg_referral_credit );
use strict;
-use base qw( FS::part_event::Action::pkg_referral_credit );
sub description { 'Credit the sales person a specific amount'; }
diff --git a/FS/FS/part_event/Action/pkg_sales_credit_pkg.pm b/FS/FS/part_event/Action/pkg_sales_credit_pkg.pm
index 1e3c2b3..9b13cd8 100644
--- a/FS/FS/part_event/Action/pkg_sales_credit_pkg.pm
+++ b/FS/FS/part_event/Action/pkg_sales_credit_pkg.pm
@@ -1,7 +1,6 @@
package FS::part_event::Action::pkg_sales_credit_pkg;
-
-use strict;
-use base qw( FS::part_event::Action::Mixin::credit_pkg
+use base qw( FS::part_event::Action::Mixin::pkg_sales_credit
+ FS::part_event::Action::Mixin::credit_pkg
FS::part_event::Action::pkg_sales_credit );
sub description { 'Credit the package sales person an amount based on the referred package'; }
diff --git a/FS/FS/part_event/Action/pkg_sales_credit_pkg_class.pm b/FS/FS/part_event/Action/pkg_sales_credit_pkg_class.pm
index 600985b..c69c004 100644
--- a/FS/FS/part_event/Action/pkg_sales_credit_pkg_class.pm
+++ b/FS/FS/part_event/Action/pkg_sales_credit_pkg_class.pm
@@ -1,7 +1,7 @@
package FS::part_event::Action::pkg_sales_credit_pkg_class;
-use strict;
-use base qw( FS::part_event::Action::Mixin::credit_sales_pkg_class
+use base qw( FS::part_event::Action::Mixin::pkg_sales_credit
+ FS::part_event::Action::Mixin::credit_sales_pkg_class
FS::part_event::Action::pkg_sales_credit );
sub description { "Credit the package sales person an amount based on their commission percentage for the package's class"; }
-----------------------------------------------------------------------
Summary of changes:
.../Action/Mixin/credit_sales_pkg_class.pm | 6 ------
FS/FS/part_event/Action/Mixin/pkg_sales_credit.pm | 19 +++++++++++++++++++
FS/FS/part_event/Action/pkg_sales_credit.pm | 3 ++-
FS/FS/part_event/Action/pkg_sales_credit_pkg.pm | 5 ++---
.../part_event/Action/pkg_sales_credit_pkg_class.pm | 4 ++--
5 files changed, 25 insertions(+), 12 deletions(-)
create mode 100644 FS/FS/part_event/Action/Mixin/pkg_sales_credit.pm
More information about the freeside-commits
mailing list