X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fmisc%2Fdelete-quotation_pkg.html;fp=httemplate%2Fmisc%2Fdelete-quotation_pkg.html;h=5a44d37282e5e683b20712ac2d93020276ffc971;hb=b6538b4641f900da4892d8c44292befb71188822;hp=0000000000000000000000000000000000000000;hpb=8fa2d4df960414f50c33f1c0e57a9bab02db517e;p=freeside.git diff --git a/httemplate/misc/delete-quotation_pkg.html b/httemplate/misc/delete-quotation_pkg.html new file mode 100644 index 000000000..5a44d3728 --- /dev/null +++ b/httemplate/misc/delete-quotation_pkg.html @@ -0,0 +1,21 @@ +% if ( $error ) { +% errorpage($error); +% } else { +<% $cgi->redirect($p. "view/quotation.html?". $quotationnum) %> +% } +<%init> + +die "access denied" + unless $FS::CurrentUser::CurrentUser->access_right('Generate quotation'); #separate ACL for editing it later? too silly for us yet + +#untaint quotationpkgnum +my($query) = $cgi->keywords; +$query =~ /^(\d+)$/ or die "Illegal quotationpkgnum"; +my $quotationpkgnum = $1; + +my $quotation_pkg = qsearchs('quotation_pkg',{'quotationpkgnum'=>$quotationpkgnum}); +my $quotationnum = $quotation_pkg->quotationnum; + +my $error = $quotation_pkg->delete; + +