Revision 833f083e
Von Jan Büren vor mehr als 9 Jahren hinzugefügt
SL/OE.pm | ||
---|---|---|
795 | 795 |
if (!$form->{id}) { |
796 | 796 |
my $wday = (localtime(time))[6]; |
797 | 797 |
my $next_workday = $wday == 5 ? 3 : $wday == 6 ? 2 : 1; |
798 |
|
|
799 |
# if we have a client configured interval for sales quotation, we add this |
|
800 |
$next_workday += $::instance_conf->get_reqdate_interval if ($::instance_conf->get_reqdate_interval && |
|
801 |
$form->{type} eq 'sales_quotation' ); |
|
802 |
|
|
798 | 803 |
$query_add = qq|, current_date AS transdate, date(current_date + interval '${next_workday} days') AS reqdate|; |
799 | 804 |
} |
800 | 805 |
|
Auch abrufbar als: Unified diff
Konfigurierbares Angebotsgültigkeits-Intervall hinzugefügt
Standardmässig ist ein Verkaufsangebot bis zum nächsten Werktag gültig.
Dieses Intervall wird dann noch hinzugerechnet, bspw. nächster Werktag plus 14, 28 etc.
Falls das Intervall nicht gesetzt oder wir nicht den Typ sales_quotation haben, passiert nichts.
Der Datentyp ist Integer, Tippfehler werden bisher nur dort abgefangen (Wird wahrscheinlich
nur einmalig von einem Kunden gesetzt).