X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Far.pl;h=af47235a933f49ecc395998042a480781e280d9e;hb=15f549fdb43fba2d99817c659533dfa02638bf27;hp=1e5aa98f26379b2dfee3846d90f97ad23c5cd842;hpb=590f737f0418ac7672e22efdf424265bf970f2c7;p=kivitendo-erp.git diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl index 1e5aa98f2..af47235a9 100644 --- a/bin/mozilla/ar.pl +++ b/bin/mozilla/ar.pl @@ -38,6 +38,7 @@ use Data::Dumper; require "$form->{path}/arap.pl"; require "bin/mozilla/common.pl"; +require "bin/mozilla/drafts.pl"; 1; @@ -73,7 +74,9 @@ require "bin/mozilla/common.pl"; sub add { $lxdebug->enter_sub(); - + + return $lxdebug->leave_sub() if (load_draft_maybe()); + # saving the history if(!exists $form->{addition} && ($form->{id} ne "")) { $form->{addition} = "ADDED"; @@ -494,6 +497,8 @@ sub form_header { {locked}> +| . ($form->{saved_message} ? qq|

$form->{saved_message}

| : "") . qq| + @@ -789,6 +794,10 @@ sub form_footer { {path}> {login}> {password}> +| +. $cgi->hidden('-name' => 'draft_id', '-default' => [$form->{draft_id}]) +. $cgi->hidden('-name' => 'draft_description', '-default' => [$form->{draft_description}]) +. qq|
|; @@ -822,7 +831,9 @@ sub form_footer { } else { if ($transdate > $closedto) { print qq||; + . $locale->text('Post') . qq|"> | . + NTI($cgi->submit('-name' => 'action', '-value' => $locale->text('Save draft'), + '-class' => 'submit')); } } @@ -1049,6 +1060,7 @@ sub post { $form->save_history($form->dbconnect(\%myconfig)); } # /saving the history + remove_draft(); $form->redirect($locale->text('Transaction posted!')); } $form->error($locale->text('Cannot post transaction!'));
$form->{title}