Revision fbee3bde
Von Tamino Steinert vor etwa 1 Jahr hinzugefügt
t/workflow/invoice_to_reclamation.t | ||
---|---|---|
24 | 24 |
use SL::DB::Employee; |
25 | 25 |
use SL::DB::Part; |
26 | 26 |
use SL::DB::Unit; |
27 |
use SL::Model::Record; |
|
27 | 28 |
|
28 | 29 |
use Rose::DB::Object::Helpers qw(clone); |
29 | 30 |
|
... | ... | |
180 | 181 |
)->load; |
181 | 182 |
|
182 | 183 |
# convert invoice → reclamation |
183 |
my $converted_sales_reclamation = $sales_invoice->convert_to_reclamation;
|
|
184 |
my $converted_sales_reclamation =SL::Model::Record->new_from_workflow($sales_invoice, "sales_reclamation");
|
|
184 | 185 |
$converted_sales_reclamation->items_sorted->[0]->reason($relamation_reason); |
185 | 186 |
$converted_sales_reclamation->items_sorted->[1]->reason($relamation_reason); |
186 | 187 |
$converted_sales_reclamation->save->load; |
187 |
my $converted_purchase_reclamation = $purchase_invoice->convert_to_reclamation;
|
|
188 |
my $converted_purchase_reclamation = SL::Model::Record->new_from_workflow($purchase_invoice, "purchase_reclamation");
|
|
188 | 189 |
$converted_purchase_reclamation->items_sorted->[0]->reason($relamation_reason); |
189 | 190 |
$converted_purchase_reclamation->items_sorted->[1]->reason($relamation_reason); |
190 | 191 |
$converted_purchase_reclamation->save->load; |
Auch abrufbar als: Unified diff
MOdel::Record: Test angepasst