Commits

Thomas Tornevall authored c681dd36703
RWC-291 Close #68 * rbSwitchCustomerType has been corrected so that we are handing over the big business to internal logics as much as possible (making sure that resursSsnCustomerType are just updated to push data through the fragment handler - update_checkout - instead of doing frontend work). * setCustomer now handles companies and contact data properly, and setting customerType dynamically. * requiredFields is now supporting NATURAL and LEGAL properly. * streamLineFields is now known as alwaysShowApplicantFields as this is reflected in the configuration. * added getFieldMethodList so it supports translated LEGAL fields. * Updated getSpecificTypeFields to really handle both NATURAL and LEGAL (should be pushed onto ecom). * rbwc_get_switch_to_customer_type_string now handles two parameters, to reflect customer types vs translations. As it is a filter integrators can change this by handling the filter by another priority. * hasDualCustomerTypes adopted from a WC2.x idea, but with better code. * Translations for switchToNatural/switchToLegal are now handled through filters instead of PluginHooks. * civicNumberOptions are fixed so it won't bail out on unknown countries. * Frontend scripts handles translations and strings automatically when switching customer types in "simple getAddress mode". * Frontend html resursSsnCustomerType now includes current customer type. * Added testdata for DK.