diff options
author | ivan <ivan> | 2002-05-22 18:44:01 +0000 |
---|---|---|
committer | ivan <ivan> | 2002-05-22 18:44:01 +0000 |
commit | 23186f0338ec248d930c85db08cc997bca42525b (patch) | |
tree | 0f913dcdf0b10d662baf90947d44cd4ac43584c2 /httemplate/edit/process/domain_record.cgi | |
parent | a55f1c9e63b5428c55aa75d55ab4a280889be288 (diff) |
bind export, editing zones, deleting unaudited domains, mmm
Diffstat (limited to 'httemplate/edit/process/domain_record.cgi')
-rwxr-xr-x | httemplate/edit/process/domain_record.cgi | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/httemplate/edit/process/domain_record.cgi b/httemplate/edit/process/domain_record.cgi new file mode 100755 index 000000000..8fb0368f6 --- /dev/null +++ b/httemplate/edit/process/domain_record.cgi @@ -0,0 +1,31 @@ +<% + +my $recnum = $cgi->param('recnum'); + +my $old = qsearchs('agent',{'recnum'=>$recnum}) if $recnum; + +my $new = new FS::domain_record ( { + map { + $_, scalar($cgi->param($_)); + } fields('domain_record') +} ); + +my $error; +if ( $recnum ) { + $error=$new->replace($old); +} else { + $error=$new->insert; + $recnum=$new->getfield('recnum'); +} + +if ( $error ) { +# $cgi->param('error', $error); +# print $cgi->redirect(popurl(2). "agent.cgi?". $cgi->query_string ); + #no edit screen to send them back to + eidiot($error); +} else { + my $svcnum = $new->svcnum; + print $cgi->redirect(popurl(3). "view/svc_domain.cgi?$svcnum"); +} + +%> |