X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=SL%2FDB%2FManager%2FPriceRule.pm;h=d5b5489d67e181d85a7cd3f7d2bb23eb2c541be3;hb=b269674b6b0e99818c3643d4fc3271a8ce83b8c6;hp=99065dbb5ee60f56048fe8c7fba92d099c1f1e7f;hpb=986282c191d6ad3c02608b2fd33d66a12779e401;p=kivitendo-erp.git diff --git a/SL/DB/Manager/PriceRule.pm b/SL/DB/Manager/PriceRule.pm index 99065dbb5..d5b5489d6 100644 --- a/SL/DB/Manager/PriceRule.pm +++ b/SL/DB/Manager/PriceRule.pm @@ -7,6 +7,10 @@ use strict; use parent qw(SL::DB::Helper::Manager); +use constant PRICE_NEW => 0; +use constant PRICE_REDUCED_MASTER_DATA => 1; +use constant PRICE_DISCOUNT => 2; + use SL::DB::Helper::Filtered; use SL::DB::Helper::Paginated; use SL::DB::Helper::Sorted; @@ -76,6 +80,12 @@ sub get_all_matching { $self->get_all(query => [ id => \@ids ]); } +sub all_price_types { + [ PRICE_NEW, t8('Price') ], + [ PRICE_REDUCED_MASTER_DATA, t8('Reduced Master Data') ], + [ PRICE_DISCOUNT, t8('Discount') ], +} + sub _sort_spec { return ( columns => { SIMPLE => 'ALL', }, default => [ 'name', 1 ],