Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 62726dfd

Von Sven Schöling vor mehr als 8 Jahren hinzugefügt

  • ID 62726dfdf4f763efa65c25fcfe8658d98649c8a8
  • Vorgänger b8376fba
  • Nachfolger 12727b13

Drafts: Ausgelagert in Controller

Unterschiede anzeigen:

bin/mozilla/is.pl
49 49

  
50 50
require "bin/mozilla/io.pl";
51 51
require "bin/mozilla/arap.pl";
52
require "bin/mozilla/drafts.pl";
53 52

  
54 53
use strict;
55 54

  
......
65 64

  
66 65
  $main::auth->assert('invoice_edit');
67 66

  
68
  return $main::lxdebug->leave_sub() if (load_draft_maybe());
69

  
70 67
  $form->{show_details} = $::myconfig{show_form_details};
71 68

  
72 69
  if ($form->{type} eq "credit_note") {
......
396 393
  ), @custom_hiddens,
397 394
  map { $_.'_rate', $_.'_description', $_.'_taxnumber' } split / /, $form->{taxaccounts}];
398 395

  
399
  $::request->{layout}->use_javascript(map { "${_}.js" } qw(kivi.SalesPurchase ckeditor/ckeditor ckeditor/adapters/jquery kivi.io autocomplete_customer autocomplete_part client_js));
396
  $::request->{layout}->use_javascript(map { "${_}.js" } qw(kivi.Draft kivi.SalesPurchase ckeditor/ckeditor ckeditor/adapters/jquery kivi.io autocomplete_customer autocomplete_part client_js));
400 397

  
401 398
  $TMPL_VAR{payment_terms_obj} = get_payment_terms_for_invoice();
402 399
  $form->{duedate}             = $TMPL_VAR{payment_terms_obj}->calc_date(reference_date => $form->{invdate}, due_date => $form->{duedate})->to_kivitendo if $TMPL_VAR{payment_terms_obj};
......
863 860
    }
864 861
  }
865 862

  
866
  remove_draft() if $form->{remove_draft};
867

  
868 863
  if(!exists $form->{addition}) {
869 864
    $form->{snumbers}  =  'invnumber' .'_'. $form->{invnumber}; # ($form->{type} eq 'credit_note' ? 'cnnumber' : 'invnumber') .'_'. $form->{invnumber};
870 865
    $form->{what_done} = 'invoice';
......
1127 1122
sub dispatcher {
1128 1123
  for my $action (qw(
1129 1124
    print update ship_to e_mail storno post_payment use_as_new credit_note
1130
    delete post order preview post_and_e_mail print_and_post save_draft
1125
    delete post order preview post_and_e_mail print_and_post
1131 1126
    mark_as_paid
1132 1127
  )) {
1133 1128
    if ($::form->{"action_$action"}) {

Auch abrufbar als: Unified diff