text: (window.webpackJsonp=window.webpackJsonp||[]).push([[33,13],{1507:function(e,t,a){"use strict";a.r(t);var r=a(24),n=a.n(r),i=a(25),o=a.n(i),c=a(26),l=a.n(c),s=a(27),u=a.n(s),d=a(16),m=a.n(d),p=a(0),h=a.n(p),g=a(31),b=a(800),f=a(22),v=a.n(f),y=a(6),E=a.n(y),I=a(4),N=a(702),P=a(102),A=a(861),C=Object(g.b)(null,(function(e){return{deleteOrder:function(t){e(Object(A.c)(t))}}}))((function(e){return h.a.createElement(P.a,{buttonConfirmText:"Verwijder",buttonClassName:"btn-danger",closeModal:e.closeDeleteItemModal,confirmAction:function(){return e.deleteOrder(e.id),void e.closeDeleteItemModal()},title:"Verwijderen"},"Verwijder Order: ",h.a.createElement("strong",null," ",e.subject," "),"?")})),R=a(703);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var x=function(e){l()(a,e);var t=D(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"toggleDelete",(function(){r.setState({showDelete:!r.state.showDelete})})),E()(v()(r),"preview",(function(){I.f.push("/order/inzien/".concat(r.props.orderDetails.id))})),E()(v()(r),"newInvoice",(function(){r.props.previewCreate([r.props.orderDetails.id]),I.f.push("/financieel/".concat(r.props.orderDetails.administrationId,"/orders/aanmaken"))})),r.state={showDelete:!1,showNewInvoice:!1},r}return o()(a,[{key:"render",value:function(){return h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-md-4"},h.a.createElement("div",{className:"btn-group btn-group-flex margin-small",role:"group"},h.a.createElement(N.a,{iconName:"glyphicon-arrow-left",onClickAction:I.e.goBack}),!this.props.orderDetails.canCreateInvoice&&h.a.createElement(N.a,{iconName:"glyphicon-eye-open",onClickAction:this.preview}),this.props.orderDetails.canCreateInvoice&&h.a.createElement(R.a,{buttonText:"Preview concept nota",onClickAction:this.newInvoice}),h.a.createElement(N.a,{iconName:"glyphicon-trash",onClickAction:this.toggleDelete}))),!this.props.isLoading&&h.a.createElement("div",{className:"col-md-4"},h.a.createElement("h4",{className:"text-center"},"Order: ",this.props.orderDetails.subject," / ",this.props.orderDetails.number)),h.a.createElement("div",{className:"col-md-4"}),this.state.showDelete&&h.a.createElement(C,{closeDeleteItemModal:this.toggleDelete,subject:this.props.orderDetails.subject,id:this.props.orderDetails.id,administrationId:this.props.administrationId}))}}]),a}(p.Component),O=Object(g.b)((function(e){return{orderDetails:e.orderDetails,administrationId:e.orderDetails.administrationId,isLoading:e.loadingData.isLoading}}),(function(e){return{previewCreate:function(t){e(Object(A.e)(t))}}}))(x),S=a(200),B=a(708),w=a.n(B),k=a(704),T=a(700),_=a(701),F=(a(761),a(707)),M=a(105),j=a(710),L=a(730),V=a(7),Y=a.n(V),q=a(94);function z(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Z(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?z(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):z(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function $(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var G=function(e){l()(a,e);var t=$(a);function a(e){var r;n()(this,a),r=t.call(this,e),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState({order:Z(Z({},r.state.order),{},E()({},n,a))})})),E()(v()(r),"handleInputChangeParticipation",(function(e){var t,a=e.target,n="checkbox"===a.type?a.checked:a.value;t=(t=r.state.participations.filter((function(e){return e.id==n})))[0],r.setState({order:Z(Z({},r.state.order),{},{participationId:t.id})})})),E()(v()(r),"handleInputChangeDate",(function(e,t){r.setState({order:Z(Z({},r.state.order),{},E()({},t,e))})})),E()(v()(r),"handleInputChangeInvoiceDate",(function(e,t){r.setState({order:Z(Z({},r.state.order),{},E()({},t,e))},r.checkContactCollectMandate)})),E()(v()(r),"checkContactCollectMandate",(function(){var e=r.state.order.paymentTypeId,t=r.state.order.dateNextInvoice;t||(t=Y()().format("YYYY-MM-DD"));var a=r.props.contactCollectMandateFirstRun,n=r.props.contactCollectMandate,i=1==n;n&&a>t&&(i=!1),i||(e="transfer"),r.setState({collectMandateActive:i,order:Z(Z({},r.state.order),{},{paymentTypeId:e})})})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t=r.state.order,a={},n=!1;w.a.isEmpty(t.paymentTypeId+"")&&(a.paymentTypeId=!0,n=!0),w.a.isEmpty(t.statusId+"")&&(a.statusId=!0,n=!0),w.a.isEmpty(t.subject+"")&&(a.subject=!0,n=!0),r.setState(Z(Z({},r.state),{},{errors:a})),n||r.props.updateOrder(t,r.props.switchToView)}));var i=e.orderDetails,o=i.id,c=i.contactId,l=i.statusId,s=i.subject,u=i.participationId,d=i.emailTemplateIdCollection,m=i.emailTemplateIdTransfer,p=i.emailTemplateReminderId,h=i.emailTemplateExhortationId,g=i.paymentTypeId,b=i.collectionFrequencyId,f=i.IBAN,y=i.ibanAttn,I=i.numberOfInvoiceReminders,N=i.poNumber,P=i.invoiceText,A=i.dateRequested,C=i.administrationId,R=i.dateNextInvoice;return r.state={emailTemplates:[],showExtraContactInfo:!1,collectMandateActive:!1,participations:[],order:{id:o,contactId:c||"",statusId:l||"",administrationId:C||"",subject:s||"",participationId:u||"",emailTemplateIdCollection:d||"",emailTemplateIdTransfer:m||"",emailTemplateReminderId:p||"",emailTemplateExhortationId:h||"",paymentTypeId:g||"",collectionFrequencyId:b||"once",IBAN:f||"",ibanAttn:y||"",numberOfInvoiceReminders:I||"",poNumber:N||"",invoiceText:P||"",dateRequested:A||"",dateNextInvoice:R||""},errors:{statusId:!1,subject:!1,IBAN:!1},peekLoading:{emailTemplates:!0}},r.handleReactSelectChange=r.handleReactSelectChange.bind(v()(r)),r}return o()(a,[{key:"componentDidMount",value:function(){var e=this;this.state.order.contactId&&q.a.fetchContactInfoForOrder(this.state.order.contactId).then((function(t){e.setState({participations:t.data.participations})})),M.a.fetchEmailTemplatesPeek().then((function(t){e.setState({emailTemplates:t,peekLoading:Z(Z({},e.state.peekLoading),{},{emailTemplates:!1})},e.checkContactCollectMandate)}))}},{key:"handleReactSelectChange",value:function(e,t){this.setState({order:Z(Z({},this.state.order),{},E()({},t,e))})}},{key:"render",value:function(){var e=this.state.order,t=e.statusId,a=e.subject,r=e.participationId,n=e.emailTemplateIdCollection,i=e.emailTemplateIdTransfer,o=e.emailTemplateReminderId,c=e.emailTemplateExhortationId,l=e.paymentTypeId,s=e.collectionFrequencyId,u=(e.IBAN,e.ibanAttn,e.numberOfInvoiceReminders),d=e.poNumber,m=e.invoiceText,p=e.dateRequested,g=e.administrationId,b=e.dateNextInvoice,f=this.props.orderDetails.invoiceCount;return h.a.createElement("form",{className:"form-horizontal",onSubmit:this.handleSubmit},h.a.createElement(T.a,null,h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Order op naam van",value:this.props.orderDetails.contact?this.props.orderDetails.contact.fullName:"",name:"contact",readOnly:!0}),f>0?h.a.createElement(k.a,{label:"Administratie",value:this.props.orderDetails.administration?this.props.orderDetails.administration.name:"",name:"administration",readOnly:!0}):h.a.createElement(F.a,{label:"Administratie",name:"administrationId",options:this.props.administrations,value:g,onChangeAction:this.handleInputChange})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Contact persoon",value:this.props.contactPerson,name:"contactPerson",readOnly:!0}),h.a.createElement(k.a,{label:"Nota wordt gemaild naar",value:this.props.contactEmail,name:"contactEmail",readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(F.a,{label:"Deelname",id:"ParticipationId",name:"ParticipationId",options:this.state.participations,value:r,onChangeAction:this.handleInputChangeParticipation,optionValue:"id",optionName:"project_name"}),h.a.createElement(k.a,{label:"Betreft",name:"subject",value:a,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.subject})),h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"E-mail template nota incasso",name:"emailTemplateIdCollection",options:this.state.emailTemplates,value:n,onChangeAction:this.handleReactSelectChange,isLoading:this.state.peekLoading.emailTemplates}),h.a.createElement(F.a,{label:"Betaalwijze",id:"paymentTypeId",name:"paymentTypeId",options:this.state.collectMandateActive?this.props.orderPaymentTypes:this.props.orderPaymentTypes.filter((function(e){return"transfer"===e.id})),emptyOption:!1,value:l,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.paymentTypeId})),h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"E-mail template nota overboeken",name:"emailTemplateIdTransfer",options:this.state.emailTemplates,value:i,onChangeAction:this.handleReactSelectChange,isLoading:this.state.peekLoading.emailTemplates}),h.a.createElement(F.a,{label:"Nota frequentie",id:"collectionFrequencyId",name:"collectionFrequencyId",options:this.props.orderCollectionFrequencies,value:s,onChangeAction:this.handleInputChange,emptyOption:!1})),h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"E-mail template herinnering",name:"emailTemplateReminderId",options:this.state.emailTemplates,value:o,onChangeAction:this.handleReactSelectChange,isLoading:this.state.peekLoading.emailTemplates}),h.a.createElement(F.a,{label:"Status",id:"statusId",name:"statusId",options:this.props.orderStatuses,value:t,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.statusId})),h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"E-mail template aanmaning",name:"emailTemplateExhortationId",options:this.state.emailTemplates,value:c,onChangeAction:this.handleReactSelectChange,isLoading:this.state.peekLoading.emailTemplates}),h.a.createElement(F.a,{label:"Aantal keer herinneringen nota",id:"numberOfInvoiceReminders",size:"col-sm-6",name:"numberOfInvoiceReminders",options:[{id:"1",name:"1x"},{id:"2",name:"2x"},{id:"3",name:"3x"}],value:u,onChangeAction:this.handleInputChange})),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-sm-6"}),h.a.createElement(k.a,{label:"Opdracht nummer klant",name:"poNumber",value:d,onChangeAction:this.handleInputChange})),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"form-group col-sm-12"},h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-sm-3"},h.a.createElement("label",{htmlFor:"invoiceText",className:"col-sm-12"},"Opmerking")),h.a.createElement("div",{className:"col-sm-8"},h.a.createElement("textarea",{name:"invoiceText",value:m,onChange:this.handleInputChange,className:"form-control input-sm",maxLength:"1000"}))))),h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"Aanvraag datum",name:"dateRequested",value:p,onChangeAction:this.handleInputChangeDate}),h.a.createElement(j.a,{label:"Volgende nota datum",value:b,name:"dateNextInvoice",onChangeAction:this.handleInputChangeInvoiceDate})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Totaal bedrag incl. BTW",value:"€"+this.props.orderDetails.totalInclVatInclReductionPerYear.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),name:"totalInclVatInclReduction",readOnly:!0}))),h.a.createElement(_.a,null,h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Sluiten",onClickAction:this.props.switchToView}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:this.handleSubmit,type:"submit",value:"Submit"})))))}}]),a}(p.Component),W=Object(g.b)((function(e){return{orderStatuses:e.systemData.orderStatuses,orderPaymentTypes:e.systemData.orderPaymentTypes,orderCollectionFrequencies:e.systemData.orderCollectionFrequencies,orderDetails:e.orderDetails,administrations:e.meDetails.administrations}}),(function(e){return{updateOrder:function(t,a){e(Object(b.b)(t,a))}}}))(G),K=a(706),U=Object(g.b)((function(e){return{orderDetails:e.orderDetails}}))((function(e){var t=e.orderDetails,a=t.contact,r=t.project,n=t.administration,i=t.status,o=t.subject,c=t.emailTemplateCollection,l=t.emailTemplateTransfer,s=t.emailTemplateReminder,u=t.emailTemplateExhortation,d=t.paymentType,m=t.collectionFrequency,p=(t.IBAN,t.ibanAttn,t.numberOfInvoiceReminders),g=t.poNumber,b=t.invoiceText,f=t.dateRequested,v=t.totalInclVatInclReductionPerYear,y=t.dateNextInvoice;return h.a.createElement("div",{onClick:e.switchToEdit},h.a.createElement(T.a,null,h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Order op naam van",value:a?a.fullName:"",link:a?"contact/"+a.id:""}),h.a.createElement(K.a,{label:"Administratie",value:n.name,link:n?"administratie/"+n.id:""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Contact persoon",value:e.contactPerson}),h.a.createElement(K.a,{label:"Nota wordt gemaild naar",value:e.contactEmail})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Deelname",value:r?r.name:""}),h.a.createElement(K.a,{label:"Betreft",value:o||""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"E-mail template nota incasso",value:c?c.name:""}),h.a.createElement(K.a,{label:"Betaalwijze",value:d?d.name:""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"E-mail template nota overboeken",value:l?l.name:""}),h.a.createElement(K.a,{label:"Nota frequentie",value:m?m.name:""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"E-mail template herinnering",value:s?s.name:""}),h.a.createElement(K.a,{label:"Status",value:i?i.name:""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"E-mail template aanmaning",value:u?u.name:""}),h.a.createElement(K.a,{label:"Aantal keer herinneringen nota",value:1===p?"1x":2===p?"2x":3===p?"3x":""})),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-sm-6"}),h.a.createElement(K.a,{label:"Opdracht nummer klant",value:g})),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-sm-3"},h.a.createElement("label",{htmlFor:"invoiceText",className:"col-sm-12"},"Opmerking")),h.a.createElement("div",{className:"col-sm-9",id:"invoiceText"},b)),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Aanvraag datum",value:f?Y()(f).format("DD-MM-Y"):""}),h.a.createElement(K.a,{label:"Volgende nota datum",value:y?Y()(y).format("DD-MM-Y"):""})),h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Totaal bedrag incl. BTW",value:"€"+v.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2})})))))})),H=a(203);function X(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function J(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?X(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):X(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function Q(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var ee=function(e){l()(a,e);var t=Q(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"switchToEdit",(function(){r.props.orderDetails.canEdit?r.setState({showEdit:!0}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),E()(v()(r),"switchToView",(function(){r.setState({showEdit:!1,activeDiv:""})})),r.state={contactPerson:"",contactEmail:"",contactCollectMandate:!1,contactCollectMandateFirstRun:"0000-00-00",showEdit:!1,activeDiv:""},r}return o()(a,[{key:"componentDidMount",value:function(){var e=this;this.props.orderDetails.contactId&&q.a.fetchContactInfoForOrder(this.props.orderDetails.contactId).then((function(t){e.setState(J(J({},e.state),{},{contactPerson:t.data.contactPerson,contactEmail:t.data.email,contactCollectMandate:t.data.collectMandate,contactCollectMandateFirstRun:t.data.collectMandateFirstRun}))}))}},{key:"componentDidUpdate",value:function(e){var t=this;this.props.orderDetails.id!==e.orderDetails.id&&this.props.orderDetails.contactId&&q.a.fetchContactInfoForOrder(nextProps.orderDetails.contactId).then((function(e){t.setState(J(J({},t.state),{},{contactPerson:e.data.contactPerson,contactEmail:e.data.email,contactCollectMandate:e.data.collectMandate,contactCollectMandateFirstRun:e.data.collectMandateFirstRun}))}))}},{key:"onDivEnter",value:function(){this.setState({activeDiv:"panel-grey"})}},{key:"onDivLeave",value:function(){this.state.showEdit||this.setState({activeDiv:""})}},{key:"render",value:function(){var e=this,t=this.props.meDetails.permissions,a=void 0===t?{}:t;return h.a.createElement("div",{className:this.state.activeDiv,onMouseEnter:function(){return e.onDivEnter()},onMouseLeave:function(){return e.onDivLeave()}},this.state.showEdit&&this.props.orderDetails.canEdit&&a.manageFinancial?h.a.createElement(W,{switchToView:this.switchToView,contactPerson:this.state.contactPerson,contactEmail:this.state.contactEmail,contactCollectMandate:this.state.contactCollectMandate,contactCollectMandateFirstRun:this.state.contactCollectMandateFirstRun}):h.a.createElement(U,{switchToEdit:this.switchToEdit,contactPerson:this.state.contactPerson,contactEmail:this.state.contactEmail}))}}]),a}(p.Component),te=Object(g.b)((function(e){return{orderDetails:e.orderDetails,meDetails:e.meDetails}}),(function(e){return{setError:function(t,a){e(Object(H.b)(t,a))}}}))(ee);Y.a.locale("nl");var ae=Object(g.b)((function(e){return{orderDetails:e.orderDetails}}))((function(e){var t=e.orderDetails,a=t.createdAt,r=t.createdBy;return h.a.createElement("div",null,h.a.createElement("div",{className:"row"},h.a.createElement(K.a,{label:"Gemaakt door",value:r?r.fullName:"Onbekend",link:r?"gebruiker/"+r.id:""}),h.a.createElement(K.a,{label:"Gemaakt op",value:a?Y()(a).format("L"):"Onbekend"})))})),re=a(709),ne=function(e){return h.a.createElement(T.a,null,h.a.createElement(re.a,null,h.a.createElement("span",{className:"h5 text-bold"},"Afsluiting gegevens")),h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-md-12"},h.a.createElement(ae,null))))};Y.a.locale("nl");var ie=Object(g.b)((function(e){return{permissions:e.meDetails.permissions,orderDetails:e.orderDetails}}))((function(e){var t=e.orderProduct,a=t.product,r=t.amount,n=t.amountInclReductionInclVat,i=t.dateStart,o=t.dateEnd,c=t.amountInclReductionInclVatPerYear,l=t.isOneTimeAndPaidProduct,s=t.period,u=Y()(Y()().format("YYYY-MM-DD")).isAfter(Y()(o).format("YYYY-MM-DD")),d=l?"paid-order-product-row":"",m=u?"not-active-anymore-row":"",p=u?"not-active-anymore-text":"";return h.a.createElement("div",{className:"row border ".concat(e.highlightLine," ").concat(d," ").concat(m),onMouseEnter:function(){return e.onLineEnter()},onMouseLeave:function(){return e.onLineLeave()}},h.a.createElement("div",{onClick:e.openEdit},h.a.createElement("div",{className:"col-sm-1"},a&&a.code),h.a.createElement("div",{className:"col-sm-2"},a?a.invoiceText:""),h.a.createElement("div",{className:"col-sm-1"},r||""),h.a.createElement("div",{className:"col-sm-2"},n?"€"+n.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}):"€0,00"),h.a.createElement("div",{className:"col-sm-2"},a.invoiceFrequency?a.invoiceFrequency.name:""),h.a.createElement("div",{className:"col-sm-1"},c?"€"+c.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}):"€0,00"),h.a.createElement("div",{className:"col-sm-1"},i?Y()(i).format("L"):""),h.a.createElement("div",{className:"col-sm-1 ".concat(p)},o?Y()(o).format("L"):"")),h.a.createElement("div",{className:"col-sm-1"},e.showActionButtons&&e.permissions.manageFinancial?h.a.createElement("a",{role:"button",onClick:e.openEdit},h.a.createElement("span",{className:"glyphicon glyphicon-pencil mybtn-success"})," "):"",e.showActionButtons&&e.permissions.manageFinancial?h.a.createElement("a",{role:"button",onClick:e.toggleDelete},h.a.createElement("span",{className:"glyphicon glyphicon-trash mybtn-danger"})," "):""),s&&h.a.createElement("div",{className:"col-sm-12"},"Periode ",s))}));Y.a.locale("nl");var oe=Object(g.b)((function(e){return{costCenters:e.systemData.costCenters}}))((function(e){var t=e.orderProduct,a=t.product,r=t.costCenterId,n=t.amount,i=t.amountReduction,o=t.percentageReduction,c=t.dateStart,l=t.dateEnd,s=t.dateLastInvoice,u=t.datePeriodStartFirstInvoice,d=t.variablePrice;return h.a.createElement("div",null,h.a.createElement("form",{className:"form-horizontal",onSubmit:e.handleSubmit},h.a.createElement(T.a,{className:"panel-grey"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Ordernummer",name:"order",value:e.orderDetails?e.orderDetails.number:"",readOnly:!0}),h.a.createElement(k.a,{label:"Product",name:"product",value:a?a.name:"",readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(F.a,{label:"Kostenplaats",id:"costCenterId",name:"costCenterId",options:e.costCenters,optionName:"description",value:r,onChangeAction:e.handleInputChange})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Omschrijving",id:"description",name:"description",value:a.invoiceText,readOnly:!0}),h.a.createElement(k.a,{label:"Aantal",type:"number",id:"amount",name:"amount",value:n,onChangeAction:e.handleInputChange,required:"required",error:e.errors.amount})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingspercentage",type:"number",id:"percentageReduction",name:"percentageReduction",value:o,onChangeAction:e.handleInputChange}),null!==d?h.a.createElement(k.a,{label:"Prijs excl. BTW",name:"variablePrice",type:"number",value:d,onChangeAction:e.handleInputChangeVariablePrice,error:e.errors.variablePrice,required:null!==d&&"required"}):h.a.createElement(k.a,{label:e.orderProduct.product.currentPrice.inputInclVat?"Prijs incl. BTW":"Prijs excl. BTW",name:"price",value:e.orderProduct.product.currentPrice.inputInclVat?"€"+e.orderProduct.product.currentPrice.priceInclVat.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:e.orderProduct.product.currentPrice.priceNumberOfDecimals}):"€"+e.orderProduct.product.currentPrice.price.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:e.orderProduct.product.currentPrice.priceNumberOfDecimals}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingsbedrag",type:"number",id:"amountReduction",name:"amountReduction",value:i,onChangeAction:e.handleInputChange}),h.a.createElement(k.a,{label:"Totaalbedrag incl. BTW",name:"totalPrice",value:"€"+e.totalPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"Begin datum",name:"dateStart",value:c,onChangeAction:e.handleInputChangeStartDate,required:"required",error:e.errors.dateStart}),h.a.createElement(j.a,{label:"Eind datum",name:"dateEnd",readOnly:"none"===a.durationId,value:l,onChangeAction:e.handleInputChangeDate,error:e.errors.dateEnd})),!s&&"none"!==a.durationId&&h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"1ste notaperiode start op",name:"datePeriodStartFirstInvoice",value:u,onChangeAction:e.handleInputChangeDate})),h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Annuleren",onClickAction:e.cancelEdit}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:e.handleSubmit,type:"submit",value:"Submit"}))))))})),ce=Object(g.b)(null,(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))((function(e){return h.a.createElement(P.a,{buttonConfirmText:"Verwijder",buttonClassName:"btn-danger",closeModal:e.closeDeleteItemModal,confirmAction:function(){q.a.deleteOrderProduct(e.id).then((function(t){e.fetchOrderDetails(e.orderId),e.closeDeleteItemModal()}))},title:"Verwijderen"},h.a.createElement("p",null,"Verwijder orderregel?"))}));function le(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function se(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?le(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):le(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function ue(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var de=function(e){l()(a,e);var t=ue(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(se(se({},r.state),{},{orderProduct:se(se({},r.state.orderProduct),{},E()({},n,a))}),r.updateOrderPrice)})),E()(v()(r),"handleLedgerChange",(function(e){r.setState(se(se({},r.state),{},{product:se(se({},r.state.product),{},{ledgerId:e})}),r.updateOrderPrice)})),E()(v()(r),"handleCostCenterChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(se(se({},r.state),{},{product:se(se({},r.state.product),{},E()({},n,a))}))})),E()(v()(r),"handleInputChangeProduct",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(se(se({},r.state),{},{product:se(se({},r.state.product),{},E()({},n,a))}))})),E()(v()(r),"updateOrderPrice",(function(){var e=!!r.state.product.currentPrice.inputInclVat&&r.state.product.currentPrice.inputInclVat,t=0;t=e?w.a.isFloat(r.state.product.currentPrice.priceInclVat+"")?r.state.product.currentPrice.priceInclVat:0:w.a.isFloat(r.state.product.currentPrice.price+"")?r.state.product.currentPrice.price:0;var a=w.a.isFloat(r.state.orderProduct.amount+"")?r.state.orderProduct.amount:0,n=w.a.isFloat(r.state.orderProduct.percentageReduction+"")?r.state.orderProduct.percentageReduction:0,i=w.a.isFloat(r.state.orderProduct.amountReduction+"")?r.state.orderProduct.amountReduction:0,o=0;t<0?o=t*a*((parseFloat(100)+parseFloat(n))/100)-i:o=t*a*((100-n)/100)-i;if(!e){var c=w.a.isFloat(r.state.product.currentPrice.vatPercentage+"")?r.state.product.currentPrice.vatPercentage:0;o*=(parseFloat(100)+parseFloat(c))/100}r.setState(se(se({},r.state),{},{totalPrice:parseFloat(o).toFixed(2)}))})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t=r.state.orderProduct,a={},n=!1;w.a.isEmpty(t.amount+"")&&(a.amount=!0,n=!0);var i=r.state.product;w.a.isEmpty(i.description)&&(a.description=!0,n=!0),r.props.usesTwinfield&&w.a.isEmpty(String(i.ledgerId))&&(a.ledgerId=!0,n=!0),r.setState(se(se({},r.state),{},{errors:a,errorMessage:!1})),!n&&q.a.updateOrderProductOneTime(t,i).then((function(e){r.props.fetchOrderDetails(r.props.orderProduct.orderId),r.props.cancelEdit()}))})),r.state={errorMessage:!1,orderPrice:e.product.currentPrice.inputInclVat?e.product.currentPrice.priceInclVat:e.product.currentPrice.price,totalPrice:"",orderProduct:{id:e.orderProduct.id,amount:e.orderProduct.amount,amountReduction:e.orderProduct.amountReduction,percentageReduction:e.orderProduct.percentageReduction,dateStart:e.orderProduct.dateStart,dateEnd:e.orderProduct.dateEnd,datePeriodStartFirstInvoice:e.orderProduct.datePeriodStartFirstInvoice},product:{id:e.product.id,description:e.product.invoiceText,ledgerId:e.product.ledgerId?e.product.ledgerId:"",costCenterId:e.product.costCenterId?e.product.costCenterId:"",currentPrice:e.product.currentPrice?e.product.currentPrice:""},errors:{amount:!1,ledgerId:!1,description:!1}},r}return o()(a,[{key:"componentDidMount",value:function(){this.updateOrderPrice()}},{key:"render",value:function(){var e=this,t=this.state.orderProduct,a=t.amount,r=t.amountReduction,n=t.percentageReduction,i=this.state.product,o=i.description,c=i.costCenterId,l=i.ledgerId,s=this.props.ledgers.filter((function(t){return t.vatCode?t.vatCode.percentage===e.state.product.currentPrice.vatPercentage:t.vatCode===e.state.product.currentPrice.vatPercentage}));return h.a.createElement("form",{className:"form-horizontal",onSubmit:this.handleSubmit},h.a.createElement(T.a,{className:"panel-grey"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Product"))),this.props.usesTwinfield?h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"Grootboek",name:"ledgerId",id:"ledgerId",options:s,optionName:"description",value:l,onChangeAction:this.handleLedgerChange,required:"required",error:this.state.errors.ledgerId}),h.a.createElement(F.a,{label:"Kostenplaats",id:"costCenterId",name:"costCenterId",options:this.props.costCenters,optionName:"description",value:c,onChangeAction:this.handleCostCenterChange})):null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-part panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Orderregel"))),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Omschrijving",id:"description",name:"description",value:o,onChangeAction:this.handleInputChangeProduct,required:"required",error:this.state.errors.description}),h.a.createElement(k.a,{label:"Aantal",type:"number",id:"amount",name:"amount",value:a,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.amount})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingspercentage",type:"number",id:"percentageReduction",name:"percentageReduction",value:n,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:this.state.product.currentPrice.inputInclVat?"Prijs incl. BTW":"Prijs excl. BTW",name:"orderPrice",value:"€"+this.state.orderPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:this.state.product.currentPrice.priceNumberOfDecimals}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingsbedrag",type:"number",id:"amountReduction",name:"amountReduction",value:r,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:"Totaalbedrag incl. BTW",name:"totalPrice",value:"€"+this.state.totalPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),readOnly:!0})),this.state.errorMessage&&h.a.createElement("div",{className:"col-sm-10 col-md-offset-1 alert alert-danger"},this.state.errorMessage),h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Annuleren",onClickAction:this.props.cancelEdit}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:this.handleSubmit,type:"submit",value:"Submit"})))))}}]),a}(p.Component),me=Object(g.b)((function(e){return{orderDetails:e.orderDetails,costCenters:e.systemData.costCenters,ledgers:e.systemData.ledgers,usesTwinfield:e.systemData.usesTwinfield}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))(de);function pe(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function he(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?pe(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):pe(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function ge(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var be=function(e){l()(a,e);var t=ge(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"toggleDelete",(function(){r.props.orderDetails.canEdit?r.setState({showDelete:!r.state.showDelete}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),E()(v()(r),"onLineEnter",(function(){r.setState({showActionButtons:!0,highlightLine:"highlight-line"})})),E()(v()(r),"onLineLeave",(function(){r.setState({showActionButtons:!1,highlightLine:""})})),E()(v()(r),"openEdit",(function(){r.props.orderDetails.canEdit?r.setState({showEdit:!0}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),E()(v()(r),"closeEdit",(function(){r.setState({showEdit:!1})})),E()(v()(r),"cancelEdit",(function(){r.setState(he(he({},r.state),{},{orderProduct:he({},r.props.orderProduct)})),r.closeEdit()})),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(he(he({},r.state),{},{orderProduct:he(he({},r.state.orderProduct),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"updatePrice",(function(){var e=!1,t=0;r.state.orderProduct.product.currentPrice&&(e=r.state.orderProduct.product.currentPrice.inputInclVat,t=w.a.isFloat(r.state.orderProduct.product.currentPrice.vatPercentage+"")?r.state.orderProduct.product.currentPrice.vatPercentage:0);var a=(parseFloat(100)+parseFloat(t))/100,n=0,i=0,o=w.a.isFloat(r.state.orderProduct.variablePrice+"")?r.state.orderProduct.variablePrice:0;o?e?(n=o,i=o/a):(n=o*a,i=o):r.state.orderProduct.product.currentPrice&&(n=w.a.isFloat(r.state.orderProduct.product.currentPrice.priceInclVat+"")?r.state.orderProduct.product.currentPrice.priceInclVat:0,i=w.a.isFloat(r.state.orderProduct.product.currentPrice.price+"")?r.state.orderProduct.product.currentPrice.price:0);var c=w.a.isFloat(r.state.orderProduct.amount+"")?r.state.orderProduct.amount:0,l=parseFloat(n*c).toFixed(2),s=parseFloat(i*c).toFixed(2),u=w.a.isFloat(r.state.orderProduct.amountReduction+"")?r.state.orderProduct.amountReduction:0;e||(u*=a),u=parseFloat(u).toFixed(2);var d=(w.a.isFloat(r.state.orderProduct.percentageReduction+"")?r.state.orderProduct.percentageReduction:0)/100,m=0;e?m=l*d:(m=s*d,m*=a);var p=l-u-(m=parseFloat(m).toFixed(2));r.setState(he(he({},r.state),{},{totalPrice:p}))})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t={},a=!1,n=r.state.orderProduct;w.a.isEmpty(n.amount+"")&&(t.amount=!0,a=!0),w.a.isEmpty(n.dateStart+"")&&(t.dateStart=!0,a=!0),!w.a.isEmpty(n.dateStart+"")&&Y()(n.dateEnd).isSameOrBefore(Y()(n.dateStart))&&(t.dateEnd=!0,a=!0),!w.a.isEmpty(n.dateEnd+"")&&Y()(n.dateStart).isSameOrAfter(Y()(n.dateEnd))&&(t.dateStart=!0,a=!0),null!==r.props.orderProduct.variablePrice&&(w.a.isEmpty(n.variablePrice+"")||null===n.variablePrice)&&(t.variablePrice=!0,a=!0),r.setState(he(he({},r.state),{},{errors:t})),!a&&q.a.updateOrderProduct(n).then((function(e){r.props.fetchOrderDetails(r.state.orderProduct.orderId),r.closeEdit()}))})),E()(v()(r),"handleInputChangeVariablePrice",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(he(he({},r.state),{},{price:a,orderProduct:he(he({},r.state.orderProduct),{},E()({},n,a))}),r.updatePrice)})),r.state={showActionButtons:!1,highlightLine:"",showEdit:!1,showDelete:!1,totalPrice:e.orderProduct.amountInclReductionInclVat,orderProduct:he({},e.orderProduct),errors:{amount:!1,dateStart:!1,dateEnd:!1,variablePrice:!1}},r.handleInputChangeDate=r.handleInputChangeDate.bind(v()(r)),r.handleInputChangeStartDate=r.handleInputChangeStartDate.bind(v()(r)),r}return o()(a,[{key:"componentWillReceiveProps",value:function(e){Object(S.isEqual)(this.state.orderProduct,e.orderProduct)||this.setState(he(he({},this.state),{},{orderProduct:he({},e.orderProduct)}))}},{key:"handleInputChangeDate",value:function(e,t){this.setState(he(he({},this.state),{},{orderProduct:he(he({},this.state.orderProduct),{},E()({},t,e))}))}},{key:"handleInputChangeStartDate",value:function(e,t){var a,r="";if(e)switch(this.state.orderProduct.product.durationId){case"none":r="";break;case"month":r=Y()(e).add(1,"M").format("YYYY-MM-DD");break;case"quarter":r=Y()(e).add(1,"Q").format("YYYY-MM-DD");break;case"half_year":r=Y()(e).add(6,"M").format("YYYY-MM-DD");break;case"year":r=Y()(e).add(1,"y").format("YYYY-MM-DD");break;case"until_cancellation":r="";break;default:r=""}this.setState(he(he({},this.state),{},{orderProduct:he(he({},this.state.orderProduct),{},(a={},E()(a,t,e),E()(a,"dateEnd",r),a))}))}},{key:"render",value:function(){return h.a.createElement("div",null,h.a.createElement(ie,{highlightLine:this.state.highlightLine,showActionButtons:this.state.showActionButtons,onLineEnter:this.onLineEnter,onLineLeave:this.onLineLeave,openEdit:this.openEdit,toggleDelete:this.toggleDelete,orderProduct:this.state.orderProduct}),this.state.showEdit&&this.props.orderDetails.canEdit&&this.props.permissions.manageFinancial&&!this.state.orderProduct.product.isOneTime&&h.a.createElement(oe,{orderDetails:this.props.orderDetails,errors:this.state.errors,totalPrice:this.state.totalPrice,orderProduct:this.state.orderProduct,handleInputChange:this.handleInputChange,handleInputChangeDate:this.handleInputChangeDate,handleInputChangeStartDate:this.handleInputChangeStartDate,handleSubmit:this.handleSubmit,cancelEdit:this.cancelEdit,handleInputChangeVariablePrice:this.handleInputChangeVariablePrice}),this.state.showEdit&&this.props.orderDetails.canEdit&&this.props.permissions.manageFinancial&&1==this.state.orderProduct.product.isOneTime&&h.a.createElement(me,{orderProduct:this.state.orderProduct,product:this.state.orderProduct.product,cancelEdit:this.cancelEdit}),this.state.showDelete&&this.props.orderDetails.canEdit&&this.props.permissions.manageFinancial&&h.a.createElement(ce,{closeDeleteItemModal:this.toggleDelete,id:this.state.orderProduct.id,orderId:this.state.orderProduct.orderId}))}}]),a}(p.Component),fe=Object(g.b)((function(e){return{permissions:e.meDetails.permissions,orderDetails:e.orderDetails}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))},setError:function(t,a){e(Object(H.b)(t,a))}}}))(be),ve=Object(g.b)((function(e){return{orderProducts:e.orderDetails.orderProducts}}))((function(e){return h.a.createElement("div",null,h.a.createElement("div",{className:"row border header"},h.a.createElement("div",{className:"col-sm-1"},"Productcode"),h.a.createElement("div",{className:"col-sm-2"},"Omschrijving"),h.a.createElement("div",{className:"col-sm-1"},"Aantal"),h.a.createElement("div",{className:"col-sm-2"},"Prijs incl. BTW"),h.a.createElement("div",{className:"col-sm-2"},"Prijs per"),h.a.createElement("div",{className:"col-sm-1"},"Prijs incl. BTW/jaar"),h.a.createElement("div",{className:"col-sm-1"},"Begin datum"),h.a.createElement("div",{className:"col-sm-1"},"Eind datum"),h.a.createElement("div",{className:"col-sm-1"})),e.orderProducts.length>0?e.orderProducts.map((function(e){return h.a.createElement(fe,{key:e.id,orderProduct:e})})):h.a.createElement("div",null,"Geen orderregels bekend."))}));function ye(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Ee(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?ye(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):ye(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function Ie(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var Ne=function(e){l()(a,e);var t=Ie(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Ee(Ee({},r.state),{},{orderProduct:Ee(Ee({},r.state.orderProduct),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleInputChangeVariablePrice",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Ee(Ee({},r.state),{},{price:a,orderProduct:Ee(Ee({},r.state.orderProduct),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleBlurVariablePrice",(function(e){var t=e.target,a=t.value;t.name;r.setState(Ee(Ee({},r.state),{},{orderProduct:Ee(Ee({},r.state.orderProduct),{},{variablePrice:parseFloat(a).toFixed(r.state.priceNumberOfDecimals)})}))})),E()(v()(r),"updatePrice",(function(){var e,t;e=r.state.productInputInclVat,t=w.a.isFloat(r.state.vatPercentage+"")?r.state.vatPercentage:0;var a=(parseFloat(100)+parseFloat(t))/100,n=0,i=0,o=w.a.isFloat(r.state.orderProduct.variablePrice+"")?r.state.orderProduct.variablePrice:0;o?e?(n=o,i=o/a):(n=o*a,i=o):(n=w.a.isFloat(r.state.priceInclVat+"")?r.state.priceInclVat:0,i=w.a.isFloat(r.state.price+"")?r.state.price:0);var c=w.a.isFloat(r.state.orderProduct.amount+"")?r.state.orderProduct.amount:0,l=parseFloat(n*c).toFixed(2),s=parseFloat(i*c).toFixed(2),u=w.a.isFloat(r.state.orderProduct.amountReduction+"")?r.state.orderProduct.amountReduction:0;e||(u*=a),u=parseFloat(u).toFixed(2);var d=(w.a.isFloat(r.state.orderProduct.percentageReduction+"")?r.state.orderProduct.percentageReduction:0)/100,m=0;e?m=l*d:(m=s*d,m*=a);var p=l-u-(m=parseFloat(m).toFixed(2));r.setState(Ee(Ee({},r.state),{},{totalPrice:p}))})),E()(v()(r),"handleChangeProduct",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name,i=2,o=0,c=0,l=0,s="",u="",d=!1,m="",p="",h=!1;if(a){var g=r.props.products.find((function(e){return e.id==a}));i=g.currentPrice.priceNumberOfDecimals,o=g.currentPrice.price,c=g.currentPrice.priceInclVat,l=g.currentPrice.vatPercentage,h=g.currentPrice.inputInclVat,(s=g.costCenterId)||(s=""),u=g.invoiceText,d=g.durationId,p=g.hasVariablePrice}if(d&&r.state.orderProduct.dateStart)switch(d){case"none":m="";break;case"month":m=Y()(r.state.orderProduct.dateStart).add(1,"M").format("YYYY-MM-DD");break;case"quarter":m=Y()(r.state.orderProduct.dateStart).add(1,"Q").format("YYYY-MM-DD");break;case"half_year":m=Y()(r.state.orderProduct.dateStart).add(6,"M").format("YYYY-MM-DD");break;case"year":m=Y()(r.state.orderProduct.dateStart).add(1,"y").format("YYYY-MM-DD");break;case"until_cancellation":m="";break;default:m=""}r.setState(Ee(Ee({},r.state),{},{priceNumberOfDecimals:i,price:o,priceInclVat:c,vatPercentage:l,durationId:d,productHasVariablePrice:"variable"===p,productInputInclVat:h,orderProduct:Ee(Ee({},r.state.orderProduct),{},E()({costCenterId:s,description:u,dateEnd:m},n,a))}),r.updatePrice)})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t=r.state.orderProduct,a={},n=!1;w.a.isEmpty(t.productId+"")&&(a.productId=!0,n=!0),w.a.isEmpty(t.amount+"")&&(a.amount=!0,n=!0),w.a.isEmpty(t.dateStart+"")&&(a.dateStart=!0,n=!0),w.a.isEmpty(t.datePeriodStartFirstInvoice+"")&&(a.datePeriodStartFirstInvoice=!0,n=!0),!w.a.isEmpty(t.dateStart+"")&&Y()(t.dateEnd).isSameOrBefore(Y()(t.dateStart))&&(a.dateEnd=!0,n=!0),!w.a.isEmpty(t.dateEnd+"")&&Y()(t.dateStart).isSameOrAfter(Y()(t.dateEnd))&&(a.dateStart=!0,n=!0),r.state.productHasVariablePrice&&(w.a.isEmpty(t.variablePrice+"")||null===t.variablePrice)&&(a.variablePrice=!0,n=!0),r.setState(Ee(Ee({},r.state),{},{errors:a})),!n&&q.a.newOrderProduct(t).then((function(e){r.props.fetchOrderDetails(t.orderId),r.props.toggleShowNew()}))})),r.state={priceNumberOfDecimals:"2",price:"0",priceInclVat:"0",vatPercentage:"0",totalPrice:"0",durationId:"none",productHasVariablePrice:!1,productInputInclVat:!1,orderProduct:{orderId:r.props.orderDetails.id,productId:"",description:"",costCenterId:"",amount:1,amountReduction:0,percentageReduction:0,dateStart:Y()().format("YYYY-MM-DD"),dateEnd:"",datePeriodStartFirstInvoice:Y()().format("YYYY-MM-DD"),variablePrice:null},errors:{productId:!1,amount:!1,dateStart:!1,dateEnd:!1,datePeriodStartFirstInvoice:!1,variablePrice:!1}},r.handleInputChangeDate=r.handleInputChangeDate.bind(v()(r)),r.handleInputChangeStartDate=r.handleInputChangeStartDate.bind(v()(r)),r}return o()(a,[{key:"handleInputChangeDate",value:function(e,t){this.setState(Ee(Ee({},this.state),{},{orderProduct:Ee(Ee({},this.state.orderProduct),{},E()({},t,e))}))}},{key:"handleInputChangeStartDate",value:function(e,t){var a,r=this,n="";if(this.state.orderProduct.dateStart&&this.state.orderProduct.productId){var i;if(e)i=this.props.products.filter((function(e){return e.id==r.state.orderProduct.productId}))[0].durationId;switch(i){case"none":n="";break;case"month":n=Y()(e).add(1,"M").format("YYYY-MM-DD");break;case"quarter":n=Y()(e).add(1,"Q").format("YYYY-MM-DD");break;case"half_year":n=Y()(e).add(6,"M").format("YYYY-MM-DD");break;case"year":n=Y()(e).add(1,"y").format("YYYY-MM-DD");break;case"until_cancellation":n="";break;default:n=""}}this.setState(Ee(Ee({},this.state),{},{orderProduct:Ee(Ee({},this.state.orderProduct),{},(a={},E()(a,t,e),E()(a,"dateEnd",n),a))}))}},{key:"render",value:function(){var e=this.state.orderProduct,t=e.productId,a=e.description,r=e.costCenterId,n=e.amount,i=e.amountReduction,o=e.percentageReduction,c=e.dateStart,l=e.dateEnd,s=e.datePeriodStartFirstInvoice;return h.a.createElement("form",{className:"form-horizontal",onSubmit:this.handleSubmit},h.a.createElement(T.a,{className:"panel-grey"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Order nummer",name:"orderId",value:this.props.orderDetails.number,readOnly:!0}),h.a.createElement(F.a,{label:"Product",id:"productId",name:"productId",options:this.props.products.filter((function(e){return e.active})).sort((function(e,t){return e.name.localeCompare(t.name)})),value:t,onChangeAction:this.handleChangeProduct,required:"required",error:this.state.errors.productId})),h.a.createElement("div",{className:"row"},h.a.createElement(F.a,{label:"Kostenplaats",id:"costCenterId",name:"costCenterId",options:this.props.costCenters,optionName:"description",value:r,onChangeAction:this.handleInputChange})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Omschrijving",id:"description",name:"description",value:a,readOnly:!0}),h.a.createElement(k.a,{label:"Aantal",type:"number",id:"amount",name:"amount",value:n,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.amount})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingspercentage",type:"number",id:"percentageReduction",name:"percentageReduction",value:o,onChangeAction:this.handleInputChange}),this.state.productHasVariablePrice?h.a.createElement(k.a,{label:"Prijs excl. BTW",name:"variablePrice",type:"number",value:this.state.price,onChangeAction:this.handleInputChangeVariablePrice,onBlurAction:this.handleBlurVariablePrice,error:this.state.errors.variablePrice,required:this.state.productHasVariablePrice&&"required"}):h.a.createElement(k.a,{label:this.state.productInputInclVat?"Prijs incl. BTW":"Prijs excl. BTW",name:"price",value:this.state.productInputInclVat?"€"+this.state.priceInclVat.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:this.state.priceNumberOfDecimals}):"€"+this.state.price.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:this.state.priceNumberOfDecimals}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingsbedrag",type:"number",id:"amountReduction",name:"amountReduction",value:i,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:"Totaalbedrag incl. BTW",name:"totalPrice",value:"€"+this.state.totalPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"Begin datum",name:"dateStart",value:c,onChangeAction:this.handleInputChangeStartDate,required:"required",error:this.state.errors.dateStart}),h.a.createElement(j.a,{label:"Eind datum",name:"dateEnd",value:l,onChangeAction:this.handleInputChangeDate,error:this.state.errors.dateEnd,readOnly:"none"===this.state.durationId})),"none"!==this.state.durationId&&h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"1ste notaperiode start op",name:"datePeriodStartFirstInvoice",value:s,onChangeAction:this.handleInputChangeDate,error:this.state.errors.datePeriodStartFirstInvoice,required:"required"})),h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Annuleren",onClickAction:this.props.toggleShowNew}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:this.handleSubmit,type:"submit",value:"Submit"})))))}}]),a}(p.Component),Pe=Object(g.b)((function(e){return{orderDetails:e.orderDetails,products:e.systemData.products,costCenters:e.systemData.costCenters}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))(Ne),Ae=a(712);function Ce(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Re(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Ce(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Ce(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function De(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var xe=function(e){l()(a,e);var t=De(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Re(Re({},r.state),{},{orderProduct:Re(Re({},r.state.orderProduct),{},E()({},n,a))}),r.updateOrderPrice)})),E()(v()(r),"handleLedgerChange",(function(e){var t=r.props.ledgers.find((function(t){return t.id===e})),a=t.vatCode&&t.vatCode.percentage;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},{ledgerId:e,vatPercentage:a})}),r.updatePrice)})),E()(v()(r),"handleCostCenterChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},n,a))}))})),E()(v()(r),"handleInputChangeProduct",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleInputChangeProductDuration",(function(e){var t,a=e.target,n="checkbox"===a.type?a.checked:a.value,i=a.name;if(r.state.orderProduct.dateStart)switch(n){case"none":t="";break;case"month":t=Y()(r.state.orderProduct.dateStart).add(1,"M").format("YYYY-MM-DD");break;case"quarter":t=Y()(r.state.orderProduct.dateStart).add(1,"Q").format("YYYY-MM-DD");break;case"half_year":t=Y()(r.state.orderProduct.dateStart).add(6,"M").format("YYYY-MM-DD");break;case"year":t=Y()(r.state.orderProduct.dateStart).add(1,"y").format("YYYY-MM-DD");break;case"until_cancellation":t="";break;default:t=""}r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},i,n)),orderProduct:Re(Re({},r.state.orderProduct),{},{dateEnd:t})}))})),E()(v()(r),"handleInputChangeProductVat",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleInputChangeProductPrice",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleBlurProductPrice",(function(e){var t=e.target,a=t.value,n=t.name;r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},E()({},n,parseFloat(a).toFixed(r.state.product.priceNumberOfDecimals)))}))})),E()(v()(r),"handleBlurDecimals",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=(t.name,a);n<2&&(n=2),n>6&&(n=6),r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},{priceNumberOfDecimals:n,price:parseFloat(r.state.product.price).toFixed(n),priceInclVat:parseFloat(r.state.product.priceInclVat).toFixed(n)})}),r.updatePrice)})),E()(v()(r),"updatePrice",(function(){var e=!!r.state.product.inputInclVat&&r.state.product.inputInclVat,t=w.a.isFloat(r.state.product.price+"")?r.state.product.price:0,a=w.a.isFloat(r.state.product.priceInclVat+"")?r.state.product.priceInclVat:0,n=w.a.isFloat(r.state.product.vatPercentage+"")?r.state.product.vatPercentage:0,i=(parseFloat(100)+parseFloat(n))/100;e?(t=a/i,r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},{price:parseFloat(t).toFixed(r.state.product.priceNumberOfDecimals)})}),r.updateOrderPrice)):(a=t*i,r.setState(Re(Re({},r.state),{},{product:Re(Re({},r.state.product),{},{priceInclVat:parseFloat(a).toFixed(r.state.product.priceNumberOfDecimals)})}),r.updateOrderPrice))})),E()(v()(r),"updateOrderPrice",(function(){var e,t;e=r.state.product.inputInclVat,t=w.a.isFloat(r.state.product.vatPercentage+"")?r.state.product.vatPercentage:0;var a=(parseFloat(100)+parseFloat(t))/100,n=w.a.isFloat(r.state.product.priceInclVat+"")?r.state.product.priceInclVat:0,i=w.a.isFloat(r.state.product.price+"")?r.state.product.price:0,o=w.a.isFloat(r.state.orderProduct.amount+"")?r.state.orderProduct.amount:0,c=parseFloat(n*o).toFixed(2),l=parseFloat(i*o).toFixed(2),s=0;s=e?n:i;var u=w.a.isFloat(r.state.orderProduct.amountReduction+"")?r.state.orderProduct.amountReduction:0;e||(u*=a),u=parseFloat(u).toFixed(2);var d=(w.a.isFloat(r.state.orderProduct.percentageReduction+"")?r.state.orderProduct.percentageReduction:0)/100,m=0;e?m=c*d:(m=l*d,m*=a);var p=c-u-(m=parseFloat(m).toFixed(2));r.setState(Re(Re({},r.state),{},{orderPrice:parseFloat(s).toFixed(r.state.product.priceNumberOfDecimals),totalPrice:parseFloat(p).toFixed(2)}))})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t=r.state.orderProduct,a={},n=!1,i=!1;w.a.isEmpty(t.amount+"")&&(a.amount=!0,n=!0),w.a.isEmpty(t.dateStart+"")&&(a.dateStart=!0,n=!0),!w.a.isEmpty(t.dateStart+"")&&Y()(t.dateEnd).isSameOrBefore(Y()(t.dateStart))&&(a.dateEnd=!0,n=!0),!w.a.isEmpty(t.dateEnd+"")&&Y()(t.dateStart).isSameOrAfter(Y()(t.dateEnd))&&(a.dateStart=!0,n=!0),w.a.isEmpty(t.datePeriodStartFirstInvoice+"")&&(a.datePeriodStartFirstInvoice=!0,n=!0);var o=r.state.product,c=!1;r.props.products.map((function(e){return e.code==o.code&&(c=!0)})),c&&(i="Productcode moet uniek zijn.",a.code=!0,n=!0),w.a.isEmpty(o.code+"")&&(a.code=!0,n=!0);var l=!1;r.props.products.map((function(e){return e.name==o.name&&(l=!0)})),l&&(i="Productnaam moet uniek zijn.",a.name=!0,n=!0),c&&l&&(i="Productcode en productnaam moeten uniek zijn."),w.a.isEmpty(o.name+"")&&(a.name=!0,n=!0),w.a.isEmpty(o.administrationId+"")&&(a.administrationId=!0,n=!0),o.inputInclVat?w.a.isEmpty(o.priceInclVat+"")&&(a.priceInclVat=!0,n=!0):w.a.isEmpty(o.price+"")&&(a.price=!0,n=!0),r.props.usesTwinfield&&w.a.isEmpty(String(o.ledgerId))&&(a.ledgerId=!0,n=!0),w.a.isEmpty(o.description)&&(a.description=!0,n=!0),r.setState(Re(Re({},r.state),{},{errors:a,errorMessage:i})),!n&&q.a.newProductAndOrderProduct(t,o).then((function(e){r.props.fetchOrderDetails(t.orderId),r.props.toggleShowNewProduct()}))})),r.state={errorMessage:!1,orderPrice:"",totalPrice:"",orderProduct:{orderId:r.props.orderDetails.id,amount:1,amountReduction:0,percentageReduction:0,dateStart:Y()().format("YYYY-MM-DD"),dateEnd:"",datePeriodStartFirstInvoice:Y()().format("YYYY-MM-DD")},product:{code:"",name:"",durationId:"none",description:"",administrationId:r.props.orderDetails.administrationId,invoiceFrequencyId:r.props.orderDetails.collectionFrequencyId?r.props.orderDetails.collectionFrequencyId:"once",vatPercentage:"",inputInclVat:!1,priceNumberOfDecimals:2,price:"",priceInclVat:"",ledgerId:"",costCenterId:"",isOneTime:!1},errors:{amount:!1,dateStart:!1,dateEnd:!1,code:!1,name:!1,priceNumberOfDecimals:!1,price:!1,priceInclVat:!1,datePeriodStartFirstInvoice:!1,ledgerId:!1,description:!1}},r.handleInputChangeDate=r.handleInputChangeDate.bind(v()(r)),r.handleInputChangeStartDate=r.handleInputChangeStartDate.bind(v()(r)),r}return o()(a,[{key:"handleInputChangeDate",value:function(e,t){this.setState(Re(Re({},this.state),{},{orderProduct:Re(Re({},this.state.orderProduct),{},E()({},t,e))}))}},{key:"handleInputChangeStartDate",value:function(e,t){var a,r="";if(this.state.orderProduct.dateStart)switch(this.state.product.durationId){case"none":r="";break;case"month":r=Y()(e).add(1,"M").format("YYYY-MM-DD");break;case"quarter":r=Y()(e).add(1,"Q").format("YYYY-MM-DD");break;case"half_year":r=Y()(e).add(6,"M").format("YYYY-MM-DD");break;case"year":r=Y()(e).add(1,"y").format("YYYY-MM-DD");break;case"until_cancellation":r="";break;default:r=""}this.setState(Re(Re({},this.state),{},{orderProduct:Re(Re({},this.state.orderProduct),{},(a={},E()(a,t,e),E()(a,"dateEnd",r),a))}))}},{key:"render",value:function(){var e=this.state.orderProduct,t=e.amount,a=e.amountReduction,r=e.percentageReduction,n=e.dateStart,i=e.dateEnd,o=e.datePeriodStartFirstInvoice,c=this.state.product,l=c.description,s=c.code,u=c.name,d=c.durationId,m=c.vatPercentage,p=c.inputInclVat,g=c.priceNumberOfDecimals,b=c.price,f=c.priceInclVat,v=c.ledgerId,y=c.costCenterId;return h.a.createElement("form",{className:"form-horizontal",onSubmit:this.handleSubmit},h.a.createElement(T.a,{className:"panel-grey"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Product"))),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Productcode",name:"code",value:s,onChangeAction:this.handleInputChangeProduct,required:"required",error:this.state.errors.code}),h.a.createElement(k.a,{label:"Naam",name:"name",value:u,onChangeAction:this.handleInputChangeProduct,required:"required",error:this.state.errors.name})),h.a.createElement("div",{className:"row"},this.props.usesTwinfield?h.a.createElement(h.a.Fragment,null,h.a.createElement(L.a,{label:"Grootboek",name:"ledgerId",id:"ledgerId",options:this.props.ledgers,optionName:"description",value:v,onChangeAction:this.handleLedgerChange,required:"required",error:this.state.errors.ledgerId}),h.a.createElement(F.a,{label:"Kostenplaats",id:"costCenterId",name:"costCenterId",options:this.props.costCenters,optionName:"description",value:y,onChangeAction:this.handleCostCenterChange})):null),h.a.createElement("div",{className:"row"},h.a.createElement(F.a,{label:"Looptijd",id:"durationId",name:"durationId",options:this.props.productDurations,value:d,onChangeAction:this.handleInputChangeProductDuration,emptyOption:!1}),h.a.createElement(F.a,{label:"BTW percentage",name:"vatPercentage",options:this.props.vatCodes,optionValue:"percentage",optionName:"description",value:m,onChangeAction:this.props.usesTwinfield?null:this.handleInputChangeProductVat,placeholder:"Geen",readOnly:this.props.usesTwinfield})),h.a.createElement("div",{className:"row"},h.a.createElement(Ae.a,{label:"Invoer inclusief BTW",name:"inputInclVat",value:p,onChangeAction:this.handleInputChangeProduct}),h.a.createElement(k.a,{label:"Aantal decimalen",type:"number",min:"2",max:"6",name:"priceNumberOfDecimals",value:g,onChangeAction:this.handleInputChangeProduct,onBlurAction:this.handleBlurDecimals,required:"required",error:this.state.errors.priceNumberOfDecimals})),h.a.createElement("div",{className:"row"},p?h.a.createElement(h.a.Fragment,null,h.a.createElement(k.a,{label:"Prijs excl. BTW",id:"price",name:"price",value:b,readOnly:!0,required:"required"}),h.a.createElement(k.a,{label:"Prijs incl. BTW",id:"priceInclVat",name:"priceInclVat",type:"number",min:"0",max:"1000000",value:f,onChangeAction:this.handleInputChangeProductPrice,onBlurAction:this.handleBlurProductPrice,required:"required",error:this.state.errors.priceInclVat})):h.a.createElement(h.a.Fragment,null,h.a.createElement(k.a,{label:"Prijs ex. BTW",id:"price",name:"price",type:"number",min:"0",max:"1000000",value:b,onChangeAction:this.handleInputChangeProductPrice,onBlurAction:this.handleBlurProductPrice,required:"required",error:this.state.errors.price}),h.a.createElement(k.a,{label:"Prijs incl. BTW",id:"priceInclVat",name:"priceInclVat",value:f,readOnly:!0,required:"required"}))),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-part panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Orderregel"))),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Omschrijving",id:"description",name:"description",value:l,onChangeAction:this.handleInputChangeProduct,required:"required",error:this.state.errors.description}),h.a.createElement(k.a,{label:"Aantal",type:"number",id:"amount",name:"amount",value:t,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.amount})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingspercentage",type:"number",id:"percentageReduction",name:"percentageReduction",value:r,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:this.state.product.inputInclVat?"Prijs incl. BTW":"Prijs excl. BTW",name:"orderPrice",value:"€"+this.state.orderPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:this.state.product.priceNumberOfDecimals}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingsbedrag",type:"number",id:"amountReduction",name:"amountReduction",value:a,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:"Totaalbedrag incl. BTW",name:"totalPrice",value:"€"+this.state.totalPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"Begin datum",name:"dateStart",value:n,onChangeAction:this.handleInputChangeStartDate,required:"required",error:this.state.errors.dateStart}),h.a.createElement(j.a,{label:"Eind datum",name:"dateEnd",value:i,onChangeAction:this.handleInputChangeDate,error:this.state.errors.dateEnd,readOnly:"none"===d})),"none"!==d&&h.a.createElement("div",{className:"row"},h.a.createElement(j.a,{label:"1ste notaperiode start op",name:"datePeriodStartFirstInvoice",value:o,onChangeAction:this.handleInputChangeDate,error:this.state.errors.datePeriodStartFirstInvoice,required:"required"})),this.state.errorMessage&&h.a.createElement("div",{className:"col-sm-10 col-md-offset-1 alert alert-danger"},this.state.errorMessage),h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Annuleren",onClickAction:this.props.toggleShowNewProduct}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:this.handleSubmit,type:"submit",value:"Submit"})))))}}]),a}(p.Component),Oe=Object(g.b)((function(e){return{orderDetails:e.orderDetails,productDurations:e.systemData.productDurations,productInvoiceFrequencies:e.systemData.productInvoiceFrequencies,productPaymentTypes:e.systemData.productPaymentTypes,products:e.systemData.products,costCenters:e.systemData.costCenters,ledgers:e.systemData.ledgers,vatCodes:e.systemData.vatCodes,usesTwinfield:e.systemData.usesTwinfield}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))(xe);function Se(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Be(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Se(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Se(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function we(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var ke=function(e){l()(a,e);var t=we(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"handleInputChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Be(Be({},r.state),{},{orderProduct:Be(Be({},r.state.orderProduct),{},E()({},n,a))}),r.updateOrderPrice)})),E()(v()(r),"handleLedgerChange",(function(e){var t=r.props.ledgers.find((function(t){return t.id===e})),a=t.vatCode&&t.vatCode.percentage;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},{ledgerId:e,vatPercentage:a})}),r.updatePrice)})),E()(v()(r),"handleCostCenterChange",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},E()({},n,a))}))})),E()(v()(r),"handleInputChangeProduct",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleInputChangeProductVat",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleInputChangeProductPrice",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=t.name;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},E()({},n,a))}),r.updatePrice)})),E()(v()(r),"handleBlurProductPrice",(function(e){var t=e.target,a=t.value,n=t.name;r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},E()({},n,parseFloat(a).toFixed(r.state.product.priceNumberOfDecimals)))}))})),E()(v()(r),"handleBlurDecimals",(function(e){var t=e.target,a="checkbox"===t.type?t.checked:t.value,n=(t.name,a);n<2&&(n=2),n>6&&(n=6),r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},{priceNumberOfDecimals:n,price:parseFloat(r.state.product.price).toFixed(n),priceInclVat:parseFloat(r.state.product.priceInclVat).toFixed(n)})}),r.updatePrice)})),E()(v()(r),"updatePrice",(function(){var e=!!r.state.product.inputInclVat&&r.state.product.inputInclVat,t=w.a.isFloat(r.state.product.price+"")?r.state.product.price:0,a=w.a.isFloat(r.state.product.priceInclVat+"")?r.state.product.priceInclVat:0,n=w.a.isFloat(r.state.product.vatPercentage+"")?r.state.product.vatPercentage:0,i=(parseFloat(100)+parseFloat(n))/100;e?(t=a/i,r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},{price:parseFloat(t).toFixed(r.state.product.priceNumberOfDecimals)})}),r.updateOrderPrice)):(a=t*i,r.setState(Be(Be({},r.state),{},{product:Be(Be({},r.state.product),{},{priceInclVat:parseFloat(a).toFixed(r.state.product.priceNumberOfDecimals)})}),r.updateOrderPrice))})),E()(v()(r),"updateOrderPrice",(function(){var e,t;e=r.state.product.inputInclVat,t=w.a.isFloat(r.state.product.vatPercentage+"")?r.state.product.vatPercentage:0;var a=(parseFloat(100)+parseFloat(t))/100,n=w.a.isFloat(r.state.product.priceInclVat+"")?r.state.product.priceInclVat:0,i=w.a.isFloat(r.state.product.price+"")?r.state.product.price:0,o=w.a.isFloat(r.state.orderProduct.amount+"")?r.state.orderProduct.amount:0,c=parseFloat(n*o).toFixed(2),l=parseFloat(i*o).toFixed(2),s=0;s=e?n:i;var u=w.a.isFloat(r.state.orderProduct.amountReduction+"")?r.state.orderProduct.amountReduction:0;e||(u*=a),u=parseFloat(u).toFixed(2);var d=(w.a.isFloat(r.state.orderProduct.percentageReduction+"")?r.state.orderProduct.percentageReduction:0)/100,m=0;e?m=c*d:(m=l*d,m*=a);var p=c-u-(m=parseFloat(m).toFixed(2));r.setState(Be(Be({},r.state),{},{orderPrice:parseFloat(s).toFixed(r.state.product.priceNumberOfDecimals),totalPrice:parseFloat(p).toFixed(2)}))})),E()(v()(r),"handleSubmit",(function(e){e.preventDefault();var t=r.state.orderProduct,a={},n=!1;w.a.isEmpty(t.amount+"")&&(a.amount=!0,n=!0);var i=r.state.product;i.inputInclVat?w.a.isEmpty(i.priceInclVat+"")&&(a.priceInclVat=!0,n=!0):w.a.isEmpty(i.price+"")&&(a.price=!0,n=!0),r.props.usesTwinfield&&w.a.isEmpty(String(i.ledgerId))&&(a.ledgerId=!0,n=!0),w.a.isEmpty(i.description)&&(a.description=!0,n=!0),r.setState(Be(Be({},r.state),{},{errors:a,errorMessage:!1})),!n&&q.a.newProductAndOrderProduct(t,i).then((function(e){r.props.fetchOrderDetails(t.orderId),r.props.toggleShowNewProductOneTime()}))})),r.state={errorMessage:!1,orderPrice:"",totalPrice:"",orderProduct:{orderId:r.props.orderDetails.id,amount:1,amountReduction:0,percentageReduction:0,dateStart:Y()().format("YYYY-MM-DD"),dateEnd:"",datePeriodStartFirstInvoice:Y()().format("YYYY-MM-DD")},product:{code:"EMP",name:"Eenmalig product",durationId:"none",description:"",administrationId:r.props.orderDetails.administrationId,invoiceFrequencyId:r.props.orderDetails.collectionFrequencyId?r.props.orderDetails.collectionFrequencyId:"once",vatPercentage:"",inputInclVat:!1,priceNumberOfDecimals:2,price:"",priceInclVat:"",ledgerId:"",costCenterId:"",isOneTime:!0},errors:{amount:!1,priceNumberOfDecimals:!1,price:!1,priceInclVat:!1,ledgerId:!1,description:!1}},r}return o()(a,[{key:"render",value:function(){var e=this.state.orderProduct,t=e.amount,a=e.amountReduction,r=e.percentageReduction,n=this.state.product,i=n.description,o=n.vatPercentage,c=n.inputInclVat,l=n.priceNumberOfDecimals,s=n.price,u=n.priceInclVat,d=n.ledgerId,m=n.costCenterId;return h.a.createElement("form",{className:"form-horizontal",onSubmit:this.handleSubmit},h.a.createElement(T.a,{className:"panel-grey"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Product"))),this.props.usesTwinfield?h.a.createElement("div",{className:"row"},h.a.createElement(L.a,{label:"Grootboek",name:"ledgerId",id:"ledgerId",options:this.props.ledgers,optionName:"description",value:d,onChangeAction:this.handleLedgerChange,required:"required",error:this.state.errors.ledgerId}),h.a.createElement(F.a,{label:"Kostenplaats",id:"costCenterId",name:"costCenterId",options:this.props.costCenters,optionName:"description",value:m,onChangeAction:this.handleCostCenterChange})):null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"form-group col-sm-6"}," "),h.a.createElement(F.a,{label:"BTW percentage",name:"vatPercentage",options:this.props.vatCodes,optionValue:"percentage",optionName:"description",value:o,onChangeAction:this.props.usesTwinfield?null:this.handleInputChangeProductVat,placeholder:"Geen",readOnly:this.props.usesTwinfield})),h.a.createElement("div",{className:"row"},h.a.createElement(Ae.a,{label:"Invoer inclusief BTW",name:"inputInclVat",value:c,onChangeAction:this.handleInputChangeProduct}),h.a.createElement(k.a,{label:"Aantal decimalen",type:"number",min:"2",max:"6",name:"priceNumberOfDecimals",value:l,onChangeAction:this.handleInputChangeProduct,onBlurAction:this.handleBlurDecimals,required:"required",error:this.state.errors.priceNumberOfDecimals})),h.a.createElement("div",{className:"row"},c?h.a.createElement(h.a.Fragment,null,h.a.createElement(k.a,{label:"Prijs excl. BTW",id:"price",name:"price",value:s,readOnly:!0,required:"required"}),h.a.createElement(k.a,{label:"Prijs incl. BTW",id:"priceInclVat",name:"priceInclVat",type:"number",min:"0",max:"1000000",value:u,onChangeAction:this.handleInputChangeProductPrice,onBlurAction:this.handleBlurProductPrice,required:"required",error:this.state.errors.priceInclVat})):h.a.createElement(h.a.Fragment,null,h.a.createElement(k.a,{label:"Prijs ex. BTW",id:"price",name:"price",type:"number",min:"0",max:"1000000",value:s,onChangeAction:this.handleInputChangeProductPrice,onBlurAction:this.handleBlurProductPrice,required:"required",error:this.state.errors.price}),h.a.createElement(k.a,{label:"Prijs incl. BTW",id:"priceInclVat",name:"priceInclVat",value:u,readOnly:!0,required:"required"}))),h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"panel-part panel-heading"},h.a.createElement("span",{className:"h5 text-bold"},"Orderregel"))),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Omschrijving",id:"description",name:"description",value:i,onChangeAction:this.handleInputChangeProduct,required:"required",error:this.state.errors.description}),h.a.createElement(k.a,{label:"Aantal",type:"number",id:"amount",name:"amount",value:t,onChangeAction:this.handleInputChange,required:"required",error:this.state.errors.amount})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingspercentage",type:"number",id:"percentageReduction",name:"percentageReduction",value:r,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:this.state.product.inputInclVat?"Prijs incl. BTW":"Prijs excl. BTW",name:"orderPrice",value:"€"+this.state.orderPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:this.state.product.priceNumberOfDecimals}),readOnly:!0})),h.a.createElement("div",{className:"row"},h.a.createElement(k.a,{label:"Kortingsbedrag",type:"number",id:"amountReduction",name:"amountReduction",value:a,onChangeAction:this.handleInputChange}),h.a.createElement(k.a,{label:"Totaalbedrag incl. BTW",name:"totalPrice",value:"€"+this.state.totalPrice.toLocaleString("nl",{minimumFractionDigits:2,maximumFractionDigits:2}),readOnly:!0})),this.state.errorMessage&&h.a.createElement("div",{className:"col-sm-10 col-md-offset-1 alert alert-danger"},this.state.errorMessage),h.a.createElement("div",{className:"pull-right btn-group",role:"group"},h.a.createElement(R.a,{buttonClassName:"btn-default",buttonText:"Annuleren",onClickAction:this.props.toggleShowNewProductOneTime}),h.a.createElement(R.a,{buttonText:"Opslaan",onClickAction:this.handleSubmit,type:"submit",value:"Submit"})))))}}]),a}(p.Component),Te=Object(g.b)((function(e){return{orderDetails:e.orderDetails,costCenters:e.systemData.costCenters,ledgers:e.systemData.ledgers,vatCodes:e.systemData.vatCodes,usesTwinfield:e.systemData.usesTwinfield}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))(ke);function _e(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var Fe=function(e){l()(a,e);var t=_e(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"toggleShowNew",(function(){r.props.orderDetails.canEdit?r.setState({showNew:!r.state.showNew}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),E()(v()(r),"toggleShowNewProduct",(function(){r.props.orderDetails.canEdit?r.setState({showNewProduct:!r.state.showNewProduct}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),E()(v()(r),"toggleShowNewProductOneTime",(function(){r.props.orderDetails.canEdit?r.setState({showNewProductOneTime:!r.state.showNewProductOneTime}):r.props.setError(405,"Een order met daar aan gekoppeld een nota met de status “Te verzenden” kan niet worden aangepast(de order zit in de map “Order – Te verzenden”). Wil je deze order toch aanpassen? Verwijder dan eerst de “Te verzenden” nota. Dan kom deze order weer in de “Order – te factureren”.  Pas de order aan en maak vervolgens opnieuw de nota.")})),r.state={showNew:!1,showNewProduct:!1,showNewProductOneTime:!1},r}return o()(a,[{key:"render",value:function(){return h.a.createElement(T.a,null,h.a.createElement(re.a,null,h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-xs-10"},h.a.createElement("span",{className:"h5 text-bold"},"Orderregels")),this.props.permissions.manageFinancial&&h.a.createElement("div",{className:"col-xs-2"},h.a.createElement("div",{className:"pull-right"},h.a.createElement("span",{className:"glyphicon glyphicon-plus","data-toggle":"dropdown",role:"button"}),h.a.createElement("ul",{className:"dropdown-menu"},h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:this.toggleShowNew},"Bestaand product")),h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:this.toggleShowNewProduct},"Nieuw product")),h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:this.toggleShowNewProductOneTime},"Nieuw eenmalig product"))))))),h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-md-12"},h.a.createElement(ve,null)),h.a.createElement("div",{className:"col-md-12 margin-10-top"},this.state.showNew&&h.a.createElement(Pe,{toggleShowNew:this.toggleShowNew}),this.state.showNewProduct&&h.a.createElement(Oe,{toggleShowNewProduct:this.toggleShowNewProduct}),this.state.showNewProductOneTime&&h.a.createElement(Te,{toggleShowNewProductOneTime:this.toggleShowNewProductOneTime}))))}}]),a}(p.Component),Me=Object(g.b)((function(e){return{permissions:e.meDetails.permissions,orderDetails:e.orderDetails}}),(function(e){return{setError:function(t,a){e(Object(H.b)(t,a))}}}))(Fe);function je(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}Y.a.locale("nl");var Le=function(e){l()(a,e);var t=je(a);function a(e){return n()(this,a),t.call(this,e)}return o()(a,[{key:"render",value:function(){var e="",t=!0;return this.props.hasError?e="Fout bij het ophalen van order.":this.props.isLoading?e="Gegevens aan het laden.":Object(S.isEmpty)(this.props.orderDetails)?e="Geen order gevonden!":t=!1,t?h.a.createElement("div",null,e):h.a.createElement("div",null,h.a.createElement(te,null),h.a.createElement(Me,null),h.a.createElement(ne,null))}}]),a}(p.Component),Ve=Object(g.b)((function(e){return{orderDetails:e.orderDetails,isLoading:e.loadingData.isLoading,hasError:e.loadingData.hasError}}))(Le);function Ye(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var qe=function(e){l()(a,e);var t=Ye(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/taak/".concat(e))})),r.state={relatedTasks:""},r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedTasks;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen taken of notities gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{onClick:function(){return e.openItem(t.id)},key:a},h.a.createElement("td",{className:"col-xs-12 clickable"},Y()(t.createdAt).format("L")," - ",t.noteSummary))})))))}}]),a}(p.Component),ze=Object(g.b)((function(e){return{relatedTasks:e.orderDetails.relatedTasks}}))(qe),Ze=Object(g.b)((function(e){return{permissions:e.meDetails.permissions}}),null)((function(e){var t=e.toggleShowList,a=e.showTasksList,r=e.newTask,n=e.taskCount,i=e.permissions;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-10",onClick:t,role:"button"},h.a.createElement("span",null,"TAKEN/NOTITIES ",h.a.createElement("span",{className:"badge"},n))),h.a.createElement("div",{className:"col-sm-2"},i.manageTask&&h.a.createElement("div",{className:"pull-right"},h.a.createElement("span",{className:"glyphicon glyphicon-plus glyphicon-white","data-toggle":"dropdown",role:"button"}),h.a.createElement("ul",{className:"dropdown-menu"},h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:function(){return r("open")}},"Maak taak")),h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:function(){return r("afgehandeld")}},"Maak notitie"))))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(ze,null))))}));function $e(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var Ge=function(e){l()(a,e);var t=$e(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/email/".concat(e))})),r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedEmails;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen e-mails gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{key:a},h.a.createElement("td",{className:"col-xs-4 clickable",onClick:function(){return e.openItem(t.id)}},Y()(t.date_sent).format("L")),h.a.createElement("td",{className:"col-xs-8 clickable",onClick:function(){return e.openItem(t.id)}},t.subject))})))))}}]),a}(p.Component),We=Object(g.b)((function(e){return{relatedEmails:e.orderDetails.relatedEmails}}))(Ge),Ke=function(e){var t=e.toggleShowList,a=e.showEmailsList,r=e.newEmail,n=e.emailCount;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-10",onClick:t,role:"button"},h.a.createElement("span",{onClick:t,className:""},"E-MAILS ",h.a.createElement("span",{className:"badge"},n))),h.a.createElement("div",{className:"col-sm-2"},h.a.createElement("a",{role:"button",className:"pull-right",onClick:r},h.a.createElement("span",{className:"glyphicon glyphicon-plus glyphicon-white"}))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(We,null))))};function Ue(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var He=function(e){l()(a,e);var t=Ue(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/document/".concat(e))})),r.state={relatedDocuments:""},r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedDocuments;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen documenten gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{onClick:function(){return e.openItem(t.id)},key:a},h.a.createElement("td",{className:"col-xs-5 clickable"},Y()(t.createdAt).format("L")),h.a.createElement("td",{className:"col-xs-6 clickable"},t.filename))})))))}}]),a}(p.Component),Xe=Object(g.b)((function(e){return{relatedDocuments:e.orderDetails.relatedDocuments}}))(He),Je=Object(g.b)((function(e){return{permissions:e.meDetails.permissions}}),null)((function(e){var t=e.toggleShowList,a=e.showDocumentsList,r=e.newDocument,n=e.documentCount,i=e.permissions;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-10",onClick:t,role:"button"},h.a.createElement("span",null,"DOCUMENTEN ",h.a.createElement("span",{className:"badge"},n))),h.a.createElement("div",{className:"col-sm-2"},i.createDocument&&h.a.createElement("div",{className:"pull-right"},h.a.createElement("span",{className:"glyphicon glyphicon-plus glyphicon-white","data-toggle":"dropdown",role:"button"}),h.a.createElement("ul",{className:"dropdown-menu"},h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:function(){return r("internal")}},"Maak document")),h.a.createElement("li",null,h.a.createElement("a",{className:"btn",onClick:function(){return r("upload")}},"Upload document"))))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(Xe,null))))}));function Qe(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var et=function(e){l()(a,e);var t=Qe(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/nota/".concat(e))})),r.state={relatedInvoices:""},r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedInvoices;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen nota's gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{onClick:function(){return e.openItem(t.id)},key:a},h.a.createElement("td",{className:"col-xs-12 clickable"},Y()(t.createdAt).format("L")," - ",t.number))})))))}}]),a}(p.Component),tt=Object(g.b)((function(e){return{relatedInvoices:e.orderDetails.relatedInvoices}}))(et),at=function(e){var t=e.toggleShowList,a=e.showInvoicesList,r=e.invoiceCount;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-12",onClick:t,role:"button"},h.a.createElement("span",null,"NOTA'S ",h.a.createElement("span",{className:"badge"},r))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(tt,null))))};function rt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var nt=function(e){l()(a,e);var t=rt(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/nota/".concat(e))})),r.state={relatedInvoicesPaidCollection:""},r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedInvoicesPaidCollection;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen geïncasseerde incasso's gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{onClick:function(){return e.openItem(t.id)},key:a},h.a.createElement("td",{className:"col-xs-12 clickable"},Y()(t.createdAt).format("L")," - ",t.number))})))))}}]),a}(p.Component),it=Object(g.b)((function(e){return{relatedInvoicesPaidCollection:e.orderDetails.relatedInvoicesPaidCollection}}))(nt),ot=function(e){var t=e.toggleShowList,a=e.showInvoicesPaidCollectionList,r=e.invoicePaidCollectionCount;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-12",onClick:t,role:"button"},h.a.createElement("span",null,"GEÏNCASSEERDE INCASSO'S ",h.a.createElement("span",{className:"badge"},r))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(it,null))))};function ct(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var lt=function(e){l()(a,e);var t=ct(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"openItem",(function(e){I.f.push("/nota/".concat(e))})),r.state={relatedInvoicesPaidTransfer:""},r}return o()(a,[{key:"render",value:function(){var e=this,t=this.props.relatedInvoicesPaidTransfer;return h.a.createElement("div",null,""==t&&h.a.createElement("div",null,"Geen overboekingen gevonden."),""!=t&&h.a.createElement("table",{className:"table harmonica-table"},h.a.createElement("tbody",null,t.map((function(t,a){return h.a.createElement("tr",{onClick:function(){return e.openItem(t.id)},key:a},h.a.createElement("td",{className:"col-xs-12 clickable"},Y()(t.createdAt).format("L")," - ",t.number))})))))}}]),a}(p.Component),st=Object(g.b)((function(e){return{relatedInvoicesPaidTransfer:e.orderDetails.relatedInvoicesPaidTransfer}}))(lt),ut=function(e){var t=e.toggleShowList,a=e.showInvoicesPaidTransferList,r=e.invoicePaidTransferCount;return h.a.createElement(T.a,{className:"harmonica-button"},h.a.createElement(_.a,null,h.a.createElement("div",{className:"col-sm-12",onClick:t,role:"button"},h.a.createElement("span",null,"OVERBOEKINGEN ",h.a.createElement("span",{className:"badge"},r))),h.a.createElement("div",{className:"col-sm-12"},a&&h.a.createElement(st,null))))};function dt(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function mt(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?dt(Object(a),!0).forEach((function(t){E()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):dt(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}function pt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var ht=function(e){l()(a,e);var t=pt(a);function a(e){var r;return n()(this,a),r=t.call(this,e),E()(v()(r),"newTask",(function(e){I.f.push("/taak/nieuw/".concat(e,"/order/").concat(r.props.orderDetails.id))})),E()(v()(r),"newEmail",(function(){I.f.push("/email/nieuw")})),E()(v()(r),"newDocument",(function(e){I.f.push("/document/nieuw/".concat(e,"/order/").concat(r.props.orderDetails.id))})),r.state={toggleShowList:{tasks:!1,emails:!1,documents:!1,invoices:!1,invoicesPaidCollection:!1,invoicesPaidTransfer:!1}},r.toggleShowList=r.toggleShowList.bind(v()(r)),r}return o()(a,[{key:"componentWillReceiveProps",value:function(e){this.props.id!==e.id&&this.setState({toggleShowList:{tasks:!1,emails:!1,documents:!1,invoices:!1,invoicesPaidCollection:!1,invoicesPaidTransfer:!1}})}},{key:"toggleShowList",value:function(e){this.setState(mt(mt({},this.state),{},{toggleShowList:mt(mt({},this.state.toggleShowList),{},E()({},e,!this.state.toggleShowList[e]))}))}},{key:"render",value:function(){var e=this;return h.a.createElement("div",{className:"margin-10-top"},h.a.createElement(Ze,{toggleShowList:function(){return e.toggleShowList("tasks")},showTasksList:this.state.toggleShowList.tasks,taskCount:this.props.orderDetails.taskCount,newTask:this.newTask}),h.a.createElement(Ke,{toggleShowList:function(){return e.toggleShowList("emails")},showEmailsList:this.state.toggleShowList.emails,newEmail:this.newEmail,emailCount:this.props.orderDetails.emailCount}),h.a.createElement(Je,{toggleShowList:function(){return e.toggleShowList("documents")},showDocumentsList:this.state.toggleShowList.documents,newDocument:this.newDocument,documentCount:this.props.orderDetails.documentCount}),h.a.createElement(at,{toggleShowList:function(){return e.toggleShowList("invoices")},showInvoicesList:this.state.toggleShowList.invoices,invoiceCount:this.props.orderDetails.invoiceCount}),"collection"===this.props.orderDetails.paymentTypeId?h.a.createElement(ot,{toggleShowList:function(){return e.toggleShowList("invoicesPaidCollection")},showInvoicesPaidCollectionList:this.state.toggleShowList.invoicesPaidCollection,invoicePaidCollectionCount:this.props.orderDetails.invoicePaidCollectionCount}):h.a.createElement(ut,{toggleShowList:function(){return e.toggleShowList("invoicesPaidTransfer")},showInvoicesPaidTransferList:this.state.toggleShowList.invoicesPaidTransfer,invoicePaidTransferCount:this.props.orderDetails.invoicePaidTransferCount}))}}]),a}(p.Component),gt=Object(g.b)((function(e){return{orderDetails:e.orderDetails,permissions:e.meDetails.permissions}}),null)(ht);function bt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=m()(e);if(t){var n=m()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return u()(this,a)}}var ft=function(e){l()(a,e);var t=bt(a);function a(e){return n()(this,a),t.call(this,e)}return o()(a,[{key:"componentDidMount",value:function(){this.props.fetchOrderDetails(this.props.params.id)}},{key:"render",value:function(){return h.a.createElement("div",{className:"row"},h.a.createElement("div",{className:"col-md-9"},h.a.createElement("div",{className:"col-md-12 margin-10-top"},h.a.createElement(T.a,null,h.a.createElement(_.a,{className:"panel-small"},h.a.createElement(O,null)))),h.a.createElement("div",{className:"col-md-12 margin-10-top"},h.a.createElement(Ve,null))),h.a.createElement(T.a,{className:"col-md-3 harmonica"},h.a.createElement(_.a,null,h.a.createElement(gt,null))))}}]),a}(p.Component);t.default=Object(g.b)((function(e){return{orderDetails:e.orderDetails}}),(function(e){return{fetchOrderDetails:function(t){e(Object(b.a)(t))}}}))(ft)},700:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.children,a=e.className,r=e.onMouseEnter,i=e.onMouseLeave;return n.a.createElement("div",{className:"panel panel-default ".concat(a),onMouseEnter:r,onMouseLeave:i},t)};c.defaultProps={className:"",onMouseEnter:function(){},onMouseLeave:function(){}},c.propTypes={className:o.a.string,onMouseEnter:o.a.func,onMouseLeave:o.a.func},t.a=c},701:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.className,a=e.children;return n.a.createElement("div",{className:"panel-body ".concat(t)},a)};c.defaultProps={className:""},c.propTypes={className:o.a.string},t.a=c},702:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.buttonClassName,a=e.iconName,r=e.onClickAction,i=e.title,o=e.disabled;return n.a.createElement("button",{type:"button",className:"btn ".concat(t),onClick:r,disabled:o,title:i},n.a.createElement("span",{className:"glyphicon ".concat(a)}))};c.defaultProps={buttonClassName:"btn-success btn-sm",title:"",disabled:!1},c.propTypes={buttonClassName:o.a.string,iconName:o.a.string.isRequired,onClickAction:o.a.func,title:o.a.string,disabled:o.a.bool},t.a=c},703:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.buttonClassName,a=e.buttonText,r=e.onClickAction,i=e.type,o=e.value,c=e.loading,l=e.loadText,s=e.disabled;return c?n.a.createElement("button",{type:i,className:"btn btn-sm btn-loading ".concat(t),value:o,disabled:c},n.a.createElement("span",{className:"glyphicon glyphicon-refresh glyphicon-refresh-animate"})," ",l):n.a.createElement("button",{type:i,className:"btn btn-sm ".concat(t),onClick:r,value:o,disabled:s},a)};c.defaultProps={buttonClassName:"btn-success",type:"button",value:"",loading:!1,loadText:"Aan het laden",disabled:!1},c.propTypes={buttonClassName:o.a.string,buttonText:o.a.string.isRequired,onClickAction:o.a.func,type:o.a.string,value:o.a.string,loading:o.a.bool,loadText:o.a.string,disabled:o.a.bool},t.a=c},704:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.label,a=e.type,r=e.className,i=e.size,o=e.id,c=e.placeholder,l=e.name,s=e.value,u=e.onClickAction,d=e.onChangeAction,m=e.onBlurAction,p=e.required,h=e.readOnly,g=e.maxLength,b=e.error,f=e.min,v=e.max,y=e.step,E=e.errorMessage,I=e.divSize,N=e.divClassName,P=e.autoComplete;return n.a.createElement("div",{className:"form-group ".concat(I," ").concat(N)},n.a.createElement("label",{htmlFor:o,className:"col-sm-6 ".concat(p)},t),n.a.createElement("div",{className:"".concat(i)},n.a.createElement("input",{type:a,className:"form-control input-sm ".concat(r)+(b?"has-error":""),id:o,placeholder:c,name:l,value:s||"",onClick:u,onChange:d,onBlur:m,readOnly:h,maxLength:g,min:f,max:v,autoComplete:P,step:y})),b&&n.a.createElement("div",{className:"col-sm-offset-6 col-sm-6"},n.a.createElement("span",{className:"has-error-message"}," ",E)))};c.defaultProps={divClassName:"",className:"",size:"col-sm-6",divSize:"col-sm-6",name:"",type:"text",value:"",required:"",readOnly:!1,maxLength:null,error:!1,min:"",max:"",step:"",errorMessage:"",autoComplete:"off",onBlurAction:function(){},onClickAction:function(){},onChangeAction:function(){}},c.propTypes={label:o.a.oneOfType([o.a.string,o.a.object]).isRequired,type:o.a.string,className:o.a.string,divClassName:o.a.string,size:o.a.string,divSize:o.a.string,id:o.a.string,placeholder:o.a.string,name:o.a.string.isRequired,value:o.a.oneOfType([o.a.string,o.a.number]),onClickAction:o.a.func,onChangeAction:o.a.func,onBlurAction:o.a.func,required:o.a.string,readOnly:o.a.bool,maxLength:o.a.string,error:o.a.bool,min:o.a.string,max:o.a.string,step:o.a.string,errorMessage:o.a.string,autoComplete:o.a.string},t.a=c},706:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(4),o=a(8),c=a.n(o),l=function(e){var t=e.label,a=e.className,r=e.id,o=e.value,c=e.link,l=e.hidden;return c.length>0?n.a.createElement("div",{className:a,style:l?{display:"none"}:{}},n.a.createElement("label",{htmlFor:r,className:"col-sm-6"},t),n.a.createElement("div",{className:"col-sm-6",id:r,onClick:null},n.a.createElement(i.b,{to:c,className:"link-underline"},o))):n.a.createElement("div",{className:a,style:l?{display:"none"}:{}},n.a.createElement("label",{htmlFor:r,className:"col-sm-6"},t),n.a.createElement("div",{className:"col-sm-6",id:r},o))};l.defaultProps={className:"col-sm-6",value:"",link:"",hidden:!1},l.propTypes={label:c.a.oneOfType([c.a.string,c.a.object]).isRequired,className:c.a.string,id:c.a.string,value:c.a.oneOfType([c.a.string,c.a.number]),link:c.a.string,hidden:c.a.bool},t.a=l},707:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.label,a=e.className,r=e.size,i=e.id,o=e.name,c=e.value,l=e.options,s=e.onChangeAction,u=e.onBlurAction,d=e.required,m=e.error,p=e.errorMessage,h=e.optionValue,g=e.optionName,b=e.readOnly,f=e.placeholder,v=e.divClassName,y=e.emptyOption;return n.a.createElement("div",{className:"form-group ".concat(r," ").concat(v)},n.a.createElement("label",{htmlFor:i,className:"col-sm-6 ".concat(d)},t),n.a.createElement("div",{className:"col-sm-6"},n.a.createElement("select",{className:"form-control input-sm ".concat(a)+(m&&" has-error"),id:i,name:o,value:c||"",onChange:s,onBlur:u,readOnly:b},y&&n.a.createElement("option",{value:""},f),l.map((function(e){return n.a.createElement("option",{key:e[h],value:e[h]},e[g])})))),m&&n.a.createElement("div",{className:"col-sm-offset-6 col-sm-6"},n.a.createElement("span",{className:"has-error-message"}," ",p)))};c.defaultProps={divClassName:"",className:"",size:"col-sm-6",readOnly:!1,required:"",error:!1,errorMessage:"",value:"",optionValue:"id",optionName:"name",placeholder:"",emptyOption:!0},c.propTypes={label:o.a.string.isRequired,className:o.a.string,size:o.a.string,id:o.a.string,name:o.a.string.isRequired,options:o.a.array,value:o.a.oneOfType([o.a.string,o.a.number]),onChangeAction:o.a.func,onBlurAction:o.a.func,required:o.a.string,readOnly:o.a.bool,error:o.a.bool,errorMessage:o.a.string,emptyOption:o.a.bool,optionValue:o.a.string,optionName:o.a.string,placeholder:o.a.string},t.a=c},709:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=function(e){var t=e.className,a=e.children;return n.a.createElement("div",{className:"panel-heading ".concat(t)},a)};c.defaultProps={className:""},c.propTypes={className:o.a.string},t.a=c},710:function(e,t,a){"use strict";var r=a(24),n=a.n(r),i=a(25),o=a.n(i),c=a(22),l=a.n(c),s=a(26),u=a.n(s),d=a(27),m=a.n(d),p=a(16),h=a.n(p),g=a(6),b=a.n(g),f=a(0),v=a.n(f),y=a(8),E=a.n(y),I=a(728),N=a.n(I),P=a(729),A=a.n(P),C=a(7),R=a.n(C);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=h()(e);if(t){var n=h()(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return m()(this,a)}}R.a.locale("nl");var x=function(e){u()(a,e);var t=D(a);function a(e){var r;return n()(this,a),r=t.call(this,e),b()(l()(r),"validateDate",(function(e){var t=R()(e.target.value,"DD-MM-YYYY",!0),a=!1;t.isValid()||""===e.target.value||(a=!0),r.props.disabledBefore&&t.isBefore(r.props.disabledBefore)&&(a=!0),r.props.disabledAfter&&t.isAfter(r.props.disabledAfter)&&(a=!0),r.setState({errorDateFormat:a})})),b()(l()(r),"onDateChange",(function(e){var t=e?R()(e).format("Y-MM-DD"):"",a=!1;t&&r.props.disabledBefore&&R()(t).isBefore(r.props.disabledBefore)&&(a=!0),t&&r.props.disabledAfter&&R()(t).isAfter(r.props.disabledAfter)&&(a=!0),r.setState({errorDateFormat:a}),!a&&r.props.onChangeAction(t,r.props.name)})),r.state={errorDateFormat:!1},r}return o()(a,[{key:"render",value:function(){var e=this.props,t=e.label,a=e.className,r=e.size,n=e.divSize,i=e.id,o=e.value,c=e.required,l=e.readOnly,s=e.name,u=e.error,d=e.errorMessage,m=e.disabledBefore,p=e.disabledAfter,h=o?R()(o).format("L"):"",g={};return m&&(g.before=new Date(m)),p&&(g.after=new Date(p)),v.a.createElement("div",{className:"form-group ".concat(n)},v.a.createElement("div",null,v.a.createElement("label",{htmlFor:i,className:"col-sm-6 ".concat(c)},t)),v.a.createElement("div",{className:"".concat(r)},v.a.createElement(N.a,{id:i,value:h,formatDate:P.formatDate,parseDate:P.parseDate,onDayChange:this.onDateChange,dayPickerProps:{showWeekNumbers:!0,locale:"nl",firstDayOfWeek:1,localeUtils:A.a,disabledDays:g},inputProps:{className:"form-control input-sm ".concat(a)+(this.state.errorDateFormat||u?" has-error":""),name:s,onBlur:this.validateDate,autoComplete:"off",readOnly:l,disabled:l},required:c,readOnly:l,placeholder:""})),u&&v.a.createElement("div",{className:"col-sm-offset-6 col-sm-6"},v.a.createElement("span",{className:"has-error-message"}," ",d)))}}]),a}(f.Component);x.defaultProps={className:"",size:"col-sm-6",divSize:"col-sm-6",required:"",readOnly:!1,value:null,error:!1,errorMessage:"",disabledBefore:null,disabledAfter:null},x.propTypes={label:E.a.string.isRequired,type:E.a.string,className:E.a.string,size:E.a.string,divSize:E.a.string,id:E.a.string,name:E.a.string,value:E.a.oneOfType([E.a.string,E.a.object]),onChangeAction:E.a.func,required:E.a.string,readOnly:E.a.bool,error:E.a.bool,errorMessage:E.a.string,disabledBefore:E.a.string,disabledAfter:E.a.string},t.a=x},712:function(e,t,a){"use strict";var r=a(0),n=a.n(r),i=a(8),o=a.n(i),c=a(719),l=a.n(c),s=function(e){var t=e.label,a=e.size,r=e.id,i=e.name,o=e.value,c=e.onChangeAction,s=e.required,u=e.divSize,d=e.className,m=e.disabled;return n.a.createElement("div",{className:"form-group ".concat(u," ").concat(d)},n.a.createElement("div",null,n.a.createElement("label",{htmlFor:r,className:"col-sm-6 ".concat(s)},t)),n.a.createElement("div",{className:"".concat(a)},n.a.createElement(l.a,{id:r,name:i,onChange:c,defaultChecked:o,disabled:m})))};s.defaultProps={className:"",size:"col-sm-6",divSize:"col-sm-6",required:"",disabled:!1,value:""},s.propTypes={label:o.a.string.isRequired,type:o.a.string,size:o.a.string,divSize:o.a.string,id:o.a.string,name:o.a.string.isRequired,value:o.a.bool,onChangeAction:o.a.func,required:o.a.string,disabled:o.a.bool},t.a=s},714:function(e,t,a){var r;
  /*!
    Copyright (c) 2017 Jed Watson.
    Licensed under the MIT License (MIT), see
    http://jedwatson.github.io/classnames
  */!function(){"use strict";var a={}.hasOwnProperty;function n(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var i=typeof r;if("string"===i||"number"===i)e.push(r);else if(Array.isArray(r)&&r.length){var o=n.apply(null,r);o&&e.push(o)}else if("object"===i)for(var c in r)a.call(r,c)&&r[c]&&e.push(c)}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):void 0===(r=function(){return n}.apply(t,[]))||(e.exports=r)}()},718:function(e,t,a){"use strict";a(736),a(199),a(711),a(12),a(6);var r=a(732),n=a(725),i=(a(22),a(735)),o=a(733),c=a(734),l=a(0),s=a.n(l),u=a(727),d=a(723),m=(a(103),a(92),a(705)),p=(a(724),a(716),a(726),a(731)),h=a(748);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=Object(c.a)(e);if(t){var n=Object(c.a)(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return Object(o.a)(this,a)}}l.Component;var b=Object(p.a)(m.a);t.a=b},719:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var a=arguments[t];for(var r in a)Object.prototype.hasOwnProperty.call(a,r)&&(e[r]=a[r])}return e},n=function(){function e(e,t){for(var a=0;a<t.length;a++){var r=t[a];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,a,r){return a&&e(t.prototype,a),r&&e(t,r),t}}(),i=a(0),o=m(i),c=m(a(714)),l=m(a(8)),s=m(a(720)),u=m(a(721)),d=a(722);function m(e){return e&&e.__esModule?e:{default:e}}var p=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var a=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return a.handleClick=a.handleClick.bind(a),a.handleTouchStart=a.handleTouchStart.bind(a),a.handleTouchMove=a.handleTouchMove.bind(a),a.handleTouchEnd=a.handleTouchEnd.bind(a),a.handleFocus=a.handleFocus.bind(a),a.handleBlur=a.handleBlur.bind(a),a.previouslyChecked=!(!e.checked&&!e.defaultChecked),a.state={checked:!(!e.checked&&!e.defaultChecked),hasFocus:!1},a}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),n(t,[{key:"componentDidUpdate",value:function(e){e.checked!==this.props.checked&&this.setState({checked:!!this.props.checked})}},{key:"handleClick",value:function(e){var t=this.input;if(e.target!==t&&!this.moved)return this.previouslyChecked=t.checked,e.preventDefault(),t.focus(),void t.click();var a=this.props.hasOwnProperty("checked")?this.props.checked:t.checked;this.setState({checked:a})}},{key:"handleTouchStart",value:function(e){this.startX=(0,d.pointerCoord)(e).x,this.activated=!0}},{key:"handleTouchMove",value:function(e){if(this.activated&&(this.moved=!0,this.startX)){var t=(0,d.pointerCoord)(e).x;this.state.checked&&t+15<this.startX?(this.setState({checked:!1}),this.startX=t,this.activated=!0):t-15>this.startX&&(this.setState({checked:!0}),this.startX=t,this.activated=t<this.startX+5)}}},{key:"handleTouchEnd",value:function(e){if(this.moved){var t=this.input;if(e.preventDefault(),this.startX){var a=(0,d.pointerCoord)(e).x;!0===this.previouslyChecked&&this.startX+4>a?this.previouslyChecked!==this.state.checked&&(this.setState({checked:!1}),this.previouslyChecked=this.state.checked,t.click()):this.startX-4<a&&this.previouslyChecked!==this.state.checked&&(this.setState({checked:!0}),this.previouslyChecked=this.state.checked,t.click()),this.activated=!1,this.startX=null,this.moved=!1}}}},{key:"handleFocus",value:function(e){var t=this.props.onFocus;t&&t(e),this.setState({hasFocus:!0})}},{key:"handleBlur",value:function(e){var t=this.props.onBlur;t&&t(e),this.setState({hasFocus:!1})}},{key:"getIcon",value:function(e){var a=this.props.icons;return a?void 0===a[e]?t.defaultProps.icons[e]:a[e]:null}},{key:"render",value:function(){var e=this,t=this.props,a=t.className,n=(t.icons,function(e,t){var a={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(a[r]=e[r]);return a}(t,["className","icons"])),i=(0,c.default)("react-toggle",{"react-toggle--checked":this.state.checked,"react-toggle--focus":this.state.hasFocus,"react-toggle--disabled":this.props.disabled},a);return o.default.createElement("div",{className:i,onClick:this.handleClick,onTouchStart:this.handleTouchStart,onTouchMove:this.handleTouchMove,onTouchEnd:this.handleTouchEnd},o.default.createElement("div",{className:"react-toggle-track"},o.default.createElement("div",{className:"react-toggle-track-check"},this.getIcon("checked")),o.default.createElement("div",{className:"react-toggle-track-x"},this.getIcon("unchecked"))),o.default.createElement("div",{className:"react-toggle-thumb"}),o.default.createElement("input",r({},n,{ref:function(t){e.input=t},onFocus:this.handleFocus,onBlur:this.handleBlur,className:"react-toggle-screenreader-only",type:"checkbox"})))}}]),t}(i.PureComponent);t.default=p,p.displayName="Toggle",p.defaultProps={icons:{checked:o.default.createElement(s.default,null),unchecked:o.default.createElement(u.default,null)}},p.propTypes={checked:l.default.bool,disabled:l.default.bool,defaultChecked:l.default.bool,onChange:l.default.func,onFocus:l.default.func,onBlur:l.default.func,className:l.default.string,name:l.default.string,value:l.default.string,id:l.default.string,"aria-labelledby":l.default.string,"aria-label":l.default.string,icons:l.default.oneOfType([l.default.bool,l.default.shape({checked:l.default.node,unchecked:l.default.node})])}},720:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,n=a(0),i=(r=n)&&r.__esModule?r:{default:r};t.default=function(){return i.default.createElement("svg",{width:"14",height:"11",viewBox:"0 0 14 11"},i.default.createElement("title",null,"switch-check"),i.default.createElement("path",{d:"M11.264 0L5.26 6.004 2.103 2.847 0 4.95l5.26 5.26 8.108-8.107L11.264 0",fill:"#fff",fillRule:"evenodd"}))}},721:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,n=a(0),i=(r=n)&&r.__esModule?r:{default:r};t.default=function(){return i.default.createElement("svg",{width:"10",height:"10",viewBox:"0 0 10 10"},i.default.createElement("title",null,"switch-x"),i.default.createElement("path",{d:"M9.9 2.12L7.78 0 4.95 2.828 2.12 0 0 2.12l2.83 2.83L0 7.776 2.123 9.9 4.95 7.07 7.78 9.9 9.9 7.776 7.072 4.95 9.9 2.12",fill:"#fff",fillRule:"evenodd"}))}},722:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pointerCoord=function(e){if(e){var t=e.changedTouches;if(t&&t.length>0){var a=t[0];return{x:a.clientX,y:a.clientY}}var r=e.pageX;if(void 0!==r)return{x:r,y:e.pageY}}return{x:0,y:0}}},730:function(e,t,a){"use strict";var r=a(6),n=a.n(r),i=a(0),o=a.n(i),c=a(8),l=a.n(c),s=a(718);function u(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function d(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?u(Object(a),!0).forEach((function(t){n()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):u(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var m=function(e){var t=e.label,a=e.divSize,r=e.size,n=e.id,i=e.name,c=e.value,l=e.options,u=e.optionId,m=e.optionName,p=e.onChangeAction,h=e.required,g=e.error,b=e.errorMessage,f=e.isLoading,v=e.disabled,y=e.placeholder,E=e.clearable,I={option:function(e){return d(d({},e),{},{fontSize:"12px"})},singleValue:function(e){return d(d({},e),{},{fontSize:"12px"})},menu:function(e){return d(d({},e),{},{zIndex:20})}};return o.a.createElement("div",{className:"form-group ".concat(a)},o.a.createElement("label",{htmlFor:n,className:"col-sm-6 ".concat(h)},t),o.a.createElement("div",{className:"".concat(r)},o.a.createElement(s.a,{id:n,name:i,value:l&&c?l.find((function(e){return e[u]===c})):"",onChange:function(e){return p(e?e[u]:"",i)},options:l,getOptionLabel:function(e){return e[m]},getOptionValue:function(e){return e[u]},placeholder:y,noOptionsMessage:function(){return"Geen opties gevonden"},loadingMessage:function(){return"Laden"},isMulti:!1,simpleValue:!0,removeSelected:!0,className:g?" has-error":"",isLoading:f,isDisabled:v,styles:I,isClearable:E,theme:function(e){return d(d({},e),{},{colors:d({},e.colors),spacing:d(d({},e.spacing),{},{baseUnit:2,controlHeight:24,menuGutter:4})})}})),g&&o.a.createElement("div",{className:"col-sm-offset-3 col-sm-8"},o.a.createElement("span",{className:"has-error-message"}," ",b)))};m.defaultProps={size:"col-sm-6",divSize:"col-sm-6",optionId:"id",optionName:"name",disabled:!1,required:"",error:!1,errorMessage:"",value:"",isLoading:!1,placeholder:"",clearable:!1},m.propTypes={label:l.a.string.isRequired,size:l.a.string,divSize:l.a.string,id:l.a.string,name:l.a.string.isRequired,options:l.a.array,optionId:l.a.string,optionName:l.a.string,value:l.a.oneOfType([l.a.string,l.a.number]),onChangeAction:l.a.func,onBlurAction:l.a.func,required:l.a.string,disabled:l.a.bool,error:l.a.bool,errorMessage:l.a.string,isLoading:l.a.bool,placeholder:l.a.string,clearable:l.a.bool},t.a=m},761:function(e,t,a){"use strict";
  /*!
   * @license
   * This Source Code Form is subject to the terms of the Mozilla Public
   * License, v. 2.0. If a copy of the MPL was not distributed with this
   * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  /**
   * @file Validation, extraction and creation of IBAN, BBAN, BIC/SWIFT numbers plus some other helpful stuff
   * @author Saša Jovanić
   * @module ibantools
   * @see module:ibantools
   * @version 2.2.0
   * @license MPL-2.0
   */
  function r(e){if(null!=e){var t=new RegExp("^[0-9]{2}$",""),a=p[e.slice(0,2)];if(void 0!==a&&a.IBANRegistry&&a.chars===e.length&&t.test(e.slice(2,4))&&c(e.slice(4),a.bban_regexp)&&function(e){for(var t=parseInt(e.slice(2,4),10),a=e.slice(3)+e.slice(0,2)+"00",r="",n=1;n<a.length;n++){var i=a.charCodeAt(n);r+=i>=65?(i-55).toString():a[n]}for(;r.length>2;){var o=r.slice(0,6);r=(parseInt(o,10)%97).toString()+r.slice(o.length)}return 98-parseInt(r,10)%97===t}(e))return!0}return!1}function n(e,t){if(null!=e&&null!=t){var a=p[t];if(void 0!==a&&a.chars-4===e.length&&c(e,a.bban_regexp))return!0}return!1}function i(e){var t=l(e.bban),a=p[e.countryCode];if(null!==t&&void 0!==a&&a.chars===t.length+4&&c(t,a.bban_regexp)){var r=function(e){e=e.slice(3)+e.slice(0,4);for(var t="",a=1;a<e.length;a++){var r=e.charCodeAt(a);t+=r>=65?(r-55).toString():e[a]}for(;t.length>2;){var n=t.slice(0,6);t=(parseInt(n,10)%97).toString()+t.slice(n.length)}return parseInt(t,10)%97}(e.countryCode+"00"+t);return e.countryCode+("0"+(98-r)).slice(-2)+t}return null}function o(e){var t={};if(t.iban=e,r(e)){t.bban=e.slice(4),t.countryCode=e.slice(0,2);var a=p[t.countryCode];t.countryName=a.name,t.valid=!0}else t.valid=!1;return t}function c(e,t){return new RegExp(t,"").test(e)}function l(e){return"string"!=typeof e?null:e.replace(/[-\ ]/g,"").toUpperCase()}function s(e,t){return"string"!=typeof e?null:(void 0===t&&(t=" "),l(e).replace(/(.{4})(?!$)/g,"$1"+t))}function u(){return p}function d(e){var t=new RegExp("^[a-zA-Z]{6}[a-zA-Z0-9]{2}([a-zA-Z0-9]{3})?$",""),a=p[e.toUpperCase().slice(4,6)];return t.test(e)&&void 0!==a}function m(e){var t={},a=e.toUpperCase();if(d(a)){t.bankCode=a.slice(0,4),t.countryCode=a.slice(4,6);var r=p[t.countryCode];t.countryName=r.name,t.locationCode=a.slice(6,8),t.testBIC="0"===t.locationCode[1],t.branchCode=a.length>8?a.slice(8):"619",t.valid=!0}else t.valid=!1;return t}a.r(t),a.d(t,"isValidIBAN",(function(){return r})),a.d(t,"isValidBBAN",(function(){return n})),a.d(t,"composeIBAN",(function(){return i})),a.d(t,"extractIBAN",(function(){return o})),a.d(t,"electronicFormatIBAN",(function(){return l})),a.d(t,"friendlyFormatIBAN",(function(){return s})),a.d(t,"getCountrySpecifications",(function(){return u})),a.d(t,"isValidBIC",(function(){return d})),a.d(t,"extractBIC",(function(){return m}));var p={AD:{chars:24,bban_regexp:"^[0-9]{8}[A-Z0-9]{12}$",name:"Andorra",IBANRegistry:!0},AE:{chars:23,bban_regexp:"^[0-9]{3}[0-9]{16}$",name:"United Arab Emirates",IBANRegistry:!0},AF:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Afganistan"},AG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Antigua and Bermuda"},AI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Anguilla"},AL:{chars:28,bban_regexp:"^[0-9]{8}[A-Z0-9]{16}$",name:"Albania",IBANRegistry:!0},AM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Armenia"},AO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Angola"},AQ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Antartica"},AR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Argentina"},AS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"American Samoa"},AT:{chars:20,bban_regexp:"^[0-9]{16}$",name:"Austria",IBANRegistry:!0},AU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Australia"},AW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Aruba"},AX:{chars:18,bban_regexp:"^[0-9]{14}$",name:"Åland Islands",IBANRegistry:!0},AZ:{chars:28,bban_regexp:"^[A-Z]{4}[0-9]{20}$",name:"Republic of Azerbaijan",IBANRegistry:!0},BA:{chars:20,bban_regexp:"^[0-9]{16}$",name:"Bosnia and Herzegovina",IBANRegistry:!0},BB:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Barbados"},BD:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bangladesh"},BE:{chars:16,bban_regexp:"^[0-9]{12}$",name:"Belgium",IBANRegistry:!0},BF:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Burkina Faso"},BG:{chars:22,bban_regexp:"^[A-Z]{4}[0-9]{6}[A-Z0-9]{8}$",name:"Bulgaria",IBANRegistry:!0},BH:{chars:22,bban_regexp:"^[A-Z]{4}[A-Z0-9]{14}$",name:"Bahrain",IBANRegistry:!0},BI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Burundi"},BJ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Benin"},BL:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Saint Barthelemy",IBANRegistry:!0},BM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bermuda"},BN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Brunei Darusslam"},BO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bolivia, Plurinational State of"},BQ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bonaire, Sint Eustatius and Saba"},BR:{chars:29,bban_regexp:"^[0-9]{23}[A-Z]{1}[A-Z0-9]{1}$",name:"Brazil",IBANRegistry:!0},BS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bahamas"},BT:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bhutan"},BV:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Bouvet Island"},BW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Botswana"},BY:{chars:28,bban_regexp:"^[A-Z]{4}[0-9]{4}[A-Z0-9]{16}$",name:"Republic of Belarus",IBANRegistry:!0},BZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Belize"},CA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Canada"},CC:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cocos (Keeling) Islands"},CD:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Congo, the Democratic Republic of the"},CF:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Central African Republic"},CG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Congo"},CH:{chars:21,bban_regexp:"^[0-9]{5}[A-Z0-9]{12}$",name:"Switzerland",IBANRegistry:!0},CI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Côte d'Ivoire"},CK:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cook Islands"},CL:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Chile"},CM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cameroon"},CN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"China"},CO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Columbia"},CR:{chars:22,bban_regexp:"^[0-9]{18}$",name:"Costa Rica",IBANRegistry:!0},CU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cuba"},CV:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cabo Verde"},CW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Curaçao"},CX:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Christmas Island"},CY:{chars:28,bban_regexp:"^[0-9]{8}[A-Z0-9]{16}$",name:"Cyprus",IBANRegistry:!0},CZ:{chars:24,bban_regexp:"^[0-9]{20}$",name:"Czech Republic",IBANRegistry:!0},DE:{chars:22,bban_regexp:"^[0-9]{18}$",name:"Germany",IBANRegistry:!0},DJ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Djibouti"},DK:{chars:18,bban_regexp:"^[0-9]{14}$",name:"Denmark",IBANRegistry:!0},DM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Dominica"},DO:{chars:28,bban_regexp:"^[A-Z]{4}[0-9]{20}$",name:"Dominican Republic",IBANRegistry:!0},DZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Algeria"},EC:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Ecuador"},EE:{chars:20,bban_regexp:"^[0-9]{16}$",name:"Estonia",IBANRegistry:!0},EG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Egypt"},EH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Western Sahara"},ER:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Eritrea"},ES:{chars:24,bban_regexp:"^[0-9]{20}$",name:"Spain",IBANRegistry:!0},ET:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Ethiopia"},FI:{chars:18,bban_regexp:"^[0-9]{14}$",name:"Finland",IBANRegistry:!0},FJ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Fiji"},FK:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Falkland Islands (Malvinas)"},FM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Micronesia, Federated States of"},FO:{chars:18,bban_regexp:"^[0-9]{14}$",name:"Faroe Islands (Denmark)",IBANRegistry:!0},FR:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"France",IBANRegistry:!0},GA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Gabon"},GB:{chars:22,bban_regexp:"^[A-Z]{4}[0-9]{14}$",name:"United Kingdom",IBANRegistry:!0},GD:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Grenada"},GE:{chars:22,bban_regexp:"^[A-Z0-9]{2}[0-9]{16}$",name:"Georgia",IBANRegistry:!0},GF:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"French Guyana",IBANRegistry:!0},GG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Guernsey"},GH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Ghana"},GI:{chars:23,bban_regexp:"^[A-Z]{4}[A-Z0-9]{15}$",name:"Gibraltar",IBANRegistry:!0},GL:{chars:18,bban_regexp:"^[0-9]{14}$",name:"Greenland",IBANRegistry:!0},GM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Gambia"},GN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Guinea"},GP:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Guadeloupe",IBANRegistry:!0},GQ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Equatorial Guinea"},GR:{chars:27,bban_regexp:"^[0-9]{7}[A-Z0-9]{16}$",name:"Greece",IBANRegistry:!0},GS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"South Georgia and the South Sandwitch Islands"},GT:{chars:28,bban_regexp:"^[A-Z0-9]{24}$",name:"Guatemala",IBANRegistry:!0},GU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Guam"},GW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Guinea-Bissau"},GY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Guyana"},HK:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Hong Kong"},HM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Heard Island and McDonald Islands"},HN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Honduras"},HR:{chars:21,bban_regexp:"^[0-9]{17}$",name:"Croatia",IBANRegistry:!0},HT:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Haiti"},HU:{chars:28,bban_regexp:"^[0-9]{24}$",name:"Hungary",IBANRegistry:!0},ID:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Indonesia"},IE:{chars:22,bban_regexp:"^[A-Z0-9]{4}[0-9]{14}$",name:"Republic of Ireland",IBANRegistry:!0},IL:{chars:23,bban_regexp:"^[0-9]{19}$",name:"Israel",IBANRegistry:!0},IM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Isle of Man"},IN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"India"},IO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"British Indian Ocean Territory"},IQ:{chars:23,bban_regexp:"^[A-Z]{4}[0-9]{15}$",name:"Iraq",IBANRegistry:!0},IR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Iran, Islamic Republic of"},IS:{chars:26,bban_regexp:"^[0-9]{22}$",name:"Iceland",IBANRegistry:!0},IT:{chars:27,bban_regexp:"^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$",name:"Italy",IBANRegistry:!0},JE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Jersey"},JM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Jamaica"},JO:{chars:30,bban_regexp:"^[A-Z]{4}[0-9]{4}[A-Z0-9]{18}$",name:"Jordan",IBANRegistry:!0},JP:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Japan"},KE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Kenya"},KG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Kyrgyzstan"},KH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cambodia"},KI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Kiribati"},KM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Comoros"},KN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Saint Kitts and Nevis"},KP:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Korea, Domocratic People's Republic of"},KR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Korea, Republic of"},KW:{chars:30,bban_regexp:"^[A-Z]{4}[A-Z0-9]{22}$",name:"Kuwait",IBANRegistry:!0},KY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Cayman Islands"},KZ:{chars:20,bban_regexp:"^[0-9]{3}[A-Z0-9]{13}$",name:"Kazakhstan",IBANRegistry:!0},LA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Lao People's Democratic Republic"},LB:{chars:28,bban_regexp:"^[0-9]{4}[A-Z0-9]{20}$",name:"Lebanon",IBANRegistry:!0},LC:{chars:32,bban_regexp:"^[A-Z]{4}[A-Z0-9]{24}$",name:"Saint Lucia",IBANRegistry:!0},LI:{chars:21,bban_regexp:"^[0-9]{5}[A-Z0-9]{12}$",name:"Liechtenstein",IBANRegistry:!0},LK:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Sri Lanka"},LR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Liberia"},LS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Lesotho"},LT:{chars:20,bban_regexp:"^[0-9]{16}$",name:"Lithuania",IBANRegistry:!0},LU:{chars:20,bban_regexp:"^[0-9]{3}[A-Z0-9]{13}$",name:"Luxembourg",IBANRegistry:!0},LV:{chars:21,bban_regexp:"^[A-Z]{4}[A-Z0-9]{13}$",name:"Latvia",IBANRegistry:!0},LY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Libya"},MA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Marocco"},MC:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Monaco",IBANRegistry:!0},MD:{chars:24,bban_regexp:"^[A-Z0-9]{2}[A-Z0-9]{18}$",name:"Moldova",IBANRegistry:!0},ME:{chars:22,bban_regexp:"^[0-9]{18}$",name:"Montenegro",IBANRegistry:!0},MF:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Saint Martin",IBANRegistry:!0},MG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Madagascar"},MH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Marshall Islands"},MK:{chars:19,bban_regexp:"^[0-9]{3}[A-Z0-9]{10}[0-9]{2}$",name:"Macedonia, the former Yugoslav Republic of",IBANRegistry:!0},ML:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Mali"},MM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Myanman"},MN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Mongolia"},MO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Macao"},MP:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Northern mariana Islands"},MQ:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Martinique",IBANRegistry:!0},MR:{chars:27,bban_regexp:"^[0-9]{23}$",name:"Mauritania",IBANRegistry:!0},MS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Montserrat"},MT:{chars:31,bban_regexp:"^[A-Z]{4}[0-9]{5}[A-Z0-9]{18}$",name:"Malta",IBANRegistry:!0},MU:{chars:30,bban_regexp:"^[A-Z]{4}[0-9]{19}[A-Z]{3}$",name:"Mauritius",IBANRegistry:!0},MV:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Maldives"},MW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Malawi"},MX:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Mexico"},MY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Malaysia"},MZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Mozambique"},NA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Namibia"},NC:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"New Caledonia",IBANRegistry:!0},NE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Niger"},NF:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Norfolk Island"},NG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Nigeria"},NI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Nicaraqua"},NL:{chars:18,bban_regexp:"^[A-Z]{4}[0-9]{10}$",name:"Netherlands",IBANRegistry:!0},NO:{chars:15,bban_regexp:"^[0-9]{11}$",name:"Norway",IBANRegistry:!0},NP:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Nepal"},NR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Nauru"},NU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Niue"},NZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"New Zealand"},OM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Oman"},PA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Panama"},PE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Peru"},PF:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"French Polynesia",IBANRegistry:!0},PG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Papua New Guinea"},PH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Philippines"},PK:{chars:24,bban_regexp:"^[A-Z0-9]{4}[0-9]{16}$",name:"Pakistan",IBANRegistry:!0},PL:{chars:28,bban_regexp:"^[0-9]{24}$",name:"Poland",IBANRegistry:!0},PM:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Saint Pierre et Miquelon",IBANRegistry:!0},PN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Pitcairn"},PR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Puerto Rico"},PS:{chars:29,bban_regexp:"^[A-Z0-9]{4}[0-9]{21}$",name:"Palestine, State of",IBANRegistry:!0},PT:{chars:25,bban_regexp:"^[0-9]{21}$",name:"Portugal",IBANRegistry:!0},PW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Palau"},PY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Paraguay"},QA:{chars:29,bban_regexp:"^[A-Z]{4}[A-Z0-9]{21}$",name:"Qatar",IBANRegistry:!0},RE:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Reunion",IBANRegistry:!0},RO:{chars:24,bban_regexp:"^[A-Z]{4}[A-Z0-9]{16}$",name:"Romania",IBANRegistry:!0},RS:{chars:22,bban_regexp:"^[0-9]{18}$",name:"Serbia",IBANRegistry:!0},RU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Russian Federation"},RW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Rwanda"},SA:{chars:24,bban_regexp:"^[0-9]{2}[A-Z0-9]{18}$",name:"Saudi Arabia",IBANRegistry:!0},SB:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Solomon Islands"},SC:{chars:31,bban_regexp:"^[[A-Z]{4}[]0-9]{20}[A-Z]{3}$",name:"Seychelles",IBANRegistry:!0},SD:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Sudan"},SE:{chars:24,bban_regexp:"^[0-9]{20}$",name:"Sweden",IBANRegistry:!0},SG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Singapore"},SH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Saint Helena, Ascension and Tristan da Cunha"},SI:{chars:19,bban_regexp:"^[0-9]{15}$",name:"Slovenia",IBANRegistry:!0},SJ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Svalbard and Jan Mayen"},SK:{chars:24,bban_regexp:"^[0-9]{20}$",name:"Slovak Republic",IBANRegistry:!0},SL:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Siera Leone"},SM:{chars:27,bban_regexp:"^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$",name:"San Marino",IBANRegistry:!0},SN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Senegal"},SO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Somalia"},SR:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Suriname"},SS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"South Sudan"},ST:{chars:25,bban_regexp:"^[0-9]{21}$",name:"Sao Tome And Principe",IBANRegistry:!0},SV:{chars:28,bban_regexp:"^[A-Z]{4}[0-9]{20}$",name:"El Salvador",IBANRegistry:!0},SX:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Sint Maarten (Dutch part)"},SY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Syrian Arab Republic"},SZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Swaziland"},TC:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Turks and Caicos Islands"},TD:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Chad"},TF:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"French Southern Territories",IBANRegistry:!0},TG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Togo"},TH:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Thailand"},TJ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Tajikistan"},TK:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Tokelau"},TL:{chars:23,bban_regexp:"^[0-9]{19}$",name:"Timor-Leste",IBANRegistry:!0},TM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Turkmenistan"},TN:{chars:24,bban_regexp:"^[0-9]{20}$",name:"Tunisia",IBANRegistry:!0},TO:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Tonga"},TR:{chars:26,bban_regexp:"^[0-9]{5}[A-Z0-9]{17}$",name:"Turkey",IBANRegistry:!0},TT:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Trinidad and Tobago"},TV:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Tuvalu"},TW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Taiwan, Province of China"},TZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Tanzania, United republic of"},UA:{chars:29,bban_regexp:"^[0-9]{6}[A-Z0-9]{19}$",name:"Ukraine",IBANRegistry:!0},UG:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Uganda"},UM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"United States Minor Outlying Islands"},US:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"United States of America"},UY:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Uruguay"},UZ:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Uzbekistan"},VA:{chars:22,bban_regexp:"^[0-9]{18}",IBANRegistry:!0,name:"Vatican City State"},VC:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Saint Vincent and the Granadines"},VE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Venezuela, Bolivian Republic of"},VG:{chars:24,bban_regexp:"^[A-Z0-9]{4}[0-9]{16}$",name:"Virgin Islands, British",IBANRegistry:!0},VI:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Virgin Islands, U.S."},VN:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Viet Nam"},VU:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Vanautu"},WF:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Wallis and Futuna",IBANRegistry:!0},WS:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Samoa"},XK:{chars:20,bban_regexp:"^[0-9]{16}$",name:"Kosovo",IBANRegistry:!0},YE:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Yemen"},YT:{chars:27,bban_regexp:"^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$",name:"Mayotte",IBANRegistry:!0},ZA:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"South Africa"},ZM:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Zambia"},ZW:{chars:null,bban_regexp:null,IBANRegistry:!1,name:"Zimbabwe"}}},800:function(e,t,a){"use strict";a.d(t,"a",(function(){return r})),a.d(t,"b",(function(){return n}));var r=function(e){return{type:"FETCH_ORDER_DETAILS",id:e}},n=function(e,t){return{type:"UPDATE_ORDER",order:e,switchToView:t}}},861:function(e,t,a){"use strict";a.d(t,"d",(function(){return r})),a.d(t,"a",(function(){return n})),a.d(t,"c",(function(){return i})),a.d(t,"e",(function(){return o})),a.d(t,"b",(function(){return c}));var r=function(e,t,a,r){return{type:"FETCH_ORDERS",filters:e,sorts:t,pagination:a,administrationId:r}},n=function(){return{type:"CLEAR_ORDERS"}},i=function(e){return{type:"DELETE_ORDER",id:e}},o=function(e){return{type:"ORDER_PREVIEW_CREATE",data:e}},c=function(){return{type:"CLEAR_ORDER_PREVIEW_CREATE"}}}}]);