Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 58348a96

Von Tamino Steinert vor mehr als 1 Jahr hinzugefügt

  • ID 58348a96b940ac8d9ae6f274b67141277bc5d3c8
  • Vorgänger 58954098
  • Nachfolger 74448c30

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();
......
1613 1613
  # always save
1614 1614
  $self->save();
1615 1615

  
1616
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, ref($self->order), $destination_type);
1616
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, $destination_type);
1617 1617
  $self->order($delivery_order);
1618 1618
  $self->{converted_from_oe_id} = delete $::form->{id};
1619 1619

  
......
1649 1649
  # always save
1650 1650
  $self->save();
1651 1651

  
1652
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, ref($self->order), $destination_type);
1652
  my $delivery_order = SL::Model::Record->new_from_workflow($self->order, $destination_type);
1653 1653
  $self->order($delivery_order);
1654 1654
  $self->{converted_from_oe_id} = delete $::form->{id};
1655 1655

  

Auch abrufbar als: Unified diff