diff options
| author | Mike Robinson <miker@freeside.biz> | 2012-05-01 12:40:56 -0500 |
|---|---|---|
| committer | Mike Robinson <miker@freeside.biz> | 2012-05-01 12:40:56 -0500 |
| commit | 7abae1137cfd0830f108cd65fff01370c42e3028 (patch) | |
| tree | aae1a94f3f14acde02b9f7e2b155c86e9365cae7 /httemplate/edit/process | |
| parent | 6487b344f2d3944d2ce6b185556516887836d3b9 (diff) | |
17528 Backdate payment access right.
Diffstat (limited to 'httemplate/edit/process')
| -rwxr-xr-x | httemplate/edit/process/cust_pay.cgi | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/httemplate/edit/process/cust_pay.cgi b/httemplate/edit/process/cust_pay.cgi index 06f5e64d5..8664883c1 100755 --- a/httemplate/edit/process/cust_pay.cgi +++ b/httemplate/edit/process/cust_pay.cgi @@ -39,7 +39,13 @@ $cgi->param('link') =~ /^(custnum|invnum|popup)$/ my $field = my $link = $1; $field = 'custnum' if $field eq 'popup'; -my $_date = parse_datetime($cgi->param('_date')); +my $_date; +if ( $FS::CurrentUser::CurrentUser->access_right(['Backdate payment']) ) { + $_date = parse_datetime($cgi->param('_date')); +} +else { + $_date = time; +} my $new = new FS::cust_pay ( { $field => $linknum, |
