Merge pull request #186 from faser2k/auftrag_position_waehrung

always use currency from auftrag for auftrag_positionen
This commit is contained in:
OpenXE-ERP 2025-03-02 09:36:53 +01:00 committed by GitHub
commit e10bf935f1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 8 deletions

View File

@ -3069,12 +3069,6 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
$adresse = $document['adresse'];// $this->app->DB->Select("SELECT adresse FROM $smodule WHERE id='$sid' LIMIT 1");
$waehrung = $document['waehrung'];//$this->app->DB->Select("SELECT waehrung FROM $smodule WHERE id='$sid' LIMIT 1");
$posanz = (int)$this->app->DB->Select("SELECT count(id) FROM $smodule"."_position WHERE $smodule = '$sid'");
if($posanz == 0)
{
$waehrung = '';
}
$anzeigebrutto = false;
if($smodule == 'auftrag' || $smodule == 'rechnung' || $smodule == 'gutschrift' || $smodule == 'angebot' || $smodule == 'proformarechnung')

View File

@ -3699,8 +3699,8 @@ class Artikel extends GenArtikel {
$adresse = $this->app->DB->Select("SELECT adresse FROM $smodule WHERE id='$sid' LIMIT 1");
}
if (!is_null($module)) {
if ($this->app->DB->Select("SHOW COLUMNS FROM `$module` LIKE 'waehrung'")) {
if (!is_null($smodule)) {
if ($this->app->DB->Select("SHOW COLUMNS FROM `$smodule` LIKE 'waehrung'")) {
$waehrung = $this->app->DB->Select("SELECT waehrung FROM $smodule WHERE id='$sid' LIMIT 1");
}
}