Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 382e874c

Von Sven Schöling vor etwa 14 Jahren hinzugefügt

  • ID 382e874cd5a9ffcf41643b2b8b3b34d1f4737421
  • Vorgänger fd574abb
  • Nachfolger 8e009de4

Globale Variablen entfernt/umgewandelt.

Conflicts:

bin/mozilla/is.pl

Unterschiede anzeigen:

bin/mozilla/is.pl
45 45

  
46 46
use strict;
47 47

  
48
my $edit;
49
my $print_post;
50

  
51 48
1;
52 49

  
53 50
# end of main
......
719 716

  
720 717
  if(!exists $form->{addition}) {
721 718
    $form->{snumbers} = qq|invnumber_| . $form->{invnumber};
722
    $form->{addition} = $print_post     ? "PRINTED AND POSTED" :
723
                        $form->{storno} ? "STORNO"             :
724
                                          "POSTED";
719
    $form->{addition} = $form->{print_and_post} ? "PRINTED AND POSTED" :
720
                        $form->{storno}         ? "STORNO"             :
721
                                                  "POSTED";
725 722
    $form->save_history($form->dbconnect(\%myconfig));
726 723
  }
727 724

  
728
  $form->redirect( $form->{label} . " $form->{invnumber} " . $locale->text('posted!'))
729
    unless $print_post;
725
  # macnetix: after invoice->Post, redirect to edit.
726
  if (!$form->{no_redirect_after_post}) {
727
    $form->{action} = 'edit';
728
    $form->{script} = 'is.pl';
729
    $form->{saved_message} = $form->{label} . " $form->{invnumber} " . $locale->text('posted!');
730
    $form->{callback} = build_std_url(qw(action edit id saved_message));
731
    $form->redirect;
732
  }
730 733

  
731 734
  $main::lxdebug->leave_sub();
732 735
}
......
738 741

  
739 742
  $main::auth->assert('invoice_edit');
740 743

  
741
  my $old_form               = new Form;
742
  $print_post             = 1;
743
  $form->{print_and_post} = 1;
744
  my $old_form                    = new Form;
745
  $form->{no_redirect_after_post} = 1;
746
  $form->{print_and_post}         = 1;
744 747
  &post();
745 748

  
746 749
  &edit();
......
958 961
  $main::auth->assert('invoice_edit');
959 962

  
960 963
  if (!$form->{id}) {
961
    $print_post = 1;
964
    $form->{no_redirect_after_post} = 1;
962 965

  
963 966
    my $saved_form = save_form();
964 967

  

Auch abrufbar als: Unified diff