mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2024-11-14 12:07:15 +01:00
Merge pull request #115 from creatronics-de/bugfix_rabatt_in_rechnung_erste_zeile_fehler
Fehler bei Änderung des Rabatts in der ersten Zeile von Angeboten, Rechnungen, etc.
This commit is contained in:
commit
00333f8762
@ -736,9 +736,10 @@ class YUI {
|
||||
if($value == '')$value = '0';
|
||||
$this->app->DB->Update("UPDATE $table SET rabatt='$value',keinrabatterlaubt=1 WHERE id='$id' LIMIT 1");
|
||||
$result = $this->app->DB->Select("SELECT ".$this->FormatPreis('rabatt')." FROM $table WHERE id='$id' LIMIT 1");
|
||||
$sort = $this->app->DB->Select("SELECT sort FROM $table WHERE id='$id' LIMIT 1");
|
||||
$parent = $this->app->DB->Select("SELECT $module FROM $table WHERE id='$id' LIMIT 1");
|
||||
if($parent && $sort == 1)$this->app->DB->Update("UPDATE $module SET rabatt = '$value',keinrabatterlaubt=1 WHERE id = '$parent' LIMIT 1");
|
||||
|
||||
//$sort = $this->app->DB->Select("SELECT sort FROM $table WHERE id='$id' LIMIT 1");
|
||||
//$parent = $this->app->DB->Select("SELECT $module FROM $table WHERE id='$id' LIMIT 1");
|
||||
//if($parent && $sort == 1)$this->app->DB->Update("UPDATE $module SET rabatt = '$value',keinrabatterlaubt=1 WHERE id = '$parent' LIMIT 1");
|
||||
if(in_array($module, array('auftrag','rechnung','gutschrift')))
|
||||
{
|
||||
$tmptable_value = $this->app->DB->Select("SELECT $module FROM $table WHERE id = '$id' LIMIT 1");
|
||||
|
Loading…
Reference in New Issue
Block a user