X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Femail-link.html;h=16935cf985cd985d009617ee025e72126fc50550;hb=a181b24a0050bfca2ec220421f4cbc347533119f;hp=692e5bc2e8aa32b687c2c9f4039417a5d99fb686;hpb=0fb307c305e4bc2c9c27dc25a3308beae3a4d33c;p=freeside.git
diff --git a/httemplate/elements/email-link.html b/httemplate/elements/email-link.html
index 692e5bc2e..16935cf98 100644
--- a/httemplate/elements/email-link.html
+++ b/httemplate/elements/email-link.html
@@ -1,15 +1,17 @@
% if ( $FS::CurrentUser::CurrentUser->access_right('Bulk send customer notices') ) {
-<%$label%>
+<%$label%>
% }
<%init>
my %opt = @_;
my $table = $opt{'table'};
+my $agent_virt_agentnum = $opt{'agent_virt_agentnum'};
my $search_hash = $opt{'search_hash'};
die "'table' required" if !$table;
die "'search_hash' required" if !$search_hash;
my $uri = new URI;
-$uri->query_form($search_hash);
+my @params = map { $_, $search_hash->{$_} } sort keys %$search_hash;
+$uri->query_form(@params);
my $query = $uri->query;
my $label = ($opt{'label'} || 'Email a notice to these customers');
%init>