Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 26e34663

Von Tamino Steinert vor etwa 1 Jahr hinzugefügt

  • ID 26e346638fe1066e374930e6af53b15e33da3211
  • Vorgänger 11ca9f4a
  • Nachfolger 7da8047a

Model::Record: Funktionsaufruf angepasst für new_from_worklow ...

und new_from_workflow_multi

Unterschiede anzeigen:

SL/Controller/DeliveryOrder.pm
108 108
  my $order = SL::DB::Order->new(id => $self->{converted_from_oe_id})->load;
109 109

  
110 110
  my $target_type = $::form->{type};
111
  my $delivery_order = SL::Model::Record->new_from_workflow($order, ref($self->order), $target_type);
111
  my $delivery_order = SL::Model::Record->new_from_workflow($order, $target_type);
112 112
  $self->order($delivery_order);
113 113

  
114 114
  $self->action_add;
......
120 120
  my $reclamation = SL::DB::Reclamation->new(id => $::form->{from_id})->load;
121 121
  my $target_type = $reclamation->is_sales ? 'rma_delivery_order'
122 122
                                           : 'supplier_delivery_order';
123
  my $delivery_order = SL::Model::Record->new_from_workflow($reclamation, ref($self->order), $target_type);
123
  my $delivery_order = SL::Model::Record->new_from_workflow($reclamation, $target_type);
124 124
  $self->{converted_from_reclamation_id} = $::form->{from_id};
125 125
  $self->order($delivery_order);
126 126

  
......
185 185
  my @multi_orders = map { SL::DB::DeliveryOrder->new(id => $_)->load } @multi_ids;
186 186
  $self->{converted_from_oe_id} = join ' ', map { $_->id } @multi_orders;
187 187
  my $target_type = SALES_DELIVERY_ORDER_TYPE();
188
  my $delivery_order = SL::Model::Record->new_from_workflow_multi(\@multi_orders, ref($self->order), $target_type, sort_sources_by => 'transdate');
188
  my $delivery_order = SL::Model::Record->new_from_workflow_multi(\@multi_orders, $target_type, sort_sources_by => 'transdate');
189 189
  $self->order($delivery_order);
190 190

  
191 191
  $self->action_edit();
......
1617 1617
  # always save
1618 1618
  $self->save();
1619 1619

  
1620
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, ref($self->order), $destination_type);
1620
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, $destination_type);
1621 1621
  $self->order($delivery_order);
1622 1622
  $self->{converted_from_oe_id} = delete $::form->{id};
1623 1623

  
......
1653 1653
  # always save
1654 1654
  $self->save();
1655 1655

  
1656
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, ref($self->order), $destination_type);
1656
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, $destination_type);
1657 1657
  $self->order($delivery_order);
1658 1658
  $self->{converted_from_oe_id} = delete $::form->{id};
1659 1659

  

Auch abrufbar als: Unified diff