Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 45073f4d

Von Tamino Steinert vor 11 Monaten hinzugefügt

  • ID 45073f4d6742b8fc9399e3eabf5259cbff71536f
  • Vorgänger 4d32ba10
  • Nachfolger 05d7e914

Belegvorlagen + Dialogbuchung: Workflow von EmailJournal aus umgesetzt

Unterschiede anzeigen:

bin/mozilla/gl.pl
44 44
use SL::DB::BankTransactionAccTrans;
45 45
use SL::DB::Tax;
46 46
use SL::DB::ValidityToken;
47
use SL::DB::GLTransaction;
47 48
use SL::FU;
48 49
use SL::GL;
49 50
use SL::Helper::Flash qw(flash flash_later);
......
252 253

  
253 254
}
254 255

  
256
sub add_from_email_journal {
257
  die "No 'email_journal_id' was given." unless ($::form->{email_journal_id});
258
  &add;
259
}
260

  
261
sub load_record_template_from_email_journal {
262
  die "No 'email_journal_id' was given." unless ($::form->{email_journal_id});
263
  &load_record_template;
264
}
265

  
266
sub edit_with_email_journal_workflow {
267
  my ($self) = @_;
268
  die "No 'email_journal_id' was given." unless ($::form->{email_journal_id});
269
  $::form->{workflow_email_journal_id}    = delete $::form->{email_journal_id};
270
  $::form->{workflow_email_attachment_id} = delete $::form->{email_attachment_id};
271

  
272
  &edit;
273
}
274

  
255 275
sub prepare_transaction {
256 276
  $main::lxdebug->enter_sub();
257 277

  
......
1472 1492
                   )->webdav_path;
1473 1493
  }
1474 1494

  
1495
  if ($form->{email_journal_id} && $form->{id} ne "") {
1496
    my $ar_transaction = SL::DB::GLTransaction->new(id => $form->{id})->load;
1497
    my $email_journal = SL::DB::EmailJournal->new(
1498
      id => delete $form->{email_journal_id}
1499
    )->load;
1500
    $email_journal->link_to_record_with_attachment($ar_transaction, delete $::form->{email_attachment_id});
1501
  }
1502

  
1475 1503
  my $msg = $::locale->text("General ledger transaction '#1' posted (ID: #2)", $form->{reference}, $form->{id});
1476 1504
  if ($form->{callback} =~ /BankTransaction/ && $form->{bt_id}) {
1477 1505
    SL::Helper::Flash::flash_later('info', $msg) if $msg;

Auch abrufbar als: Unified diff