Skip to content
Code-Schnipsel Gruppen Projekte
Commit 2550e99c erstellt von Patrick Müller's avatar Patrick Müller
Dateien durchsuchen

Merge branch 'dev' of https://dev.quiqqer.com/quiqqer/erp into dev

Übergeordnete e18b80b3 a4946bb2
Keine zugehörigen Branchen gefunden
Keine zugehörigen Tags gefunden
Keine zugehörigen Merge Requests gefunden
......@@ -112,6 +112,10 @@ public function __construct(array $attributes = [])
}
parent::__construct($attributes);
if (!empty($this->calculations)) {
$this->calculated = true;
}
}
/**
......
......@@ -97,7 +97,6 @@ public function __construct($attributes = [])
$this->calculations = $attributes['calculations'];
$this->showHeader = isset($attributes['showHeader']) ? $attributes['showHeader'] : true;
// price factors
$this->PriceFactors = new ErpFactorList();
......
......@@ -40,7 +40,7 @@ class User
* is the user a netto or brutto user
*
* @param UserInterface $User
* @return bool
* @return integer
*/
public static function getBruttoNettoUserStatus(UserInterface $User)
{
......@@ -103,23 +103,24 @@ public static function getBruttoNettoUserStatus(UserInterface $User)
return self::$userBruttoNettoStatus[$uid];
}
// verifizierung als unternehm einbauen
// Verifizierung als Unternehmen einbauen
try {
$Address = self::getUserERPAddress($User);
if (\is_object($Address)
&& $Address
&& $Address->getAttribute('company')
) {
if ($Config->getValue('shop', 'companyForceBruttoPrice')) {
self::$userBruttoNettoStatus[$uid] = self::IS_BRUTTO_USER;
if (\is_object($Address) && $Address) {
$company = $Address->getAttribute('company');
return self::$userBruttoNettoStatus[$uid];
}
if (!empty($company)) {
if ($Config->getValue('shop', 'companyForceBruttoPrice')) {
self::$userBruttoNettoStatus[$uid] = self::IS_BRUTTO_USER;
self::$userBruttoNettoStatus[$uid] = self::IS_NETTO_USER;
return self::$userBruttoNettoStatus[$uid];
}
return self::$userBruttoNettoStatus[$uid];
self::$userBruttoNettoStatus[$uid] = self::IS_NETTO_USER;
return self::$userBruttoNettoStatus[$uid];
}
}
if (\is_array($Address)
......
0% Lade oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren