You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is that when I build the order Object I see DefaultCommercialMailAddress & DefaultCommercialMailAddress set correctly, regardless if the email is the same with one CustomerMetaData object 9like on the sample code below), or I pass 3 different instances of CustomerMetaData with different emails.
Result
DefaultCommercialMailAddress & DefaultCommercialMailAddress are null at the returned object from the createObject response
Expected result
I expect both email addresses to be set.
Code
Note" I've skipped in the code below the unrelated Customer & Order methods
useBillbeeDe\BillbeeAPI\Model\Customer;
useBillbeeDe\BillbeeAPI\Model\CustomerMetaData;
useBillbeeDe\BillbeeAPI\Model\Order;
...$customerMetaData = newCustomerMetaData();
$customerMetaData->setTypeId(CustomerMetaData::TYPE_MAIL);
$customerMetaData->setValue('[email protected]');
$customer = newCustomer();
$customer->setEmail('[email protected]');
$customer->setDefaultMailAddress($customerMetaData);
// the next 2 are set to null when the order is created$customer->setDefaultCommercialMailAddress($customerMetaData);
$customer->setDefaultStatusUpdatesMailAddress($customerMetaData);
$order = newOrder();
$order->setCustomer($customer);
Problem
The problem is that when I build the order Object I see
DefaultCommercialMailAddress
&DefaultCommercialMailAddress
set correctly, regardless if the email is the same with oneCustomerMetaData
object 9like on the sample code below), or I pass 3 different instances ofCustomerMetaData
with different emails.Result
DefaultCommercialMailAddress
&DefaultCommercialMailAddress
are null at the returned object from thecreateObject
responseExpected result
I expect both email addresses to be set.
Code
Note" I've skipped in the code below the unrelated Customer & Order methods
build Order object
serialized data of Customer
This is the data passed to the
Customer
of theOrder
that is passed inCustomerEndpoint::createCustomer()
which calls the client post() method.created Order object
The text was updated successfully, but these errors were encountered: