dealposbooks 1.9.6-p5 → 1.9.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/3rdpartylicenses.txt +26 -26
- package/assets/scss/style.scss +30 -0
- package/{chunk-RBDJZRHY.js → chunk-27P5HOS3.js} +1 -1
- package/chunk-2HOHR6C5.js +1 -0
- package/{chunk-CSMMP7XG.js → chunk-35ER6BC7.js} +1 -1
- package/{chunk-BNI5KUDE.js → chunk-3GHEXAAZ.js} +3 -3
- package/chunk-3HGVSC6D.js +7 -0
- package/{chunk-TC43COAE.js → chunk-3RM5CDGW.js} +1 -1
- package/{chunk-G6FJQBZZ.js → chunk-3ZFQSQVU.js} +1 -1
- package/chunk-45VFBAOS.js +1 -0
- package/{chunk-46TNY5N4.js → chunk-4V5YFD3N.js} +1 -1
- package/chunk-6332DY2I.js +82 -0
- package/chunk-6EL7TGVK.js +1 -0
- package/{chunk-OVCTOPAO.js → chunk-6PS3NJ62.js} +1 -1
- package/{chunk-J2SK4PGN.js → chunk-77BBQI2T.js} +1 -1
- package/{chunk-PGECEXRR.js → chunk-7ET5CSOO.js} +1 -1
- package/{chunk-6ZZARVQO.js → chunk-7IPVVF6Y.js} +1 -1
- package/chunk-7JGGV5FX.js +1 -0
- package/chunk-7TOJMYLE.js +1 -0
- package/chunk-AQRLC7NB.js +1 -0
- package/chunk-AZWJMXL6.js +449 -0
- package/chunk-BDJHC5O6.js +2 -0
- package/{chunk-IIB2DZLA.js → chunk-BPFL7VRT.js} +1 -1
- package/{chunk-EXVUABTO.js → chunk-BX74ZLQG.js} +1 -1
- package/chunk-C32DCO2H.js +1 -0
- package/chunk-C3N6HRIE.js +1 -0
- package/{chunk-TFV5QZKR.js → chunk-CEZEYAWZ.js} +1 -1
- package/chunk-CGUMUBB7.js +1 -0
- package/chunk-CIG34QJJ.js +129 -0
- package/{chunk-JDW35ZB5.js → chunk-CNLYDNON.js} +1 -1
- package/chunk-CUDRSVFH.js +1 -0
- package/{chunk-JP3F2QND.js → chunk-CZWWMQFD.js} +1 -1
- package/{chunk-BYD3JK4R.js → chunk-DAQCANBV.js} +1 -1
- package/{chunk-OZACNHDP.js → chunk-DJAICZNR.js} +1 -1
- package/chunk-DXIZC3FM.js +87 -0
- package/chunk-EJCLRSB2.js +1 -0
- package/chunk-EVVQ2SFY.js +1 -0
- package/{chunk-OEOAUJY5.js → chunk-FDZFCC3N.js} +1 -1
- package/{chunk-4S33ZRKF.js → chunk-FTI2QPWV.js} +1 -1
- package/{chunk-ASK2IVMC.js → chunk-H6BPUKCW.js} +1 -1
- package/{chunk-TK3G2BVM.js → chunk-HFUW7PYZ.js} +1 -1
- package/chunk-I3BTHUK3.js +160 -0
- package/chunk-IY6KCAQ4.js +1 -0
- package/{chunk-JMLETF7Y.js → chunk-J6H5UCJR.js} +1 -1
- package/chunk-JL2CIZE7.js +1 -0
- package/{chunk-J77A3DFB.js → chunk-JO3SI6HU.js} +1 -1
- package/{chunk-32BR7AQL.js → chunk-JZTK7BS7.js} +1 -1
- package/{chunk-P6CJ2ONT.js → chunk-K4ALA724.js} +1 -1
- package/{chunk-NF3TF3LT.js → chunk-KANHSSLO.js} +1 -1
- package/chunk-L5AUQL23.js +1 -0
- package/chunk-L66QS3IX.js +81 -0
- package/{chunk-YOEPO6LK.js → chunk-LMI4DLB5.js} +1 -1
- package/{chunk-GJXWL5XV.js → chunk-LWYZZP3I.js} +1 -1
- package/chunk-MF7TC5KB.js +1 -0
- package/chunk-NC6RBSOA.js +1 -0
- package/{chunk-3L7IWFXM.js → chunk-NR3EHEG3.js} +1 -1
- package/chunk-NXCHPBCH.js +1 -0
- package/chunk-OXGCSUUS.js +2 -0
- package/{chunk-LTZA6IIO.js → chunk-PDNXU4MC.js} +1 -1
- package/chunk-QVQOBBLJ.js +1 -0
- package/chunk-R6NK3ROE.js +1 -0
- package/{chunk-54OPMMIM.js → chunk-R6XNFCQM.js} +1 -1
- package/{chunk-HRQJ5DXP.js → chunk-RLR2HFSC.js} +1 -1
- package/{chunk-HFFH2WIX.js → chunk-RNOSD5RO.js} +1 -1
- package/chunk-RQ52IUQY.js +130 -0
- package/{chunk-DOM7WYRM.js → chunk-RSGEQTNJ.js} +1 -1
- package/{chunk-35CWG2OK.js → chunk-RYHNURUZ.js} +2 -2
- package/{chunk-3DN7TZCI.js → chunk-SH4ALZVS.js} +1 -1
- package/{chunk-3HW557B7.js → chunk-TDMJ2M6W.js} +1 -1
- package/chunk-TE7Y3LKA.js +1 -0
- package/{chunk-AKMHO3LC.js → chunk-TIX3GAPF.js} +1 -1
- package/{chunk-XKEV5AED.js → chunk-TLLNQB5C.js} +1 -1
- package/{chunk-C5GEP4MM.js → chunk-U75O34AW.js} +1 -1
- package/{chunk-I3HFXOYS.js → chunk-UNWDCLFZ.js} +1 -1
- package/chunk-UWWFSGE7.js +1 -0
- package/{chunk-6TA77CRR.js → chunk-V4IY7RIP.js} +1 -1
- package/chunk-VDBXI7BY.js +1 -0
- package/{chunk-RT5PUZ5F.js → chunk-VJLO7GNT.js} +1 -1
- package/chunk-VP6GWJ6D.js +1 -0
- package/{chunk-LKZL77YR.js → chunk-W4KTL6Y6.js} +1 -1
- package/{chunk-ZWHB7NI7.js → chunk-W6LBFCQQ.js} +1 -1
- package/{chunk-YVEUYFCE.js → chunk-WCXWWANV.js} +5 -5
- package/chunk-WVPOYMTO.js +1 -0
- package/{chunk-LR2DJRRL.js → chunk-WWWY3VE7.js} +1 -1
- package/{chunk-7WXXPCRV.js → chunk-XYU65DNE.js} +1 -1
- package/{chunk-34XRAZFC.js → chunk-Y45TAHWD.js} +1 -1
- package/chunk-YGADGNDB.js +1 -0
- package/chunk-YJ3CWPO4.js +1 -0
- package/{chunk-3WB76KQC.js → chunk-YVGWGEPX.js} +1 -1
- package/chunk-YXXRJV2N.js +1 -0
- package/{chunk-TQZNJ5WF.js → chunk-Z3SHAW6W.js} +1 -1
- package/{chunk-AOSPVPK7.js → chunk-ZHU3HOWQ.js} +1 -1
- package/chunk-ZWA7RUAY.js +1 -0
- package/index.html +2 -2
- package/{main-U5PC2W2C.js → main-VZEZO7AT.js} +1 -1
- package/package.json +1 -1
- package/{styles-GTUKYMN7.css → styles-XXVTW56A.css} +1 -1
- package/chunk-27SWEVDU.js +0 -1
- package/chunk-2DV653RD.js +0 -1
- package/chunk-2OECREUZ.js +0 -1
- package/chunk-35KDUCM3.js +0 -1
- package/chunk-3G3QSUWH.js +0 -1
- package/chunk-43WCLYRX.js +0 -1
- package/chunk-4FGQ5T64.js +0 -2
- package/chunk-4KXSM3HP.js +0 -1
- package/chunk-4QKRWFW4.js +0 -1
- package/chunk-6HQX2SM2.js +0 -1
- package/chunk-B7JILYJO.js +0 -1
- package/chunk-BX3CRF44.js +0 -1
- package/chunk-C4LZX33Q.js +0 -449
- package/chunk-C7UZ6ZYF.js +0 -1
- package/chunk-CTCQB63H.js +0 -1
- package/chunk-DNK2GUDB.js +0 -1
- package/chunk-ELWFWCNU.js +0 -246
- package/chunk-GNP7WGSH.js +0 -1
- package/chunk-GTGRV7IH.js +0 -1
- package/chunk-HRPP75N7.js +0 -1
- package/chunk-JYNZPVLW.js +0 -1
- package/chunk-K6753MGR.js +0 -7
- package/chunk-LD4G6ND6.js +0 -130
- package/chunk-M7MFX6BW.js +0 -1
- package/chunk-MCDQ2TIS.js +0 -1
- package/chunk-MJVSTWYY.js +0 -1
- package/chunk-N2RYBZK7.js +0 -1
- package/chunk-N6JCA3CN.js +0 -2
- package/chunk-OEJBOFI5.js +0 -1
- package/chunk-QPKNYNLC.js +0 -210
- package/chunk-UEOO2LYA.js +0 -82
- package/chunk-WEWEITR7.js +0 -1
- package/chunk-WGZN6AN2.js +0 -1
- package/chunk-WZO2ZLBL.js +0 -1
- package/chunk-X34Y3TVX.js +0 -1
- package/chunk-XFSZDZPJ.js +0 -1
- package/chunk-XZGFG6E3.js +0 -1
package/chunk-OEJBOFI5.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as be}from"./chunk-RBDJZRHY.js";import"./chunk-P6CJ2ONT.js";import{a as ge,b as ye,c as Ce,d as ve,e as Ee,f as he}from"./chunk-46TNY5N4.js";import{b as xe,c as Te,d as Ie}from"./chunk-3L7IWFXM.js";import{d as de,f as ce,g as _e,h as ue,k as fe}from"./chunk-TFV5QZKR.js";import"./chunk-3WB76KQC.js";import"./chunk-LTZA6IIO.js";import{a as T}from"./chunk-B7JILYJO.js";import"./chunk-HFFH2WIX.js";import"./chunk-TK3G2BVM.js";import"./chunk-LR2DJRRL.js";import"./chunk-CSMMP7XG.js";import"./chunk-6TA77CRR.js";import"./chunk-JMLETF7Y.js";import"./chunk-C5GEP4MM.js";import"./chunk-TC43COAE.js";import{a as oe,b as re}from"./chunk-JDW35ZB5.js";import"./chunk-WZO2ZLBL.js";import{a as me,b as se}from"./chunk-6ZZARVQO.js";import{e as ae,f as le,h as pe}from"./chunk-35CWG2OK.js";import"./chunk-EXVUABTO.js";import"./chunk-4S33ZRKF.js";import"./chunk-4FGQ5T64.js";import{w as ne,x as ie}from"./chunk-YOEPO6LK.js";import"./chunk-ZWHB7NI7.js";import"./chunk-BNI5KUDE.js";import"./chunk-35KDUCM3.js";import"./chunk-3HW557B7.js";import{E as te,c as G,f as X,k as Y,l as Z,m as ee}from"./chunk-BYD3JK4R.js";import"./chunk-F2X3VGZZ.js";import{Cb as c,Ga as h,I as U,Ic as J,Jc as D,Kb as m,Kc as q,Lc as d,Nb as V,Pb as v,Qb as A,Sb as F,Tb as P,Ub as n,Vb as i,Wb as _,X as N,Z as S,_b as C,dc as y,eb as O,ec as s,gb as l,ha as R,jc as K,kc as H,lc as L,m as M,oc as $,pa as x,pc as r,qa as g,qc as u,rc as I,s as B,uc as W,vc as Q,wb as j,wc as z,yc as w,zc as b}from"./chunk-YVEUYFCE.js";import{e as Je}from"./chunk-YQFG5XE2.js";var Se=Je(Te());var ke=["stepper"],Re=()=>({width:"30vw"}),Ve=()=>({"1199px":"75vw","575px":"100vw"}),Ae=()=>({height:"calc(100vh - 70px)"}),Fe=t=>({"justify-content-center":t}),Pe=t=>({"col-12":t}),we=t=>({"state-danger":t});function De(t,p){if(t&1){let e=C();n(0,"p-button",14),y("click",function(){x(e);let o=s(2);return g(o.onPrevStep())}),i()}if(t&2){let e=s(2);m("disabled",e.stepActiveIndex()===1)}}function Me(t,p){if(t&1){let e=C();n(0,"p-button",15),y("click",function(){x(e);let o=s(2);return g(o.onNextStep())}),i()}if(t&2){let e=s(2);m("disabled",e.stepActiveIndex()===3||!e.JournalEntryImport())}}function Be(t,p){if(t&1){let e=C();n(0,"p-button",16),y("click",function(){x(e);let o=s(2);return g(o.onReset())}),i()}}function Ue(t,p){if(t&1&&c(0,De,1,1,"p-button",11)(1,Me,1,1,"p-button",12)(2,Be,1,0,"p-button",13),t&2){let e=s();m("ngIf",e.stepActiveIndex()>1),l(),m("ngIf",e.stepActiveIndex()<3),l(),m("ngIf",e.stepActiveIndex()===3)}}function Ne(t,p){if(t&1){let e=C();n(0,"POS-uppy",25),y("fileUploaded",function(o){x(e);let f=s(2);return g(f.onFileUploaded(o))})("fileRemoved",function(o){x(e);let f=s(2);return g(f.onFileRemoved(o))}),i(),n(1,"p",26),r(2," Please refer this "),n(3,"a",27),r(4,"article"),i(),r(5," for more information "),i()}if(t&2){let e=s(2);m("uppyCoreConfiguration",e.uppyCore)("dashboardPropsConfiguration",e.uppyDashboardConfiguration)("sampleUrl",e.SAMPLE_URL)("subtitle",e.subtitle)}}function Oe(t,p){t&1&&(n(0,"tr"),_(1,"th",29),n(2,"th",30),r(3," Number "),_(4,"p-sortIcon",31),i(),n(5,"th",32),r(6," Outlet "),_(7,"p-sortIcon",33),i(),n(8,"th",34),r(9," Date "),_(10,"p-sortIcon",35),i(),n(11,"th",36),r(12," Status "),_(13,"p-sortIcon",37),i(),n(14,"th"),r(15,"Message"),i()())}function je(t,p){if(t&1&&(n(0,"div",41)(1,"span"),r(2),i(),n(3,"span"),r(4),i()()),t&2){let e=p.$implicit;l(2),u(e.issue),l(2),u(e.solution)}}function Ke(t,p){if(t&1&&(n(0,"div",40),F(1,je,5,2,"div",41,A),i()),t&2){let e=s(2).$implicit;l(),P(e.issues)}}function He(t,p){t&1&&(n(0,"div"),r(1," We found error in account item, please check your item! "),i())}function Le(t,p){if(t&1&&c(0,Ke,3,0,"div",40)(1,He,2,0,"div"),t&2){let e=s().$implicit;v(e.issues&&e.issues.length>0?0:1)}}function $e(t,p){if(t&1&&(n(0,"tr")(1,"td"),_(2,"p-button",38),i(),n(3,"td"),r(4),i(),n(5,"td"),r(6),i(),n(7,"td"),r(8),J(9,"date"),i(),n(10,"td"),r(11),i(),n(12,"td",39),c(13,Le,2,1),i()()),t&2){let e=p.$implicit,a=p.expanded,o=s(4);l(2),m("pRowToggler",e)("text",!0)("rounded",!0)("plain",!0)("icon",a?"fa-solid fa-chevron-down":"fa-solid fa-chevron-right"),l(2),u(e.number),l(2),I(" ",e.outlet," "),l(2),u(q(9,11,e.date,"d MMM y")),l(3),u(e.actionName),l(),m("ngClass",b(14,we,o.hasIssue)),l(),v(o.hasIssue?13:-1)}}function We(t,p){t&1&&(n(0,"tr")(1,"th",45),r(2," Code "),_(3,"p-sortIcon",46),i(),n(4,"th",47),r(5," Name "),_(6,"p-sortIcon",48),i(),n(7,"th",49),r(8," Note "),_(9,"p-sortIcon",50),i(),n(10,"th",51),r(11," Debit "),_(12,"p-sortIcon",52),i(),n(13,"th",53),r(14," Credit "),_(15,"p-sortIcon",54),i(),n(16,"th"),r(17,"Message"),i()())}function Qe(t,p){if(t&1&&(n(0,"div",41)(1,"span"),r(2),i(),n(3,"span"),r(4),i()()),t&2){let e=p.$implicit;l(2),u(e.issue),l(2),u(e.solution)}}function ze(t,p){if(t&1&&(n(0,"div",40),F(1,Qe,5,2,"div",41,A),i()),t&2){let e=s().$implicit;l(),P(e.issues)}}function qe(t,p){if(t&1&&(n(0,"tr")(1,"td"),r(2),i(),n(3,"td"),r(4),i(),n(5,"td"),r(6),i(),n(7,"td"),r(8),J(9,"number"),i(),n(10,"td"),r(11),J(12,"number"),i(),n(13,"td",39),c(14,ze,3,0,"div",40),i()()),t&2){let e=p.$implicit,a=s(5);l(2),u(e.accountCode),l(2),u(e.accountName),l(2),u(e.note),l(2),I(" ",D(9,7,e.debitAmount)," "),l(3),I(" ",D(12,9,e.creditAmount)," "),l(2),m("ngClass",b(11,we,e.issues&&e.issues.length>0)),l(),v(a.hasIssue?14:-1)}}function Ge(t,p){t&1&&(n(0,"tr")(1,"td",55),r(2," There are no order for this product yet. "),i()())}function Xe(t,p){if(t&1&&(n(0,"tr")(1,"td",42)(2,"div",43)(3,"p-table",44),c(4,We,18,0,"ng-template",null,3,d)(6,qe,15,13,"ng-template",null,6,d)(8,Ge,3,0,"ng-template",null,8,d),i()()()()),t&2){let e=p.$implicit;l(3),m("value",e.items)}}function Ye(t,p){if(t&1&&(n(0,"p-table",28),c(1,Oe,16,0,"ng-template",null,3,d)(3,$e,14,16,"ng-template",null,6,d)(5,Xe,10,1,"ng-template",null,7,d),i()),t&2){let e=s(3);m("scrollable",!0)("scrollHeight","calc(100vh - 160px)")("value",e.JournalEntryImport().dataRow)}}function Ze(t,p){if(t&1&&c(0,Ye,7,3,"p-table",28),t&2){let e=s(2);v(e.JournalEntryImport()?0:-1)}}function et(t,p){t&1&&(n(0,"h5"),r(1,"Successfully Imported"),i())}function tt(t,p){if(t&1&&(n(0,"p-panel")(1,"div",17)(2,"div",18)(3,"p-stepper",19,5)(5,"p-step-list")(6,"p-step",20)(7,"div",21),_(8,"i",22),n(9,"span"),r(10,"Upload"),i()()(),n(11,"p-step",20)(12,"div",21),_(13,"i",23),n(14,"span"),r(15,"Preview"),i()()(),n(16,"p-step",20)(17,"div",21),_(18,"i",24),n(19,"span"),r(20,"Finish"),i()()()(),n(21,"p-step-panels")(22,"p-step-panel",20),c(23,Ne,6,4,"ng-template",null,1,d),i(),n(25,"p-step-panel",20),c(26,Ze,1,1,"ng-template",null,1,d),i(),n(28,"p-step-panel",20),c(29,et,2,0,"ng-template",null,1,d),i()()()()()()),t&2){let e=s();V(w(12,Ae)),l(),m("ngClass",b(13,Fe,e.stepActiveIndex()===1||e.stepActiveIndex()===3)),l(),m("ngClass",b(15,Pe,e.stepActiveIndex()===2)),l(),m("linear",!0)("value",e.stepActiveIndex()),l(3),m("value",1),l(5),m("value",2),l(5),m("value",3),l(6),m("value",1),l(3),m("value",2),l(3),m("value",3)}}function nt(t,p){if(t&1){let e=C();n(0,"p-button",56),y("onClick",function(){x(e);let o=s();return g(o.summaryDialogVisible.set(!1))}),i()}t&2&&m("rounded",!0)("text",!0)}function it(t,p){if(t&1&&(n(0,"div",57)(1,"h4",58),r(2,"Import Summary"),i(),n(3,"p",59),r(4),i()()),t&2){let e=s();l(4),I("(",e.CSVRowCount()," rows ready for import)")}}function ot(t,p){t&1&&(n(0,"div",62)(1,"h4",63),r(2,"New"),i()())}function rt(t,p){t&1&&(n(0,"div",64)(1,"h4",63),r(2,"Updated"),i()())}function at(t,p){t&1&&(n(0,"div",65)(1,"h4",63),r(2,"Unchanged"),i()())}function lt(t,p){t&1&&(n(0,"div",66)(1,"h4",63),r(2,"Error"),i()())}function pt(t,p){if(t&1&&(n(0,"div",60)(1,"div",61)(2,"p-card"),c(3,ot,3,0,"ng-template",null,3,d),n(5,"div",60)(6,"div",61)(7,"h5"),r(8),i()()()()()(),_(9,"br"),n(10,"div",60)(11,"div",61)(12,"p-card"),c(13,rt,3,0,"ng-template",null,3,d),n(15,"div",60)(16,"div",61)(17,"h5"),r(18),i()()()()(),n(19,"div",61)(20,"p-card"),c(21,at,3,0,"ng-template",null,3,d),n(23,"div",60)(24,"div",61)(25,"h5"),r(26),i()()()()(),n(27,"div",61)(28,"p-card"),c(29,lt,3,0,"ng-template",null,3,d),n(31,"div",60)(32,"div",61)(33,"h5"),r(34),i()()()()()()),t&2){let e=s(2);l(8),u(e.JournalEntryImport().summary.new),l(10),u(e.JournalEntryImport().summary.updated),l(8),u(e.JournalEntryImport().summary.noChanges),l(8),u(e.JournalEntryImport().summary.error)}}function mt(t,p){if(t&1&&c(0,pt,35,4),t&2){let e=s();v(e.JournalEntryImport()?0:-1)}}function st(t,p){if(t&1){let e=C();n(0,"p-button",67),y("click",function(){x(e);let o=s();return g(o.summaryDialogVisible.set(!1))}),i(),n(1,"p-button",68),y("click",function(){x(e);let o=s();return g(o.onConfirmImport())}),i()}}var Ut=(()=>{class t{constructor(){this.service=R(be),this.router=R(te),this.subtitle="Accepted file format: .csv & max file size: 1MB",this.stepActiveIndex=h(1),this.JournalEntryImport=h(null),this.summaryDialogVisible=h(!1),this.CSVRowCount=h(0),this.uppyDashboardConfiguration={width:250},this.uppyCore={restrictions:{allowedFileTypes:["text/csv","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"]}},this.SAMPLE_URL="https://res.cloudinary.com/pos/raw/upload/POS/CSV/Journal_DealPOS.csv"}ngAfterViewInit(){console.log("Stepper instance:",this.stepperRef)}onFileUpload(e){console.log("File upload event:",e);let a=new FormData;Array.isArray(e.currentFiles)&&e.currentFiles.forEach(o=>{o instanceof File&&a.append("File",o,o.name)}),console.log("Form data prepared for upload:",a.get("File")),this.service.importPreviewJournal(a).pipe(T("Import Preview"),B(o=>({cacheKey:o.cacheKey})),N(o=>this.service.importConfirmJournal(o)),S(()=>{this.router.navigate(["/pages/journal/journal-entry"])})).subscribe()}onFileRemoved(e){console.log("File removed event:",e),this.JournalEntryImport.set(null),this.CSVRowCount.set(0)}onNextStep(){if(this.stepActiveIndex()<3&&(this.stepActiveIndex.update(e=>e+1),this.stepActiveIndex()===3)){this.stepActiveIndex.update(()=>this.stepActiveIndex()-1),this.summaryDialogVisible.set(!0);return}}onPrevStep(){this.stepActiveIndex()>1&&this.stepActiveIndex.update(e=>e-1)}onFileUploaded(e){let a=new FormData;if("name"in e&&typeof e.name=="string")a.append("File",e,e.name),this.service.importPreviewJournal(a).pipe(T("Import Preview"),S(o=>{this.JournalEntryImport.set(o)})).subscribe(),Se.default.parse(e,{header:!0,skipEmptyLines:!0,complete:o=>{console.log("CSV Parsing Results:",o),this.CSVRowCount.set(o.data.length)},error:o=>{console.error("Error parsing CSV:",o)}});else return}getJournalEntryImportCount(){let e=this.JournalEntryImport();return e&&e.summary?.total!==void 0?e.summary.total:0}onConfirmImport(){if(this.JournalEntryImport()&&this.JournalEntryImport().canProceed){let e={cacheKey:this.JournalEntryImport().cacheKey};this.service.importConfirmJournal(e).pipe(T("Import Confirm"),S(()=>{this.router.navigate(["/pages/journal/journal-entry"]),this.stepActiveIndex.update(a=>a+1),this.summaryDialogVisible.update(a=>!a)}),U(a=>(console.error("Error occurred during import confirmation:",a),this.stepActiveIndex.update(o=>o+1),this.summaryDialogVisible.update(o=>!o),M(null)))).subscribe()}else{console.error("Cannot proceed with import, JournalEntryImport is not set or canProceed is false.");return}}onReset(){this.stepActiveIndex.set(1),this.JournalEntryImport.set(null)}handleKeyboardEvent(e){e.key==="F2"&&this.onConfirmImport()}get hasIssue(){let e=this.JournalEntryImport();return e&&Array.isArray(e.dataRow)?e.dataRow.some(a=>{let o=a.issues&&a.issues.length>0,f=a.items&&a.items.some(E=>E.issues&&E.issues.length>0);return o||f}):!1}static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=j({type:t,selectors:[["app-journal-entry-import"]],viewQuery:function(a,o){if(a&1&&K(ke,5),a&2){let f;H(f=L())&&(o.stepperRef=f.first)}},hostBindings:function(a,o){a&1&&y("keydown",function(E){return o.handleKeyboardEvent(E)},!1,O)},decls:14,vars:10,consts:[["actionButton",""],["content",""],["closeIconTemplate",""],["header",""],["footer",""],["stepper",""],["body",""],["expandedrow",""],["emptymessage",""],["pageTitle","Manual Journal Import"],["position","center","appendTo","body",3,"visibleChange","modal","visible","breakpoints","draggable","closeIconTemplate","dismissableMask"],["label","Back","severity","secondary","variant","outlined",3,"disabled","click",4,"ngIf"],["label","Next","severity","primary",3,"disabled","click",4,"ngIf"],["label","Finish","severity","primary",3,"click",4,"ngIf"],["label","Back","severity","secondary","variant","outlined",3,"click","disabled"],["label","Next","severity","primary",3,"click","disabled"],["label","Finish","severity","primary",3,"click"],[1,"row",3,"ngClass"],[1,"col-6",3,"ngClass"],[1,"basis-[50rem]",3,"linear","value"],[3,"value"],[1,"d-flex","gap-2","align-items-center"],[1,"fa-solid","fa-upload"],[1,"fa-solid","fa-file"],[1,"fa-solid","fa-check"],[3,"fileUploaded","fileRemoved","uppyCoreConfiguration","dashboardPropsConfiguration","sampleUrl","subtitle"],[1,"fst-italic"],["href","#","target","_blank",1,"link","link-primary"],["dataKey","number",3,"scrollable","scrollHeight","value"],[2,"width","5rem"],["pSortableColumn","number"],["field","number"],["pSortableColumn","outlet"],["field","outlet"],["pSortableColumn","date"],["field","date"],["pSortableColumn","inventoryStatus"],["field","inventoryStatus"],["type","button","pRipple","",3,"pRowToggler","text","rounded","plain","icon"],[3,"ngClass"],[1,"d-flex","flex-column","gap-2"],[1,"d-flex","flex-column"],["colspan","8"],[1,"p-4"],["dataKey","accountID",3,"value"],["pSortableColumn","accountCode"],["field","accountCode"],["pSortableColumn","accountName"],["field","accountName"],["pSortableColumn","note"],["field","note"],["pSortableColumn","debitAmount"],["field","debitAmount"],["pSortableColumn","creditAmount"],["field","creditAmount"],["colspan","6"],["severity","secondary","variant","outlined","icon","fa-solid fa-xmark",3,"onClick","rounded","text"],[1,"d-flex","gap-2","align-items-baseline"],[1,"fs-4","text-white","m-0"],[1,"m-0","fs-3"],[1,"row"],[1,"col"],[1,"state-new"],[1,"fs-4","m-0"],[1,"state-updated"],[1,"state-unchanged"],[1,"state-error"],["label","Cancel","severity","secondary","variant","outlined",3,"click"],["label","OK (F2)",3,"click"]],template:function(a,o){if(a&1){let f=C();n(0,"app-main-panel",9),c(1,Ue,3,3,"ng-template",null,0,d)(3,tt,31,17,"ng-template",null,1,d),i(),n(5,"p-dialog",10),z("visibleChange",function(k){return x(f),Q(o.summaryDialogVisible,k)||(o.summaryDialogVisible=k),g(k)}),c(6,nt,1,2,"ng-template",null,2,d)(8,it,5,1,"ng-template",null,3,d)(10,mt,1,1,"ng-template",null,1,d)(12,st,2,0,"ng-template",null,4,d),i()}if(a&2){let f=$(7);l(5),V(w(8,Re)),m("modal",!0),W("visible",o.summaryDialogVisible),m("breakpoints",w(9,Ve))("draggable",!1)("closeIconTemplate",f)("dismissableMask",!0)}},dependencies:[pe,ee,G,X,Z,Y,re,oe,xe,se,me,he,Ee,ge,ve,Ce,ye,Ie,ie,ne,fe,de,ce,ue,_e,le,ae],styles:[".p-datatable-thead>tr>th{background-color:transparent!important;color:#000!important} .p-stepper .p-steplist{max-width:50vw;margin:0 auto} .p-card{border-radius:4px} .p-card .p-card-header{display:flex;align-items:center;width:100%} .p-card .p-card-header .state-new{width:inherit;padding:.75rem;vertical-align:middle;background:repeating-linear-gradient(-60deg,#beeebb,#beeebb 15px,#afeba8 15px 30px)!important} .p-card .p-card-header .state-updated{width:inherit;padding:.75rem;background:repeating-linear-gradient(-60deg,#fcf3cf,#fcf3cf 15px,#f9e79f 15px 30px)!important} .p-card .p-card-header .state-unchanged{width:inherit;padding:.75rem;border-bottom:1px solid #dee2e6} .p-card .p-card-header .state-error{width:inherit;padding:.75rem;background:repeating-linear-gradient(-60deg,#f8d7da,#f8d7da 15px,#f5c6cb 15px 30px)!important} pos-uppy div div h4{font-size:16px} pos-uppy div div p{font-size:14px!important} pos-uppy div div hr{margin:0}.status-success[_ngcontent-%COMP%]{background:repeating-linear-gradient(-60deg,#beeebb,#beeebb 15px,#afeba8 15px 30px)!important}.state-danger[_ngcontent-%COMP%]{background:repeating-linear-gradient(-60deg,#f8d7da,#f8d7da 15px,#f5c6cb 15px 30px)!important}"],changeDetection:0})}}return t})();export{Ut as JournalEntryImportComponent};
|