1(self["webpackChunkerp_frontend"]=self["webpackChunkerp_frontend"]||[]).push([[5851],{39338:function(t,e,n){"use strict";n.d(e,{A:function(){return p}});var o=function(){var t=this,e=t._self._c;return e("b-modal",{attrs:{id:"treasury-details",active:t.visible,width:"1200px","can-cancel":!1},on:{"after-enter":t.loadInfo,"after-leave":t.onClose}},[e("header",{staticClass:"modal-card-head"},[e("p",{staticClass:"modal-card-title"},[t._v(" Pagos de cuentas por pagar / por cobrar ")]),e("div",{staticClass:"buttons"},[e("b-button",{attrs:{label:"Cerrar"},on:{click:t.onClose}},[t._v(" Cerrar ")])],1)]),e("div",{staticClass:"modal-card-body"},[t.loading?e("b-loading",{attrs:{"is-full-page":!1},model:{value:t.loading,callback:function(e){t.loading=e},expression:"loading"}}):t._e(),t.entity?e("div",[e("div",{staticClass:"level"},[e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[t._v(t._s(t.entity.accountCode))]),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Cuenta ")])])]),e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[e("b-tooltip",{attrs:{label:t.entity.personName,position:"is-right",type:"is-dark",multilined:""}},[t._v(" "+t._s(t.entity.personName.length>40?t.entity.personName.substr(0,40)+"...":t.entity.personName)+" ")])],1),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Contacto ")])])]),e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[t._v(t._s(t.formatToDate(t.entity.documentDate)))]),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Fecha ")])])]),e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[t._v(t._s(t.formatToCurrency(t.entity.reportWalletValue)))]),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Valor ")])])]),e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[t._v(t._s(t.formatToCurrency(t.entity.reportWalletPayment)))]),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Pago ")])])]),e("div",{staticClass:"level-item"},[e("p",[e("span",{staticClass:"is-size-6"},[t._v(t._s(t.formatToCurrency(t.entity.reportWalletBalance)))]),e("br"),e("span",{staticClass:"is-size-6 has-text-grey-light"},[t._v(" Saldo ")])])])]),e("b-table",{attrs:{striped:"",narrowed:"",hoverable:"",bordered:"",data:t.data},scopedSlots:t._u([{key:"footer",fn:function(){return[e("th",{staticClass:"has-text-right",attrs:{colspan:"6"}},[t._v(" TOTAL PAGOS: ")]),e("th",{staticClass:"has-text-right"},[t._v(" "+t._s(t.formatToCurrency(-t.total))+" ")])]},proxy:!0}],null,!1,2109159906)},[e("b-table-column",{attrs:{label:"",width:"30px",centered:""},scopedSlots:t._u([{key:"default",fn:function(n){return[e("b-tooltip",{attrs:{label:"Desvincular",position:"is-right",type:"is-dark"}},[e("a",{on:{click:function(e){return t.onUnlink(n.row)}}},[e("b-icon",{attrs:{icon:"unlink",type:"is-dark",size:"is-medium"}})],1)])]}}],null,!1,1631853547)}),e("b-table-column",{attrs:{label:"Cuenta"},scopedSlots:t._u([{key:"default",fn:function(n){return[e("b-tooltip",{attrs:{label:n.row.accountName,position:"is-right",type:"is-dark"}},[t._v(" "+t._s(n.row.accountCode)+" ")])]}}],null,!1,1104032745)}),e("b-table-column",{attrs:{label:"Contacto"},scopedSlots:t._u([{key:"default",fn:function(n){return[e("b-tooltip",{attrs:{label:n.row.personFullIdentification,position:"is-right",type:"is-dark"}},[t._v(" "+t._s(n.row.personName)+" ")])]}}],null,!1,596524861)}),e("b-table-column",{attrs:{label:"Documento"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.documentFull)+" ")]}}],null,!1,1740050465)}),e("b-table-column",{attrs:{label:"Fecha",width:"80px",centered:""},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(t.formatToDate(e.row.documentDate))+" ")]}}],null,!1,219580843)}),e("b-table-column",{attrs:{label:"Descripción"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.reportWalletDescription)+" ")]}}],null,!1,316667250)}),e("b-table-column",{attrs:{label:"Valor",numeric:""},scopedSlots:t._u([{key:"default",fn:function(n){return[n.row.reportWalletValue>=0?e("b-tooltip",{staticClass:"has-text-danger",attrs:{label:"Este valor se resta en los pagos de la obligación, ya que debe ser una devolución del pago o ajuste a la obligación.",position:"is-left",multilined:""}},[e("b-icon",{attrs:{icon:"exclamation-triangle"}}),t._v(" "+t._s(t.formatToCurrency(n.row.reportWalletValue))+" ")],1):e("span",[t._v(" "+t._s(t.formatToCurrency(-n.row.reportWalletValue))+" ")])]}}],null,!1,3825271932)})],1)],1):t._e()],1)])},r=[],s=(n(18111),n(7588),n(93011)),i=n(43282),a=n(90488),l={name:"TreasuriesModalDetails",props:{visible:{type:Boolean,default:!1},entity:{type:Object,default:null}},data(){return{data:[],loading:!0}},computed:{total(){let t=0;
1return this.data.forEach(e=>{t=parseFloat(t)+parseFloat(e.reportWalletValue)}),t}},methods:{formatToDate:i.nQ,formatToCurrency:i.Ur,async loadInfo(){this.loading=!0;const t={documentId:this.entity.documentId,documentDetailId:this.entity.documentDetailId,reportWalletCode:this.entity.reportWalletCode};s.A.get("reportWallets/findByParent",{params:t}).then(t=>{this.data=t.data}).catch(t=>{console.error("ERROR >> ",t)}).then(()=>{this.loading=!1})},onUnlink(t){this.$buefy.dialog.confirm({title:this.$tc("UnlinkPayment"),message:this.$tc("RecordUnlinkConfirmation"),type:"is-info",hasIcon:!0,iconPack:"fa fa-exclamation-circle fa-2x alert-circle",confirmText:this.$tc("Yes"),cancelText:this.$tc("No"),onConfirm:()=>{const e={documentDetailId:t.documentDetailId,documentId:t.documentId,documentId_Parent:t.documentId_Parent,companyKey:t.companyKey,bizDocumentId:this.entity.bizDocumentId,bizDocumentTypeCode:this.entity.bizDocumentTypeCode};this.loading=!0,s.A.post("documentDetails/unlink",e).then(()=>{(0,a.Q$)(this.$tc("RecordUnlinkedSuccessfully")),this.$emit("success-treasury-details")}).catch(t=>{console.error("onUnlink() >>> ",t)}).then(()=>{this.loading=!1})}})},onClose(){this.$emit("update:visible",!1),this.$emit("close-treasury-details")}}},u=l,c=n(81656),d=(0,c.A)(u,o,r,!1,null,null,null),p=d.exports},51873:function(t,e,n){var o=n(9325),r=o.Symbol;t.exports=r},61074:function(t){function e(t){return t.split("")}t.exports=e},16547:function(t,e,n){var o=n(43360),r=n(75288),s=Object.prototype,i=s.hasOwnProperty;function a(t,e,n){var s=t[e];i.call(t,e)&&r(s,n)&&(void 0!==n||e in t)||o(t,e,n)}t.exports=a},43360:function(t,e,n){var o=n(93243);function r(t,e,n){"__proto__"==e&&o?o(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}t.exports=r},72552:function(t,e,n){var o=n(51873),r=n(659),s=n(59350),i="[object Null]",a="[object Undefined]",l=o?o.toStringTag:void 0;function u(t){return null==t?void 0===t?a:i:l&&l in Object(t)?r(t):s(t)}t.exports=u},72903:function(t,e,n){var o=n(23805),r=n(55527),s=n(90181),i=Object.prototype,a=i.hasOwnProperty;function l(t){if(!o(t))return s(t);var e=r(t),n=[];for(var i in t)("constructor"!=i||!e&&a.call(t,i))&&n.push(i);return n}t.exports=l},97420:function(t,e,n){var o=n(47422),r=n(73170),s=n(31769);function i(t,e,n){var i=-1,a=e.length,l={};while(++i<a){var u=e[i],c=o(t,u);n(c,u)&&r(l,s(u,t),c)}return l}t.exports=i},73170:function(t,e,n){var o=n(16547),r=n(31769),s=n(30361),i=n(23805),a=n(77797);function l(t,e,n,l){if(!i(t))return t;e=r(e,t);var u=-1,c=e.length,d=c-1,p=t;while(null!=p&&++u<c){var f=a(e[u]),h=n;if("__proto__"===f||"constructor"===f||"prototype"===f)return t;if(u!=d){var v=p[f];h=l?l(v,f,p):void 0,void 0===h&&(h=i(v)?v:s(e[u+1])?[]:{})}o(p,f,h),p=p[f]}return t}t.exports=l},28754:function(t,e,n){var o=n(25160);function r(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:o(t,e,n)}t.exports=r},12507:function(t,e,n){var o=n(28754),r=n(49698),s=n(63912),i=n(13222);function a(t){return function(e){e=i(e);var n=r(e)?s(e):void 0,a=n?n[0]:e.charAt(0),l=n?o(n,1).join(""):e.slice(1);return a[t]()+l}}t.exports=a},93243:function(t,e,n){var o=n(56110),r=function(){try{var t=o(Object,"defineProperty");return t({},"",{}),t}catch(e){}}();t.exports=r},34840:function(t,e,n){var o="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;t.exports=o},83349:function(t,e,n){var o=n(82199),r=n(86375),s=n(37241);function i(t){return o(t,s,r)}t.exports=i},28879:function(t,e,n){var o=n(74335),r=o(Object.getPrototypeOf,Object);t.exports=r},659:function(t,e,n){var o=n(51873),r=Object.prototype,s=r.hasOwnProperty,i=r.toString,a=o?o.toStringTag:void 0;function l(t){var e=s.call(t,a),n=t[a];try{t[a]=void 0;var o=!0}catch(l){}var r=i.call(t);return o&&(e?t[a]=n:delete t[a]),r}t.exports=l},86375:function(t,e,n){var o=n(14528),r=n(28879),s=n(4664),i=n(63345),a=Object.getOwnPropertySymbols,l=a?function(t){var e=[];while(t)o(e,s(t)),t=r(t);return e}:i;t.exports=l},49698:function(t){var e="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",s=n+o+r,i="\\ufe0e\\ufe0f",a="\\u200d",l=RegExp("["+a+e+s+i+"]");function u(t){return l.test(t)}t.exports=u},90181:function(t){function e(t){var e=[];
1if(null!=t)for(var n in Object(t))e.push(n);return e}t.exports=e},59350:function(t){var e=Object.prototype,n=e.toString;function o(t){return n.call(t)}t.exports=o},9325:function(t,e,n){var o=n(34840),r="object"==typeof self&&self&&self.Object===Object&&self,s=o||r||Function("return this")();t.exports=s},63912:function(t,e,n){var o=n(61074),r=n(49698),s=n(42054);function i(t){return r(t)?s(t):o(t)}t.exports=i},42054:function(t){var e="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",s=n+o+r,i="\\ufe0e\\ufe0f",a="["+e+"]",l="["+s+"]",u="\\ud83c[\\udffb-\\udfff]",c="(?:"+l+"|"+u+")",d="[^"+e+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",h="\\u200d",v=c+"?",m="["+i+"]?",y="(?:"+h+"(?:"+[d,p,f].join("|")+")"+m+v+")*",b=m+v+y,g="(?:"+[d+l+"?",l,p,f,a].join("|")+")",C=RegExp(u+"(?="+u+")|"+g+b,"g");function _(t){return t.match(C)||[]}t.exports=_},84058:function(t,e,n){var o=n(14792),r=n(45539),s=r(function(t,e,n){return e=e.toLowerCase(),t+(n?o(e):e)});t.exports=s},14792:function(t,e,n){var o=n(13222),r=n(55808);function s(t){return r(o(t).toLowerCase())}t.exports=s},38221:function(t,e,n){var o=n(23805),r=n(10124),s=n(99374),i="Expected a function",a=Math.max,l=Math.min;function u(t,e,n){var u,c,d,p,f,h,v=0,m=!1,y=!1,b=!0;if("function"!=typeof t)throw new TypeError(i);function g(e){var n=u,o=c;return u=c=void 0,v=e,p=t.apply(o,n),p}function C(t){return v=t,f=setTimeout(w,e),m?g(t):p}function _(t){var n=t-h,o=t-v,r=e-n;return y?l(r,d-o):r}function x(t){var n=t-h,o=t-v;return void 0===h||n>=e||n<0||y&&o>=d}function w(){var t=r();if(x(t))return I(t);f=setTimeout(w,_(t))}function I(t){return f=void 0,b&&u?g(t):(u=c=void 0,p)}function k(){void 0!==f&&clearTimeout(f),v=0,u=h=c=f=void 0}function S(){return void 0===f?p:I(r())}function A(){var t=r(),n=x(t);if(u=arguments,c=this,h=t,n){if(void 0===f)return C(h);if(y)return clearTimeout(f),f=setTimeout(w,e),g(h)}return void 0===f&&(f=setTimeout(w,e)),p}return e=s(e)||0,o(n)&&(m=!!n.leading,y="maxWait"in n,d=y?a(s(n.maxWait)||0,e):d,b="trailing"in n?!!n.trailing:b),A.cancel=k,A.flush=S,A}t.exports=u},23805:function(t){function e(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}t.exports=e},40346:function(t){function e(t){return null!=t&&"object"==typeof t}t.exports=e},44394:function(t,e,n){var o=n(72552),r=n(40346),s="[object Symbol]";function i(t){return"symbol"==typeof t||r(t)&&o(t)==s}t.exports=i},37241:function(t,e,n){var o=n(70695),r=n(72903),s=n(64894);function i(t){return s(t)?o(t,!0):r(t)}t.exports=i},10124:function(t,e,n){var o=n(9325),r=function(){return o.Date.now()};t.exports=r},71086:function(t,e,n){var o=n(34932),r=n(15389),s=n(97420),i=n(83349);function a(t,e){if(null==t)return{};var n=o(i(t),function(t){return[t]});return e=r(e),s(t,n,function(t,n){return e(t,n[0])})}t.exports=a},55808:function(t,e,n){var o=n(12507),r=o("toUpperCase");t.exports=r},76952:function(t,e,n){"use strict";n.d(e,{SF:function(){return a},_A:function(){return c},ck:function(){return i},hy:function(){return l},n9:function(){return u}});var o=n(28097),r=n(31973),s=n(47844);const i="222222222222",a=Object.freeze({Company:"Company",Person:"Person"}),l=Object.freeze({Female:"F",Male:"M"}),u=Object.freeze({Saving:"Saving",Checking:"Checking"});function c(t={}){const e=o.c9.now();this.id=null,this.personId=null,this.personName=null,this.personStateReason=null,this.personFirstName=null,this.personSecondName=null,this.personFirstSurname=null,this.personSecondSurname=null,this.identificationTypeCode="31",this.identificationTypeName="NIT",this.personIdentification=null,this.personIdentificationCheck=null,this.personResponsibilities=[],this.personResponsibleFor="01",this.personEconomicActivities=[],this.personKind=a.Company,this.personStatusId=null,this.personStateId=null,this.isLead=!1,this.personIsForeign=!1,this.personIsCustomer=!1,this.personIsAdministrator=!1,this.personIsSeller=!1,this.personIsCashier=!1,this.personIsSupplier=!1,this.personIsEmployee=!1,this.personIsCarrier=!1,this.personHasRetainingIca=!1,this.personHasAttachment=!1,this.personHasDeal=!1,this.personIsSystem=!1,this.withholdingOnSales=!0,this.withholdingOnPurchases=!0,this.accountCodeCausationSell=null,this.accountCodeCausationBuy=null,this.accountCodeCausationExpense=null,this.personEmails=[],this.personEmailReceptionEvents=null,this.personPhoneMobile=null,this.phoneMobileDialCode=57,this.personPhoneWork=null,this.personWebsite=null,this.personBirthday=null,this.personGender=null,this.personBloodType=null,this.personMaritalStatus=null,this.personAgreement=null,this.personAccount=null,this.personOccupation=null,this.personNote=null,this.personAnnualIncome=0,this.personNumberEmployees=0,this.personEconomicActivityRate=0,this.tagIds=[],this.accountCodeEconomicActivity=null,this.accountCode_EconomicActivity=null,this.personIdSeller=null,this.paymentMeanCode=null,this.warehouseId=null,this.priceListId=null,this.currencyCode=(0,r.A)()?.currencyKey||null,this.personRetainingVat=0,this.personCreditLimit=0,this.personCreditDays=0,this.personHasCommission=!1,this.personCommissionSalesValue=0,this.personCommissionSalesIsPercent=!1,this.personCommissionCollectionValue=0,this.personCommissionCollectionIsPercent=!1,this.loyaltyEnabled=!1,this.loyaltyPoints=0,this.loyaltyPointsRedeemable=0,this.loyaltyPointsRedeemed=0,this.loyaltyCode=null,this.userIdOwner=(0,r.A)()?.userId||null,this.lossReasonId=null,this.originId=null,this.territoryId=null,this.heardAboutUsId=null,this.lastActivityDateTime=null,this.userTagOwner=(0,r.A)()?.userEmail||null,this.personHasPayroll=!1,this.personHasAgreement=!1,this.personHasAppEmployee=!1,this.personCurriculum=null,this.personStatus="Activo",this.personBankAccountType=null,this.bankId=null,this.personBankAccountNumber=null,this.createdAt=e.toISO({includeOffset:!1}),this.createdBy=null,this.createdById=null,this.updatedAt=e.toISO({includeOffset:!1}),this.updatedBy=null,this.updatedById=null,this.itemId=null,this.address=[],this.customField={};for(const n in t)n in this&&(this[n]=t[n]);this.personId=this.personId||(0,s.A)(),this.id=this.id||(0,s.A)()}},57957:function(t,e,n){"use strict";n.d(e,{GK:function(){return u},Uh:function(){return a},Xo:function(){return c}});n(74423),n(44114),n(18111),n(61806),n(69112),n(14603),n(47566),n(98721);var o=n(93011),r=n(49761),s=n(23041),i=n(48287);function a(t,e){const n=URL.createObjectURL(t),o=document.createElement("a"),r=()=>{setTimeout(()=>{setTimeout(()=>URL.revokeObjectURL(n),3e5),o.removeEventListener("click",r),o.remove&&(o.remove(),1)||o.parentNode?.removeChild(o)},150)};o.setAttribute("href",n),o.setAttribute("download",e),o.addEventListener("click",r,!1),o.click()}function l(t,e=null){const{href:n,route:o}=r.Ay.resolve(t);switch(e){case"_blank":return window.open(n,"_blank");
1case"_self":default:r.Ay.push(o)}}async function u(t){const e=await o.A.get("exports",{params:t,responseType:"blob"});if("application/json"===e.data.type){const t=JSON.parse(await e.data.text());return void l(t,"_blank")}const n=URL.createObjectURL(e.data),r=document.createElement("a"),s=()=>{setTimeout(()=>{setTimeout(()=>URL.revokeObjectURL(n),3e5),r.removeEventListener("click",s),r.remove&&(r.remove(),1)||r.parentNode?.removeChild(r)},150)};var a=e.headers["content-disposition"].replace(/attachment; filename\*?=['"]?(?:UTF-\d['"]*)?([^;\r\n"']*)['"]?;?/i,"$1");a.includes("?utf-8?")&&(a=a.split("?")[3],a=i.hp.from(a,"base64").toString("utf-8")),r.setAttribute("href",n),r.setAttribute("download",a),r.addEventListener("click",s,!1),r.click()}async function c(t){if(!t)return null;const e=new FileReader,{data:n}=await o.A.get("https://app.aliaddo.net/logo/signUrl",{params:{url:t,redirect:!1}}),{data:r}=await s.A.get(n,{responseType:"blob"});if(r.size<=0&&console.warn("La respuesta del servidor está vacÃa"),e.readAsDataURL(r),await new Promise(t=>e.addEventListener("load",t)),"object"===typeof e.result){e.result.byteLength<=0&&console.warn("La respuesta del servidor no se pudo leer");const t=e.result,n=i.hp.from(t),o=n.toString("base64");return o||console.warn("La respuesta del servidor entregó un archivo vacÃo"),`data:application/octet-stream;base64,${o}`}e.result||console.warn("La respuesta del servidor no se pudo leer");const[a]=e.result.matchAll(/data:(?<mediatype>.*);base64,(?<base64data>.*)/g).toArray();a||console.warn("La respuesta del servidor es inválida");const{mediatype:l,base64data:u}=a.groups||{};return u||console.warn("La respuesta del servidor entregó un archivo vacÃo"),"application/octet-stream"===l?console.warn("La respuesta del servidor entregó un archivo que no es una imagen, es un tipo de archivo desconocido"):l.startsWith("image/")||console.warn("La respuesta del servidor entregó un archivo que no es una imagen",{mediatype:l}),e.result}},85239:function(t,e,n){"use strict";n.d(e,{C:function(){return s},d:function(){return i}});n(69112),n(33110),n(64979),n(71678);var o=n(84058),r=n.n(o);function s(t){const e={};for(const n in t)e[r()(n)]=t[n];return e}function i(t){return"undefined"!==typeof structuredClone?structuredClone(t):JSON.parse(JSON.stringify(t))}},61806:function(t,e,n){"use strict";var o=n(46518),r=n(28551),s=n(97040),i=n(72652),a=n(1767);o({target:"Iterator",proto:!0,real:!0},{toArray:function(){var t=[],e=0;return i(a(r(this)),function(n){s(t,e++,n)},{IS_RECORD:!0}),t}})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.