Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 382890fe

Von Thomas Heck vor etwa 11 Jahren hinzugefügt

  • ID 382890fe41b27b14c74d15587396255988883448
  • Vorgänger bc7c5665
  • Nachfolger b623ece7

CustomerVendor: bei Wiedervorlagen FollowUpLinks erstellen

Unterschiede anzeigen:

SL/Controller/CustomerVendor.pm
18 18
use SL::DB::Pricegroup;
19 19
use SL::DB::Contact;
20 20
use SL::DB::FollowUp;
21
use SL::DB::FollowUpLink;
21 22
use SL::DB::History;
22 23
use SL::DB::Currency;
23 24

  
......
124 125

  
125 126
      $self->{note}->trans_id($self->{cv}->id);
126 127
      $self->{note}->save();
128

  
127 129
      $self->{note_followup}->save();
128 130

  
131
      $self->{note_followup_link}->follow_up_id($self->{note_followup}->id);
132
      $self->{note_followup_link}->trans_id($self->{cv}->id);
133
      $self->{note_followup_link}->save();
134

  
129 135
      SL::Helper::Flash::flash_later('info', $::locale->text('Follow-Up saved.'));
130 136

  
131 137
      $self->{note} = SL::DB::Note->new();
132 138
      $self->{note_followup} = SL::DB::FollowUp->new();
139
      $self->{note_followup_link} = SL::DB::FollowUpLink->new();
133 140
    }
134 141

  
135 142
    $self->{shipto}->trans_id($self->{cv}->id);
......
627 634
  $self->{note_followup}->note($self->{note});
628 635
  $self->{note_followup}->created_by($curr_employee->id);
629 636

  
637
  $self->{note_followup_link} = SL::DB::FollowUpLink->new(
638
    trans_type => ($self->is_vendor() ? 'vendor' : 'customer'),
639
    trans_info => $self->{cv}->name
640
  );
641

  
630 642
  if ( $::form->{shipto}->{shipto_id} ) {
631 643
    $self->{shipto} = SL::DB::Shipto->new(shipto_id => $::form->{shipto}->{shipto_id})->load();
632 644
  } else {
......
664 676

  
665 677
  $self->{note} = SL::DB::Note->new();
666 678
  $self->{note_followup} = SL::DB::FollowUp->new();
679
  $self->{note_followup_link} = SL::DB::FollowUpLink->new();
667 680

  
668 681
  if ( $::form->{shipto_id} ) {
669 682
    $self->{shipto} = SL::DB::Shipto->new(shipto_id => $::form->{shipto_id})->load();

Auch abrufbar als: Unified diff