Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
In uc_ups.module (and possibly elsewhere) there is the following code around line 1000:
<?php
foreach (array('delivery_email', 'delivery_last_name', 'delivery_street1', 'delivery_city', 'delivery_zone', 'delivery_country', 'delivery_postal_code') as $field) {
$form['destination'][$field]['#required'] = TRUE;
}
?>
This forces the 'delivery_zone' field (State/Province) to be required. When shipping to a country with no zones such as Singapore you can never submit this form. I've had to comment out 'delivery_zone' so that the form would pass validation.
Comments
Comment #1
TR CreditAttribution: TR commentedAre you talking about shipping quotes or shipping? What form are you talking about?
Comment #2
charlie-s CreditAttribution: charlie-s commentedHey TR!
Creating an actual shipment from a package on a finished order. The actual path where the form is displayed and the error occurs is
admin/store/orders/[order-id]/ship/ups/[package-id]
. The form id isuc_ups_fulfill_order
. If the country is Singapore then the State/Province is set to-1 => N/A
. The field itself has been set to'#required' => TRUE
in the code that I posted in the issue summary.Comment #3
longwaveFix committed to both branches.