The problem
When some of the address fields have the same weight value, some address fields will get hidden on the address field settings page (part of "Checkout settings" in Ubercart 6.x-2.x). This will result into these fields to be disabled and non-required. This is because Extra Fields Pane assumes the address weight is unique which don't have to be always true, because the variable uc_address_fields_weight (in which the field weights are saved) can also be set manually or by an other module (e.g. features/strongarm).
How to reproduce
Give some address fields the same weight:
variable_set('uc_address_fields_weight', array('first_name' => 10, 'last_name' => 10));
In this case the field "First name" will not be shown on the address fields settings page. If you now save the settings on this page, the "First name" field will be disabled.
The Drupal 7 version of Extra Fields Pane is not affected.
A fix for this will be committed shortly.
Comments
Comment #1
megachrizFixed by using the
uasort()function instead of theksort()function intheme_uc_extra_fields_pane_uc_store_address_fields().See commit.