Skip to content

Commit 981a947

Browse files
authored
[Shopify] Auto create new customer toggle prevents connector from using default customer (#4374)
<!-- Thank you for submitting a Pull Request. If you're new to contributing to BCApps please read our pull request guideline below * https://github.com/microsoft/BCApps/Contributing.md --> #### Summary <!-- Provide a general summary of your changes --> Auto create new customer toggle prevents connector from using default customer #### Work Item(s) <!-- Add the issue number here after the #. The issue needs to be open and approved. Submitting PRs with no linked issues or unapproved issues is highly discouraged. --> Fixes [AB#595971](https://dynamicssmb2.visualstudio.com/1fcb79e7-ab07-432a-a3c6-6cf5a88ba4a5/_workitems/edit/592060)
1 parent 1fcc5f4 commit 981a947

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Apps/W1/Shopify/App/src/Order handling/Codeunits/ShpfyOrderMapping.Codeunit.al

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ codeunit 30163 "Shpfy Order Mapping"
117117
JCustomer.Add('County', OrderHeader."Bill-to County");
118118
JCustomer.Add('CountryCode', OrderHeader."Bill-to Country/Region Code");
119119
OrderHeader."Bill-to Customer No." := CustomerMapping.DoMapping(OrderHeader."Customer Id", JCustomer, OrderHeader."Shop Code", CustomerTemplateCode, AllowCreateCustomer);
120-
if (OrderHeader."Bill-to Customer No." = '') and (not Shop."Auto Create Unknown Customers") and (Shop."Default Customer No." <> '') then
120+
if (OrderHeader."Bill-to Customer No." = '') and (Shop."Default Customer No." <> '') then
121121
OrderHeader."Bill-to Customer No." := Shop."Default Customer No.";
122122

123123
if OrderHeader."Sell-to Customer No." = '' then
@@ -161,7 +161,7 @@ codeunit 30163 "Shpfy Order Mapping"
161161
OrderHeader."Bill-to Customer No." := OrderHeader."Sell-to Customer No.";
162162
end;
163163

164-
if (OrderHeader."Bill-to Customer No." = '') and (not Shop."Auto Create Unknown Customers") and (Shop."Default Company No." <> '') then
164+
if (OrderHeader."Bill-to Customer No." = '') and (Shop."Default Company No." <> '') then
165165
OrderHeader."Bill-to Customer No." := Shop."Default Company No.";
166166
if OrderHeader."Sell-to Customer No." = '' then
167167
OrderHeader."Sell-to Customer No." := OrderHeader."Bill-to Customer No.";

0 commit comments

Comments
 (0)