projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
51f4026
)
packages and recurdates for impending_recur templates
author
mark
<mark>
Wed, 1 Sep 2010 18:44:15 +0000
(18:44 +0000)
committer
mark
<mark>
Wed, 1 Sep 2010 18:44:15 +0000
(18:44 +0000)
FS/FS/Cron/notify.pm
patch
|
blob
|
history
FS/FS/msg_template.pm
patch
|
blob
|
history
diff --git
a/FS/FS/Cron/notify.pm
b/FS/FS/Cron/notify.pm
index
ece96fc
..
dcc7b30
100644
(file)
--- a/
FS/FS/Cron/notify.pm
+++ b/
FS/FS/Cron/notify.pm
@@
-4,7
+4,7
@@
use strict;
use vars qw( @ISA @EXPORT_OK $DEBUG );
use Exporter;
use FS::UID qw( dbh driver_name );
use vars qw( @ISA @EXPORT_OK $DEBUG );
use Exporter;
use FS::UID qw( dbh driver_name );
-use FS::Record qw(qsearch);
+use FS::Record qw(qsearch
qsearchs
);
use FS::cust_main;
use FS::cust_pkg;
use FS::cust_main;
use FS::cust_pkg;
@@
-106,6
+106,8
@@
END
my $msgnum = $conf->config('impending_recur_msgnum',$cust_main->agentnum);
if ( $msgnum ) {
my $msg_template = qsearchs('msg_template', { msgnum => $msgnum });
my $msgnum = $conf->config('impending_recur_msgnum',$cust_main->agentnum);
if ( $msgnum ) {
my $msg_template = qsearchs('msg_template', { msgnum => $msgnum });
+ $cust_main->setfield('packages', \\@packages);
+ $cust_main->setfield('recurdates', \\@recurdates);
$error = $msg_template->send('cust_main' => $cust_main);
}
else {
$error = $msg_template->send('cust_main' => $cust_main);
}
else {
diff --git
a/FS/FS/msg_template.pm
b/FS/FS/msg_template.pm
index
071a3c4
..
50298d2
100644
(file)
--- a/
FS/FS/msg_template.pm
+++ b/
FS/FS/msg_template.pm
@@
-316,6
+316,7
@@
sub substitutions {
signupdate dundate
expdate
signupdate dundate
expdate
+ packages recurdates
),
# expdate is a special case
[ signupdate_ymd => sub { time2str('%Y-%m-%d', shift->signupdate) } ],
),
# expdate is a special case
[ signupdate_ymd => sub { time2str('%Y-%m-%d', shift->signupdate) } ],