Your IP : 3.129.249.61
"use strict";BX.namespace("BX.Sale.PropertyCollection");BX.Sale.PropertyCollection=function(){var t=function(t){var n=0;return function(){return t[n++]}};var n=function(n,e){this.getId=function(){return n.ID};this.getName=function(){return n.NAME};this.getPersonTypeId=function(){return n.PERSON_TYPE_ID};this.getIterator=function(){return t(e)}};var e=BX.Sale.Input.Manager.Editor;var r=function(t,n){var r=!!n?"ORDER_PROP_"+t.ID:"PROPERTIES["+t.ID+"]";var i=t.TYPE=="LOCATION"&&!!n?{}:new e(r,t);i.getId=function(){return t.ID};i.getName=function(){return t.NAME};i.getType=function(){return t.TYPE};i.isRequired=function(){return t.REQUIRED==="Y"};i.isMultiple=function(){return t.MULTIPLE==="Y"};i.getGroupId=function(){return t.PROPS_GROUP_ID};i.getDescription=function(){return t.DESCRIPTION};i.getPersonTypeId=function(){return t.PERSON_TYPE_ID};i.getAltLocation=function(){return t.INPUT_FIELD_LOCATION};i.getSettings=function(){return t};return i};var i=["IS_EMAIL","IS_PAYER","IS_LOCATION","IS_LOCATION4TAX","IS_PROFILE_NAME","IS_ZIP","IS_PHONE","IS_ADDRESS"],u=i.length;return function(e){var o=[],I=[],c={};var f,a,P,s,g,E,O={},_=[],S,h,l,T,p=!!e.publicMode;f=e.groups;for(P in f){if(!f.hasOwnProperty(P))continue;s=f[P];g=s.ID;E=[];O[g]=E;o.push(new n(s,E))}f=e.properties;for(P in f){if(!f.hasOwnProperty(P))continue;s=f[P];S=s.ID;g=s.PROPS_GROUP_ID;h=r(s,p);c[S]=h;I.push(h);if(O.hasOwnProperty(g)){O[g].push(h)}else{throw"undefined group"}if(s.TYPE=="LOCATION"&&s.INPUT_FIELD_LOCATION&&!p)_.push(h);for(l=0;l<u;l++){T=i[l];if(s[T]=="Y")c[T]=h}}a=_.length;for(P=0;P<a;P++){_[P].addEvent("change",function(t,n){var e=false,r=n.getValuePath(),i=0,u=r.length;for(;i<u;i++){if(r[i].TYPE=="CITY"){e=true;break}}if(!!c[n.getAltLocation()])c[n.getAltLocation()].setDisabled(e)})}e=f=s=E=O=_=h=null;this.getIterator=function(){return t(I)};this.getGroupIterator=function(){return t(o)};this.getById=function(t){return c[t]};this.getUserEmail=function(){return c.IS_EMAIL};this.getPayerName=function(){return c.IS_PAYER};this.getDeliveryLocation=function(){return c.IS_LOCATION};this.getTaxLocation=function(){return c.IS_LOCATION4TAX};this.getProfileName=function(){return c.IS_PROFILE_NAME};this.getDeliveryLocationZip=function(){return c.IS_ZIP};this.getPhone=function(){return c.IS_PHONE};this.getAddress=function(){return c.IS_ADDRESS}}}();
//# sourceMappingURL=orderproperties.map.js