[freeside-commits] branch master updated. f417eee294482e6a7bc4ad60c916b84ffd662112
Ivan
ivan at 420.am
Tue Sep 10 21:25:14 PDT 2013
The branch, master has been updated
via f417eee294482e6a7bc4ad60c916b84ffd662112 (commit)
from 42cb05f8b363d8f56ff620256adcaf1a4f15046f (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 f417eee294482e6a7bc4ad60c916b84ffd662112
Author: Ivan Kohler <ivan at freeside.biz>
Date: Tue Sep 10 21:25:12 2013 -0700
fix order package UI layout when there aren't any sales people for an agent, RT#24955
diff --git a/httemplate/elements/tr-select-sales.html b/httemplate/elements/tr-select-sales.html
index c29e0d7..956a9d1 100644
--- a/httemplate/elements/tr-select-sales.html
+++ b/httemplate/elements/tr-select-sales.html
@@ -155,8 +155,11 @@ my $salesnum = $opt{'curr_value'} || $opt{'value'};
my $field = $opt{'element_name'} || $opt{'field'} || 'salesnum';
my $id = $opt{'id'} || $opt{'field'} || 'salesnum';
-my @sales = qsearch({ 'table' => 'sales',
- 'hashref' => { 'disabled' => '' },
+my $hashref = { disabled => '' };
+$hashref->{agentnum} = $opt{agentnum} if $opt{agentnum};
+
+my @sales = qsearch({ 'table' => 'sales',
+ 'hashref' => $hashref,
'extra_sql' => ' AND '. $curuser->agentnums_sql,
'order_by' => 'ORDER BY salesperson',
});
diff --git a/httemplate/misc/order_pkg.html b/httemplate/misc/order_pkg.html
index febe427..03531bf 100644
--- a/httemplate/misc/order_pkg.html
+++ b/httemplate/misc/order_pkg.html
@@ -38,7 +38,8 @@
<& /elements/tr-select-sales.html,
'curr_value' => scalar($cgi->param('salesnum')),
- 'th' => 1,
+ 'agentnum' => $agent->agentnum,
+ 'th' => 1,
&>
% if ( $conf->exists('pkg_referral') ) {
-----------------------------------------------------------------------
Summary of changes:
httemplate/elements/tr-select-sales.html | 7 +++++--
httemplate/misc/order_pkg.html | 3 ++-
2 files changed, 7 insertions(+), 3 deletions(-)
More information about the freeside-commits
mailing list