diff options
| author | Mark Wells <mark@freeside.biz> | 2013-04-25 16:15:38 -0700 |
|---|---|---|
| committer | Mark Wells <mark@freeside.biz> | 2013-04-25 16:15:38 -0700 |
| commit | 5c619fec0cb5d8adbce182d91c7c6a22d6725bcf (patch) | |
| tree | ab121642d4247091d664da6562fd4dced51162b5 /httemplate/edit/process | |
| parent | bf6644780bf1036f5eca4d191caf7c141447dd47 (diff) | |
billing event "initialize" feature for 2.3, #22766
Diffstat (limited to 'httemplate/edit/process')
| -rw-r--r-- | httemplate/edit/process/part_event.html | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/httemplate/edit/process/part_event.html b/httemplate/edit/process/part_event.html index 20066ba05..a8c434c1a 100644 --- a/httemplate/edit/process/part_event.html +++ b/httemplate/edit/process/part_event.html @@ -82,8 +82,21 @@ length($actionfields{'reasonnum'}) == 0 ) { return 'Reason required'; } + if ( $cgi->param('_initialize') ) { + $cgi->param('disabled', 'Y'); + } return ''; }, + 'noerror_callback' => sub { + my ($cgi, $new) = @_; + if ( $cgi->param('_initialize') ) { + my $job = new FS::queue { + 'job' => 'FS::part_event::process_initialize' + }; + my $error = $job->insert('eventpart' => $new->eventpart); + warn "error queueing job: $error\n" if $error; # can't do anything else + } + }, 'agent_virt' => 1, 'agent_null_right' => 'Edit global billing events', |
