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

fix: invoice address must be array on save

Übergeordneter ab476265
No related branches found
No related tags found
Keine zugehörigen Merge Requests gefunden
......@@ -353,6 +353,8 @@ public function getCustomer()
'email' => $User->getAttribute('email')
];
$Customer = false;
try {
$Customer = QUI\ERP\User::convertUserToErpUser($User);
$userData = $Customer->getAttributes();
......@@ -390,10 +392,6 @@ public function getCustomer()
}
}
if (!empty($this->getAttribute('contact_person'))) {
$userData['quiqqer.erp.customer.contact.person'] = $this->getAttribute('contact_person');
}
if (empty($userData['country'])) {
$userData['country'] = QUI\ERP\Defaults::getCountry()->getCode();
}
......@@ -767,8 +765,9 @@ public function update($PermissionUser = null)
$invoiceAddressCheck['contactEmail'] = $contactEmail;
$invoiceAddress = \json_encode($invoiceAddressCheck);
} else {
} elseif (\is_array($invoiceAddress)) {
$invoiceAddress['contactEmail'] = $contactEmail;
$invoiceAddress = \json_encode($invoiceAddress);
}
if (!$invoiceAddressCheck) {
......
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren