# if contractnumber exists, it's a modify action, so read values to modify...
if ($contractnumber) {
- my $contract =
- @{ GetContract( { contractnumber => $contractnumber } ) }[0];
+ my $contract = GetContract({
+ contractnumber => $contractnumber
+ });
$template->param(
contractnumber => $contract->{contractnumber},
elsif ( $op eq 'delete_confirm' ) {
$template->param( delete_confirm => 1 );
- my $contract = @{GetContract( { contractnumber => $contractnumber } )}[0];
+ my $contract = GetContract( { contractnumber => $contractnumber } );
$template->param(
contractnumber => $$contract{contractnumber},
$template->param(else => 1);
# get contracts
- my @contracts = @{GetContract( { booksellerid => $booksellerid } )};
+ my @contracts = @{GetContracts( { booksellerid => $booksellerid } )};
# format dates
for ( @contracts ) {