Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision c954dea7

Von Moritz Bunkus vor etwa 8 Jahren hinzugefügt

  • ID c954dea7c1b814d66b8c31d04fa70a1bbbcce71e
  • Vorgänger bbe298f0
  • Nachfolger 105428c5

Entwürfe: beim Buchen dazugehörigen Entwurf löschen

Unterschiede anzeigen:

SL/AP.pm
40 40
use SL::IO;
41 41
use SL::MoreCommon;
42 42
use SL::DB::Default;
43
use SL::DB::Draft;
43 44
use SL::Util qw(trim);
44 45
use SL::DB;
45 46
use Data::Dumper;
......
361 362

  
362 363
  IO->set_datepaid(table => 'ap', id => $form->{id}, dbh => $dbh);
363 364

  
365
  if ($form->{draft_id}) {
366
    SL::DB::Manager::Draft->delete_all(where => [ id => delete($form->{draft_id}) ]);
367
  }
368

  
364 369
  # safety check datev export
365 370
  if ($::instance_conf->get_datev_check_on_ap_transaction) {
366 371
    my $transdate = $::form->{transdate} ? DateTime->from_lxoffice($::form->{transdate}) : undef;
SL/AR.pm
38 38
use Data::Dumper;
39 39
use SL::DATEV qw(:CONSTANTS);
40 40
use SL::DBUtils;
41
use SL::DB::Draft;
41 42
use SL::IO;
42 43
use SL::MoreCommon;
43 44
use SL::DB::Default;
......
305 306

  
306 307
  IO->set_datepaid(table => 'ar', id => $form->{id}, dbh => $dbh);
307 308

  
309
  if ($form->{draft_id}) {
310
    SL::DB::Manager::Draft->delete_all(where => [ id => delete($form->{draft_id}) ]);
311
  }
312

  
308 313
  # safety check datev export
309 314
  if ($::instance_conf->get_datev_check_on_ar_transaction) {
310 315
    my $transdate = $::form->{transdate} ? DateTime->from_lxoffice($::form->{transdate}) : undef;
SL/Controller/Draft.pm
68 68
    $self->js
69 69
      ->flash('info', t8("Draft saved."))
70 70
      ->dialog->close('#save_draft')
71
      ->val('#draft_id', $draft->id)
71 72
      ->render;
72 73
  }
73 74
}
SL/GL.pm
45 45
use SL::DATEV qw(:CONSTANTS);
46 46
use SL::DBUtils;
47 47
use SL::DB::Chart;
48
use SL::DB::Draft;
48 49
use SL::Util qw(trim);
49 50
use SL::DB;
50 51

  
......
190 191
    do_query($form, $dbh, qq|UPDATE gl SET storno = 't' WHERE id = ?|, conv_i($form->{storno_id}));
191 192
  }
192 193

  
194
  if ($form->{draft_id}) {
195
    SL::DB::Manager::Draft->delete_all(where => [ id => delete($form->{draft_id}) ]);
196
  }
197

  
193 198
  # safety check datev export
194 199
  if ($::instance_conf->get_datev_check_on_gl_transaction) {
195 200
    my $transdate = $::form->{transdate} ? DateTime->from_lxoffice($::form->{transdate}) : undef;
SL/IR.pm
41 41
use SL::CVar;
42 42
use SL::DATEV qw(:CONSTANTS);
43 43
use SL::DBUtils;
44
use SL::DB::Draft;
44 45
use SL::DO;
45 46
use SL::GenericTranslations;
46 47
use SL::HTML::Restrict;
......
810 811
    do_query($form, $dbh, $query, @orphaned_ids);
811 812
  }
812 813

  
814
  if ($form->{draft_id}) {
815
    SL::DB::Manager::Draft->delete_all(where => [ id => delete($form->{draft_id}) ]);
816
  }
817

  
813 818
  # safety check datev export
814 819
  if ($::instance_conf->get_datev_check_on_purchase_invoice) {
815 820
    # if we need department for kostenstelle in DATEV check
SL/IS.pm
52 52
use SL::IO;
53 53
use SL::TransNumber;
54 54
use SL::DB::Default;
55
use SL::DB::Draft;
55 56
use SL::DB::Tax;
56 57
use SL::DB::TaxZone;
57 58
use SL::TransNumber;
......
1402 1403
    do_query($form, $dbh, $query, @orphaned_ids);
1403 1404
  }
1404 1405

  
1406
  if ($form->{draft_id}) {
1407
    SL::DB::Manager::Draft->delete_all(where => [ id => delete($form->{draft_id}) ]);
1408
  }
1409

  
1405 1410
  # safety check datev export
1406 1411
  if ($::instance_conf->get_datev_check_on_sales_invoice) {
1407 1412
    my $transdate = $::form->{invdate} ? DateTime->from_lxoffice($::form->{invdate}) : undef;
templates/webpages/ap/form_footer.html
1 1
[%- USE T8 %]
2 2
[%- USE HTML %]
3 3
[%- USE L %]
4
[%- USE LxERP %]
4
[%- USE LxERP %][%- USE P -%]
5 5

  
6 6
[%- IF (num_follow_ups && num_due) %]
7 7
  <p>[% LxERP.t8('There are #1 unfinished follow-ups of which #2 are due.', num_follow_ups, num_due) %]</p>
......
9 9

  
10 10
<input name=callback type=hidden value="[% callback | html %]">
11 11
<input name=gldate type=hidden value="[% gldate | html %]">
12
<input type=hidden name=draft_id value="[% draft_id %]">
13
<input type=hidden name=draft_description value="[% draft_description | html %]">
12
[% P.hidden_tag('draft_id', draft_id) %]
13
[% P.hidden_tag('draft_description', draft_description) %]
14 14

  
15 15
<br>
16 16

  
templates/webpages/ar/form_footer.html
1 1
[% USE LxERP %]
2 2
[% USE T8 %]
3
[% USE L %]
3
[% USE L %][%- USE P -%]
4 4

  
5 5
  [% IF ( follow_up_length && follow_up_due_length ) %]
6 6
    [% LxERP.t8('There are #1 unfinished follow-ups of which #2 are due.', follow_up_length , follow_up_due_length) %]
......
8 8

  
9 9
  <input type="hidden" name="gldate" value="[% gldate | html %]">
10 10
  <input type="hidden" name="callback" value="[% callback | html %]">
11
  <input type="hidden" name="draft_id" value="[% draft_id | html %]">
12
  <input type="hidden" name="draft_description" value="[% draft_description | html %]">
11
  [% P.hidden_tag('draft_id', draft_id) %]
12
  [% P.hidden_tag('draft_description', draft_description) %]
13 13

  
14 14
  <br>
15 15

  
templates/webpages/ir/form_footer.html
1 1
[%- USE T8 %]
2 2
[%- USE HTML %]
3 3
[%- USE LxERP %]
4
[%- USE L %]
4
[%- USE L %][%- USE P -%]
5 5
  <tr>
6 6
   <td>
7 7
    <table width="100%">
......
152 152

  
153 153
<input type="hidden" name="rowcount" value="[% rowcount %]">
154 154
<input type="hidden" name="callback" value="[% callback %]">
155
<input type="hidden" name="draft_id" value="[% draft_id %]">
156
<input type="hidden" name="draft_description" value="[% draft_description %]">
155
[% P.hidden_tag('draft_id', draft_id) %]
156
[% P.hidden_tag('draft_description', draft_description) %]
157 157
<input type="hidden" name="vendor_discount" value="[% vendor_discount %]">
158 158

  
159 159
</form>
templates/webpages/is/form_footer.html
201 201

  
202 202
<input type="hidden" name="rowcount" value="[% rowcount %]">
203 203
<input type="hidden" name="callback" value="[% callback | html %]">
204
<input type="hidden" name="draft_id" value="[% draft_id %]">
205
<input type="hidden" name="draft_description" value="[% draft_description %]">
204
[% P.hidden_tag('draft_id', draft_id) %]
205
[% P.hidden_tag('draft_description', draft_description) %]
206 206
<input type="hidden" name="customer_discount" value="[% customer_discount %]">
207 207
<input type="hidden" name="gldate" value="[% gldate %]">
208 208
</form>

Auch abrufbar als: Unified diff