Revision 0ecd797d
Von Tamino Steinert vor etwa 2 Jahren hinzugefügt
SL/DB/ReclamationItem.pm | ||
---|---|---|
4 | 4 |
use strict; |
5 | 5 |
|
6 | 6 |
use List::MoreUtils qw(any); |
7 |
use Rose::DB::Object::Helpers qw(as_tree strip); |
|
7 | 8 |
|
8 | 9 |
use SL::DB::MetaSetup::ReclamationItem; |
9 | 10 |
use SL::DB::Manager::ReclamationItem; |
... | ... | |
87 | 88 |
|
88 | 89 |
my $item = $class->new(%item_args); |
89 | 90 |
|
90 |
if ( $source->record->is_sales() && ($parent_type =~ m{sales}) ) {
|
|
91 |
if ( $source->record->is_sales() && ($parent_type =~ m{purchase}) ) {
|
|
91 | 92 |
$item->sellprice($source->lastcost); |
92 | 93 |
$item->discount(0); |
93 | 94 |
} |
94 |
if ( !$source->record->is_sales() && ($parent_type =~ m{purchase}) ) {
|
|
95 |
if ( !$source->record->is_sales() && ($parent_type =~ m{sales}) ) {
|
|
95 | 96 |
$item->lastcost($source->sellprice); |
96 | 97 |
} |
97 | 98 |
|
Auch abrufbar als: Unified diff
Reclamation: Test for workflow (reclamation, order, delivery_order)