Fix payment profile discrepancies
The return value of
Payment::Profile.lookup with the same or similar
PaymentReferences as the argument was not always consistent. In some cases,
Payment::Profile.lookup returns an invalid record, which causes problems down the line when an OMS or something needs to read information stored in the profile record, and now that record cannot be found. What is actually happening is that the profile was successfully created, but
.lookup is not written to use the pre-existing profile and instead tries to generate a new one. When this fails, when we get issues like the
Payment#profile_id referencing a record that doesn't actually exist. To remedy this, we've updated how
Payment::Profile.lookup works to always find by the
PaymentReference#id, and automatically update email if we're creating a new record.
Daylight savings time is being accounted for twice in release calendar
Add .ui-menu-item-wrapper to jQuery UI menu template
This element was not included in the jQuery UI menu template for asynchronously adding a
.ui-menu-item to the page, causing some issues in the handler code that jQuery UI gives us. Add the element to both fix the actual UI and behavior of jQuery UI menu items.
Convert IDs to string when comparing in find_ordered
find_ordered method did not work as intended when the type of each document's
#id were not consistent. Convert all IDs to String before comparing them to gain a more accurate sorted Array out of this method.