3 <FONT COLOR="#ff0000"><B><% $error |h %></B></FONT><BR><BR>
4 <CENTER><INPUT TYPE="BUTTON" VALUE="OK" onClick="parent.cClick()"></CENTER>
8 <SCRIPT TYPE="text/javascript">
9 window.top.location.reload();
15 my $curuser = $FS::CurrentUser::CurrentUser;
18 unless $curuser->access_right('Generate quotation');
20 $cgi->param('pkgnum') =~ /^(\d+)$/ or die 'illegal pkgnum';
23 my $quotation_pkg = qsearchs({
24 'table' => 'quotation_pkg',
25 'addl_from' => 'LEFT JOIN quotation USING ( quotationnum )'.
26 'LEFT JOIN cust_main USING ( custnum )',
27 'hashref' => { 'quotationpkgnum' => $pkgnum },
28 'extra_sql' => ' AND '. $curuser->agentnums_sql,
31 my @orig_details = $quotation_pkg->details();
33 my $action = 'Quotation details'.
34 ( scalar(@orig_details) ? ' changed ' : ' added ' );
36 my $param = $cgi->Vars;
38 for ( my $row = 0; exists($param->{"detail$row"}); $row++ ) {
39 push @details, $param->{"detail$row"}
40 if $param->{"detail$row"} =~ /\S/;
43 my $error = $quotation_pkg->set_details(@details);