Open davidmpickett opened 2 months ago
After some more research, it looks like the information about a given State (or "Administrative area," as they call it) in the address module comes from a dependency, the addressing PHP library. However, there's an event to which we can subscribe, the AddressEvents::SUBDIVISIONS event described in the module's documention. With that, we can add whatever subdivisions we want (including "PH"). (edited)
Drupal.org Address Provides functionality for storing, validating and displaying international postal addresses.
@omahane to look at options and flesh out the ticket. Will also apply to the VBA facility in the Philippines.
It won't block publishing Manila, but it will block future edits -- Did we decide to consider this launch blocking? Or just: asap when we understand / can get to it?
We don't know if migrations will break this again. Not currently launch blocking, not blocking editor from editing. If we run into this again, Drupal Admins can re-save the node to fix it.
5 points is assuming an old Drupal hand does the work. If this goes to someone newer, may look more like an 8.
User Story or Problem Statement
Should an editor try to edit a Manila facility, the Address widget throws an error.
Further analysis shows that this is related to the state, being "PH" (for Philippines, which is not a state). The address from the Lighthouse Facilities API is
Should an admin save the node, the facility will save with the State subfield as blank.
Subsequently, an editor can edit and save the facility, but this leaves the state blank.
Steps for Implementation
The information about a given State (or "Administrative area," as they call it) in the address module comes from a dependency, the addressing PHP library. We can subscribe to the AddressEvents::SUBDIVISIONS event described in the module's documention. With that, we can add whatever subdivisions we want (including "PH"). (edited)
Drupal.org Address Provides functionality for storing, validating and displaying international postal addresses.
Acceptance Criteria