1

We are using Phone 7.x-1.0-beta1 only because it is required to perform API calls to our ERP. After upgrading to Commerce 7.x-1.16 the address info under add user is collapsed by default. Since the phone module puts the phone number in the same section of the form it also becomes hidden. When the drop down arrow to expose the address info is clicked it complains that the phone number is invalid and refuses to expose the fields. We are forced to roll back to Commerce 7.x-1.15 so admins and customers can create accounts.

Is there an option to have the address fields exposed by default or do I need to create an issue?

2
  • What you're describing doesn't sound like default behavior of Commerce Core. User forms do not generally have address sections on them. You may need to look elsewhere for your solution, but an issue in the Commerce Core issue queue would not be appropriate. Jan 20, 2022 at 16:27
  • @RyanSzrama Thanks for you reply. We did some testing and it turns out this is the way the new commerce works. They are collapsing the billing fields into a button "The customer profile add form is now hidden on edit pages by default, preventing the creation of empty profiles on order save." unfortunately this also affects the user add form. In our case we have a custom module that validates the phone field, when clicking the button to expand the billing address fields, the form submits and fails validation. We ended up making some changes to our code so we can update to 7.x-1.16.
    – jsank95
    Feb 9, 2022 at 21:28

1 Answer 1

0

We were able to solve this issue. It was a combination of a change in Commerce 7.x-1.16 Issue 2274833 effecting our custom phone number validation script.

commerce_customer.module::~1012

+      '#value' => t('Add @type', array(
+        '@type' => strtolower($profile_type['name']),
+      )),

Since they Changed 'name' from customer information to account information our code was broken.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.