@idmwx/idmui-report 5.2.1 → 5.2.2

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.
@@ -48,7 +48,7 @@
48
48
  <div class="vrpt-from">From: ${t.from}</div>
49
49
  <div class="vrpt-to">To: ${t.to}</div>
50
50
  <div class="vrpt-subject">Subject: ${t.subject}</div>
51
- <br/>`;D=D+r+"</div>",a.insertAdjacentHTML("beforeend",D)}})}}},zA={class:"report-email"};function SA(o,t,l,r,i,a){return e.openBlock(),e.createElementBlock("div",zA,t[0]||(t[0]=[e.createStaticVNode('<div class="section email-section" data-v-0dbac70b><div class="header-block flex-center" data-v-0dbac70b><i class="iconfont" data-v-0dbac70b></i><div class="title" data-v-0dbac70b>Emails</div></div><div class="content-box" data-v-0dbac70b><div id="col1" class="col col1" data-v-0dbac70b></div><div id="col2" class="col col2" data-v-0dbac70b></div></div></div>',1)]))}const CA=Ze(xA,[["render",SA],["__scopeId","data-v-0dbac70b"]]),sh="",kA={name:"OrmVoyageIndex",components:{IdmBrand2:Ds.IdmBrand2,VoySummary:pV,Inventory:HV,Chart:TA,Email:CA,Loading:Rn,IdmSign:Ds.IdmSign},props:{report:{type:Object,default:()=>({})},voyageEmails:{type:Array,default:()=>[]}},emits:["commit"],data(){return{inventory:[],loading:!0}},computed:{computeUTCTime(){return function(o,t="MMM-DD/HHmm[Z]"){return`${W(o).utc().format(t)}`}}},watch:{report:{handler(o,t){o!=null&&o.id&&(this.loading=!1,this.$nextTick(()=>{this.prepare()}))},immediate:!0}},methods:{commit(o){this.$emit("commit",o)},prepare(){var t,l;const o=[];(l=(t=this.report)==null?void 0:t.segments)==null||l.forEach(r=>{const i=r.extend.cp;let a,M,s=!1;r.inventory.sample.hours.forEach((N,p)=>{a||(a=N),(!M||s)&&(M=N,s=!1),a.segIndex===N.segIndex?a.segLength=(a.segLength||0)+1:(a=N,a.segLength=1),M.noonLength=(M.noonLength||0)+1;let V=N.type.charAt(0);["N","M","E"].includes(V)&&(s=!0,M.dailyAvgCf=N.dailyAvgCf,M.avgSpdCalc=N.avgSpdCalc,M.distanceCalc=N.distanceCalc,M.noon&&(M.noon.foCons=N.noon.foCons,M.noon.dgoCons=N.noon.dgoCons)),N.abbrev=V,V=V==="M"?"*":V==="A"?"":V,N.time=`${V} ${this.computeUTCTime(N.utc,"MMM-DD/HHmm[Z]")}`,N._lng=re.LngLatHelper.lng2pretty(N.lng),N._lat=re.LngLatHelper.lat2pretty(N.lat),N.cp=i,N.goodWx=N.type==="BOSP"?!1:N.goodWx,o.push(N)})}),o.sort((r,i)=>r.positionTime-i.positionTime),this.inventory=o}}};function fA(o,t,l,r,i,a){var f,A,x,T,I,S,z,k,g,U;const M=e.resolveComponent("IdmBrand2"),s=e.resolveComponent("Loading"),N=e.resolveComponent("VoySummary"),p=e.resolveComponent("Inventory"),V=e.resolveComponent("Chart"),D=e.resolveComponent("IdmSign"),m=e.resolveComponent("Email");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass((A=(f=l.report)==null?void 0:f.weather)!=null&&A.referenceOnly?"report-section watermark":"report-section")},[e.createVNode(M,{name:"Voyage Analysis Report",issued:l.report.createdAt},null,8,["issued"]),e.createVNode(s,{loading:i.loading,onTimeout:t[0]||(t[0]=Q=>i.loading=!1)},null,8,["loading"]),e.createVNode(N,{report:l.report,class:"main",onCommit:a.commit},null,8,["report","onCommit"]),e.createVNode(p,{report:l.report,inventory:i.inventory,class:"main"},null,8,["report","inventory"]),e.createVNode(V,{report:l.report,inventory:i.inventory,class:"main"},null,8,["report","inventory"]),e.createVNode(D,{signed:!!((T=(x=l.report)==null?void 0:x.report)!=null&&T.email),number:(S=(I=l.report)==null?void 0:I.voyage)==null?void 0:S.number,certified:(k=(z=l.report)==null?void 0:z.report)==null?void 0:k.certified,"issued-at":(g=l.report)==null?void 0:g.createdAt},null,8,["signed","number","certified","issued-at"]),((U=l.voyageEmails)==null?void 0:U.length)>0?(e.openBlock(),e.createBlock(m,{key:0,report:l.report,"voyage-emails":l.voyageEmails},null,8,["report","voyage-emails"])):e.createCommentVNode("",!0)],2)}const ys=Ze(kA,[["render",fA],["__scopeId","data-v-5fb85b5a"]]),jA={install(o){o.component("FliVoyageReport",Es),o.component("OrmVoyageReport",ys)}},dh="",rh="",bA={name:"IdmTropical",components:{TropicalReport:Jd.TropicalReport},props:{token:{type:String,default:""},report:{type:Object,default:()=>{}},model:{type:String,default:""},ts:{type:String,default:""}},emits:["center"],data(){return{center:void 0}},computed:{},watch:{},methods:{handleHurricanceCenter(o){this.center=o}}},UA={class:"typhoon-report-container"};function OA(o,t,l,r,i,a){const M=e.resolveComponent("TropicalReport");return e.openBlock(),e.createElementBlock("div",UA,[l.report?(e.openBlock(),e.createBlock(M,{key:0,report:l.report,model:l.model,ts:l.ts,token:l.token,onCenter:a.handleHurricanceCenter},null,8,["report","model","ts","token","onCenter"])):e.createCommentVNode("",!0)])}const Is=Ze(bA,[["render",OA]]),YA={install(o){o.component("TropicalReport",Is)}},ch="",Nh="",QA={name:"OrmInvoice",components:{IdmBrand:to},props:{report:{type:Object,default:()=>({})}},data(){return{account:{},reservations4Route:[],reservations4Point:[],maxColspans:8,totalInUS:0}},computed:{computeTime(){return function(o,t="YYYY, MMM-DD/HHmm[LT]"){return o!=="-"?`${W(o).utcOffset(8).format(t)}`:"-"}}},watch:{report:{handler(){var o,t,l,r,i,a,M,s;this.reservations4Route=(t=(o=this.report)==null?void 0:o.reservations)==null?void 0:t.filter(N=>N.props),this.reservations4Point=(r=(l=this.report)==null?void 0:l.reservations)==null?void 0:r.filter(N=>!N.props),this.account=(i=this.report)==null?void 0:i.account,this.totalInUS=(M=(a=this.report)==null?void 0:a.reservations)==null?void 0:M.reduce((N,p)=>Math.round((N+p.amount)*100)/100,0),(s=this.reservations4Route)!=null&&s.length?this.maxColspans=this.report.showPort?8:6:this.maxColspans=2},immediate:!0}}},hA={class:"invoice-report"},wA={class:"section items-section"},BA={class:"flex-start"},RA=["innerHTML"],FA={class:"flex-space"},PA={class:"invoice-item"},GA={key:0,class:"invoice-item"},WA={key:0},LA={key:1},ZA={key:0},HA={key:1},_A=["colspan"],JA=["colspan"],XA=["colspan"],KA={class:"total"},qA=["colspan"],$A={class:"total"},uA=["colspan"],vA={class:"total"},e2={key:1},t2=["colspan"],l2={class:"total"},o2={key:0,class:"memo-block"},n2=["innerHTML"],a2={class:"section company-section"},i2={class:"company-item"},s2={class:"company-item"},d2={class:"company-item"},r2={class:"company-item"},c2={class:"company-item"},N2={class:"company-item"},D2={class:"company-item"},M2={class:"company-item"},m2={class:"company-item"},g2={class:"company-item"},E2={class:"company-item"},y2={class:"company-item"},I2={class:"company-item"},p2={class:"company-item"},V2={class:"section sign-section"},A2={class:"flex-space"},T2={class:"sign-block"};function x2(o,t,l,r,i,a){var s,N,p,V,D,m,f,A,x,T,I,S,z,k,g,U,Q,h,w,B,R,P,L,Z,H,_,X,O,le,oe,ne,ae,ie,n,J,$,u,v,se,de,K,Me,me,ge,Ee,ye,Ie,pe,Ne,Ae,Te,xe,ze,Se,Ce,ke,fe,je,be,Ue,Oe,Ve,Pe,d,ee,j,De,Ye,Qe,he,b,we,Be,c;const M=e.resolveComponent("IdmBrand");return e.openBlock(),e.createElementBlock("div",hA,[e.createVNode(M,{name:"INVOICE",issued:l.report.createdAt},null,8,["issued"]),e.createElementVNode("div",wA,[e.createElementVNode("div",BA,[t[0]||(t[0]=e.createElementVNode("div",{class:"invoice-item"},"Bill To:",-1)),e.createElementVNode("div",{class:"invoice-item",style:{"font-weight":"500","margin-left":"4px"},innerHTML:(p=(N=(s=l.report)==null?void 0:s.invoiceTitle)==null?void 0:N.name)==null?void 0:p.replace(`
51
+ <br/>`;D=D+r+"</div>",a.insertAdjacentHTML("beforeend",D)}})}}},zA={class:"report-email"};function SA(o,t,l,r,i,a){return e.openBlock(),e.createElementBlock("div",zA,t[0]||(t[0]=[e.createStaticVNode('<div class="section email-section" data-v-0dbac70b><div class="header-block flex-center" data-v-0dbac70b><i class="iconfont" data-v-0dbac70b></i><div class="title" data-v-0dbac70b>Emails</div></div><div class="content-box" data-v-0dbac70b><div id="col1" class="col col1" data-v-0dbac70b></div><div id="col2" class="col col2" data-v-0dbac70b></div></div></div>',1)]))}const CA=Ze(xA,[["render",SA],["__scopeId","data-v-0dbac70b"]]),sh="",kA={name:"OrmVoyageIndex",components:{IdmBrand2:Ds.IdmBrand2,VoySummary:pV,Inventory:HV,Chart:TA,Email:CA,Loading:Rn,IdmSign:Ds.IdmSign},props:{report:{type:Object,default:()=>({})},voyageEmails:{type:Array,default:()=>[]}},emits:["commit"],data(){return{inventory:[],loading:!0}},computed:{computeUTCTime(){return function(o,t="MMM-DD/HHmm[Z]"){return`${W(o).utc().format(t)}`}}},watch:{report:{handler(o,t){o!=null&&o.id&&(this.loading=!1,this.$nextTick(()=>{this.prepare()}))},immediate:!0}},methods:{commit(o){this.$emit("commit",o)},prepare(){var t,l;const o=[];(l=(t=this.report)==null?void 0:t.segments)==null||l.forEach(r=>{const i=r.extend.cp;let a,M,s=!1;r.inventory.sample.hours.forEach((N,p)=>{a||(a=N),(!M||s)&&(M=N,s=!1),a.segIndex===N.segIndex?a.segLength=(a.segLength||0)+1:(a=N,a.segLength=1),M.noonLength=(M.noonLength||0)+1;let V=N.type.charAt(0);["N","M","E"].includes(V)&&(s=!0,M.dailyAvgCf=N.dailyAvgCf,M.avgSpdCalc=N.avgSpdCalc,M.distanceCalc=N.distanceCalc,M.noon&&(M.noon.foCons=N.noon.foCons,M.noon.dgoCons=N.noon.dgoCons)),N.abbrev=V,V=V==="M"?"*":V==="A"?"":V,N.time=`${V} ${this.computeUTCTime(N.utc,"MMM-DD/HHmm[Z]")}`,N._lng=re.LngLatHelper.lng2pretty(N.lng),N._lat=re.LngLatHelper.lat2pretty(N.lat),N.cp=i,N.goodWx=N.type==="BOSP"?!1:N.goodWx,o.push(N)})}),o.sort((r,i)=>r.positionTime-i.positionTime),this.inventory=o}}};function fA(o,t,l,r,i,a){var f,A,x,T,I,S,z,k,g,U;const M=e.resolveComponent("IdmBrand2"),s=e.resolveComponent("Loading"),N=e.resolveComponent("VoySummary"),p=e.resolveComponent("Inventory"),V=e.resolveComponent("Chart"),D=e.resolveComponent("IdmSign"),m=e.resolveComponent("Email");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass((A=(f=l.report)==null?void 0:f.weather)!=null&&A.referenceOnly?"report-section watermark":"report-section")},[e.createVNode(M,{name:"Voyage Analysis Report",issued:l.report.createdAt},null,8,["issued"]),e.createVNode(s,{loading:i.loading,onTimeout:t[0]||(t[0]=Q=>i.loading=!1)},null,8,["loading"]),e.createVNode(N,{report:l.report,class:"main",onCommit:a.commit},null,8,["report","onCommit"]),e.createVNode(p,{report:l.report,inventory:i.inventory,class:"main"},null,8,["report","inventory"]),e.createVNode(V,{report:l.report,inventory:i.inventory,class:"main"},null,8,["report","inventory"]),e.createVNode(D,{signed:(T=(x=l.report)==null?void 0:x.voyage)==null?void 0:T.signed,number:(S=(I=l.report)==null?void 0:I.voyage)==null?void 0:S.number,certified:(k=(z=l.report)==null?void 0:z.report)==null?void 0:k.certified,"issued-at":(g=l.report)==null?void 0:g.createdAt},null,8,["signed","number","certified","issued-at"]),((U=l.voyageEmails)==null?void 0:U.length)>0?(e.openBlock(),e.createBlock(m,{key:0,report:l.report,"voyage-emails":l.voyageEmails},null,8,["report","voyage-emails"])):e.createCommentVNode("",!0)],2)}const ys=Ze(kA,[["render",fA],["__scopeId","data-v-edf4922e"]]),jA={install(o){o.component("FliVoyageReport",Es),o.component("OrmVoyageReport",ys)}},dh="",rh="",bA={name:"IdmTropical",components:{TropicalReport:Jd.TropicalReport},props:{token:{type:String,default:""},report:{type:Object,default:()=>{}},model:{type:String,default:""},ts:{type:String,default:""}},emits:["center"],data(){return{center:void 0}},computed:{},watch:{},methods:{handleHurricanceCenter(o){this.center=o}}},UA={class:"typhoon-report-container"};function OA(o,t,l,r,i,a){const M=e.resolveComponent("TropicalReport");return e.openBlock(),e.createElementBlock("div",UA,[l.report?(e.openBlock(),e.createBlock(M,{key:0,report:l.report,model:l.model,ts:l.ts,token:l.token,onCenter:a.handleHurricanceCenter},null,8,["report","model","ts","token","onCenter"])):e.createCommentVNode("",!0)])}const Is=Ze(bA,[["render",OA]]),YA={install(o){o.component("TropicalReport",Is)}},ch="",Nh="",QA={name:"OrmInvoice",components:{IdmBrand:to},props:{report:{type:Object,default:()=>({})}},data(){return{account:{},reservations4Route:[],reservations4Point:[],maxColspans:8,totalInUS:0}},computed:{computeTime(){return function(o,t="YYYY, MMM-DD/HHmm[LT]"){return o!=="-"?`${W(o).utcOffset(8).format(t)}`:"-"}}},watch:{report:{handler(){var o,t,l,r,i,a,M,s;this.reservations4Route=(t=(o=this.report)==null?void 0:o.reservations)==null?void 0:t.filter(N=>N.props),this.reservations4Point=(r=(l=this.report)==null?void 0:l.reservations)==null?void 0:r.filter(N=>!N.props),this.account=(i=this.report)==null?void 0:i.account,this.totalInUS=(M=(a=this.report)==null?void 0:a.reservations)==null?void 0:M.reduce((N,p)=>Math.round((N+p.amount)*100)/100,0),(s=this.reservations4Route)!=null&&s.length?this.maxColspans=this.report.showPort?8:6:this.maxColspans=2},immediate:!0}}},hA={class:"invoice-report"},wA={class:"section items-section"},BA={class:"flex-start"},RA=["innerHTML"],FA={class:"flex-space"},PA={class:"invoice-item"},GA={key:0,class:"invoice-item"},WA={key:0},LA={key:1},ZA={key:0},HA={key:1},_A=["colspan"],JA=["colspan"],XA=["colspan"],KA={class:"total"},qA=["colspan"],$A={class:"total"},uA=["colspan"],vA={class:"total"},e2={key:1},t2=["colspan"],l2={class:"total"},o2={key:0,class:"memo-block"},n2=["innerHTML"],a2={class:"section company-section"},i2={class:"company-item"},s2={class:"company-item"},d2={class:"company-item"},r2={class:"company-item"},c2={class:"company-item"},N2={class:"company-item"},D2={class:"company-item"},M2={class:"company-item"},m2={class:"company-item"},g2={class:"company-item"},E2={class:"company-item"},y2={class:"company-item"},I2={class:"company-item"},p2={class:"company-item"},V2={class:"section sign-section"},A2={class:"flex-space"},T2={class:"sign-block"};function x2(o,t,l,r,i,a){var s,N,p,V,D,m,f,A,x,T,I,S,z,k,g,U,Q,h,w,B,R,P,L,Z,H,_,X,O,le,oe,ne,ae,ie,n,J,$,u,v,se,de,K,Me,me,ge,Ee,ye,Ie,pe,Ne,Ae,Te,xe,ze,Se,Ce,ke,fe,je,be,Ue,Oe,Ve,Pe,d,ee,j,De,Ye,Qe,he,b,we,Be,c;const M=e.resolveComponent("IdmBrand");return e.openBlock(),e.createElementBlock("div",hA,[e.createVNode(M,{name:"INVOICE",issued:l.report.createdAt},null,8,["issued"]),e.createElementVNode("div",wA,[e.createElementVNode("div",BA,[t[0]||(t[0]=e.createElementVNode("div",{class:"invoice-item"},"Bill To:",-1)),e.createElementVNode("div",{class:"invoice-item",style:{"font-weight":"500","margin-left":"4px"},innerHTML:(p=(N=(s=l.report)==null?void 0:s.invoiceTitle)==null?void 0:N.name)==null?void 0:p.replace(`
52
52
  `,"<br/>")},null,8,RA)]),e.createElementVNode("div",FA,[e.createElementVNode("div",PA,"Invoice No. "+e.toDisplayString(l.report.number),1),(V=l.report)!=null&&V.paymentDate?(e.openBlock(),e.createElementBlock("div",GA,"Paid: "+e.toDisplayString(a.computeTime(l.report.paymentDate)),1)):e.createCommentVNode("",!0)]),e.createElementVNode("table",null,[(D=i.reservations4Route)!=null&&D.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[t[1]||(t[1]=e.createElementVNode("td",null,"NO.",-1)),t[2]||(t[2]=e.createElementVNode("td",null,"VoyNum.",-1)),t[3]||(t[3]=e.createElementVNode("td",null,"Vessel",-1)),t[4]||(t[4]=e.createElementVNode("td",null,"Load Condition",-1)),(m=l.report)!=null&&m.showPort?(e.openBlock(),e.createElementBlock("td",WA,"Departure")):e.createCommentVNode("",!0),t[5]||(t[5]=e.createElementVNode("td",{style:{"min-width":"80px"}},"ATD",-1)),(f=l.report)!=null&&f.showPort?(e.openBlock(),e.createElementBlock("td",LA,"Destination")):e.createCommentVNode("",!0),t[6]||(t[6]=e.createElementVNode("td",{style:{"min-width":"80px"}},"ATA",-1)),t[7]||(t[7]=e.createElementVNode("td",null,"Amounts",-1))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.reservations4Route,(G,ce)=>{var Y,Re,te,Fe,Ge,We,Je,Xe,Ke,qe,$e,ue,et,tt,lt,ot,nt,at,it,st,dt,rt,ct,Nt,Dt;return e.openBlock(),e.createElementBlock("tr",{key:ce},[e.createElementVNode("td",null,e.toDisplayString((te=(Re=(Y=G.props)==null?void 0:Y[0])==null?void 0:Re.voyage)==null?void 0:te.number),1),e.createElementVNode("td",null,e.toDisplayString(((We=(Ge=(Fe=G.props)==null?void 0:Fe[0])==null?void 0:Ge.voyage)==null?void 0:We.voyNum)||"-"),1),e.createElementVNode("td",null,e.toDisplayString((Ke=(Xe=(Je=G.props)==null?void 0:Je[0])==null?void 0:Xe.vessel)==null?void 0:Ke.name),1),e.createElementVNode("td",null,e.toDisplayString((ue=($e=(qe=G.props)==null?void 0:qe[0])==null?void 0:$e.voyage)==null?void 0:ue.loadCondition),1),(et=l.report)!=null&&et.showPort?(e.openBlock(),e.createElementBlock("td",ZA,e.toDisplayString((ot=(lt=(tt=G.props)==null?void 0:tt[0])==null?void 0:lt.departure)==null?void 0:ot.name),1)):e.createCommentVNode("",!0),e.createElementVNode("td",null,e.toDisplayString((it=(at=(nt=G.props)==null?void 0:nt[0])==null?void 0:at.departure)==null?void 0:it.atd),1),l.report.showPort?(e.openBlock(),e.createElementBlock("td",HA,e.toDisplayString((rt=(dt=(st=G.props)==null?void 0:st[0])==null?void 0:dt.destination)==null?void 0:rt.name),1)):e.createCommentVNode("",!0),e.createElementVNode("td",null,e.toDisplayString((Dt=(Nt=(ct=G.props)==null?void 0:ct[0])==null?void 0:Nt.destination)==null?void 0:Dt.ata),1),e.createElementVNode("td",null,"$"+e.toDisplayString(G.amount),1)])}),128))])],64)):e.createCommentVNode("",!0),(A=i.reservations4Point)!=null&&A.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[t[8]||(t[8]=e.createElementVNode("td",null,"NO.",-1)),e.createElementVNode("td",{colspan:i.maxColspans-1},"Items.",8,_A),t[9]||(t[9]=e.createElementVNode("td",null,"Amounts",-1))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.reservations4Point,(G,ce)=>(e.openBlock(),e.createElementBlock("tr",{key:ce},[e.createElementVNode("td",null,e.toDisplayString(G.number),1),e.createElementVNode("td",{colspan:i.maxColspans-1},e.toDisplayString(G.items),9,JA),e.createElementVNode("td",null,"$"+e.toDisplayString(G.amount),1)]))),128))])],64)):e.createCommentVNode("",!0),e.createElementVNode("tbody",null,[((x=l.report)==null?void 0:x.paymentType)==="CNY"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},t[10]||(t[10]=[e.createElementVNode("span",null,"Total in USD",-1)]),8,XA),e.createElementVNode("td",KA,[e.createElementVNode("span",null,e.toDisplayString(`$${i.totalInUS}`),1)])]),e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},t[11]||(t[11]=[e.createElementVNode("span",null,"Exchange Rate",-1)]),8,qA),e.createElementVNode("td",$A,[e.createElementVNode("span",null,e.toDisplayString((T=l.report)==null?void 0:T.rate),1)])]),e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},"Total in CNY",8,uA),e.createElementVNode("td",vA,"¥"+e.toDisplayString((I=l.report)==null?void 0:I.paymentAmount),1)])],64)):(e.openBlock(),e.createElementBlock("tr",e2,[e.createElementVNode("td",{colspan:i.maxColspans},t[12]||(t[12]=[e.createElementVNode("span",null,"Total in USD",-1)]),8,t2),e.createElementVNode("td",l2,[e.createElementVNode("span",null,e.toDisplayString(`$${(S=l.report)==null?void 0:S.paymentAmount}`),1)])]))])]),(z=l.report)!=null&&z.memo?(e.openBlock(),e.createElementBlock("div",o2,[t[13]||(t[13]=e.createElementVNode("div",{class:"invoice-item",style:{"font-weight":"600"}},"MEMO",-1)),e.createElementVNode("div",{class:"invoice-item",innerHTML:(g=(k=l.report)==null?void 0:k.memo)==null?void 0:g.replace(`
53
53
  `,"<br/>")},null,8,n2)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",a2,[t[28]||(t[28]=e.createElementVNode("div",{class:"company-item",style:{"font-weight":"600","font-size":"16px","margin-bottom":"10px"}},"Bank Information",-1)),((U=l.report)==null?void 0:U.paymentType)==="CNY"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",i2,[t[14]||(t[14]=e.createElementVNode("label",null,"Bank",-1)),e.createElementVNode("span",null,e.toDisplayString((B=(w=i.account)==null?void 0:w[(h=(Q=l.report)==null?void 0:Q.paymentType)==null?void 0:h.toLowerCase()])==null?void 0:B.bank),1)]),e.createElementVNode("div",s2,[t[15]||(t[15]=e.createElementVNode("label",null,"Account",-1)),e.createElementVNode("span",null,e.toDisplayString((Z=(L=i.account)==null?void 0:L[(P=(R=l.report)==null?void 0:R.paymentType)==null?void 0:P.toLowerCase()])==null?void 0:Z.number),1)]),e.createElementVNode("div",d2,[t[16]||(t[16]=e.createElementVNode("label",null,"Title",-1)),e.createElementVNode("span",null,e.toDisplayString((O=(X=i.account)==null?void 0:X[(_=(H=l.report)==null?void 0:H.paymentType)==null?void 0:_.toLowerCase()])==null?void 0:O.title),1)]),e.createElementVNode("div",r2,[t[17]||(t[17]=e.createElementVNode("label",null,"Addr",-1)),e.createElementVNode("span",null,e.toDisplayString((ae=(ne=i.account)==null?void 0:ne[(oe=(le=l.report)==null?void 0:le.paymentType)==null?void 0:oe.toLowerCase()])==null?void 0:ae.address),1)]),e.createElementVNode("div",c2,[t[18]||(t[18]=e.createElementVNode("label",null,"Tel",-1)),e.createElementVNode("span",null,e.toDisplayString(($=(J=i.account)==null?void 0:J[(n=(ie=l.report)==null?void 0:ie.paymentType)==null?void 0:n.toLowerCase()])==null?void 0:$.tel),1)]),e.createElementVNode("div",N2,[t[19]||(t[19]=e.createElementVNode("label",null,"Tax ID",-1)),e.createElementVNode("span",null,e.toDisplayString((de=(se=i.account)==null?void 0:se[(v=(u=l.report)==null?void 0:u.paymentType)==null?void 0:v.toLowerCase()])==null?void 0:de.taxId),1)])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",D2,[t[20]||(t[20]=e.createElementVNode("label",null,"Beneficiary's Name",-1)),e.createElementVNode("span",null,e.toDisplayString((ge=(me=i.account)==null?void 0:me[(Me=(K=l.report)==null?void 0:K.paymentType)==null?void 0:Me.toLowerCase()])==null?void 0:ge.title),1)]),e.createElementVNode("div",M2,[t[21]||(t[21]=e.createElementVNode("label",null,"Bank Name",-1)),e.createElementVNode("span",null,e.toDisplayString((pe=(Ie=i.account)==null?void 0:Ie[(ye=(Ee=l.report)==null?void 0:Ee.paymentType)==null?void 0:ye.toLowerCase()])==null?void 0:pe.bank),1)]),e.createElementVNode("div",m2,[t[22]||(t[22]=e.createElementVNode("label",null,"Bank Address",-1)),e.createElementVNode("span",null,e.toDisplayString((xe=(Te=i.account)==null?void 0:Te[(Ae=(Ne=l.report)==null?void 0:Ne.paymentType)==null?void 0:Ae.toLowerCase()])==null?void 0:xe.bankAddr),1)]),e.createElementVNode("div",g2,[t[23]||(t[23]=e.createElementVNode("label",null,"Account No.",-1)),e.createElementVNode("span",null,e.toDisplayString((ke=(Ce=i.account)==null?void 0:Ce[(Se=(ze=l.report)==null?void 0:ze.paymentType)==null?void 0:Se.toLowerCase()])==null?void 0:ke.number),1)]),e.createElementVNode("div",E2,[t[24]||(t[24]=e.createElementVNode("label",null,"SWIFT",-1)),e.createElementVNode("span",null,e.toDisplayString((Ue=(be=i.account)==null?void 0:be[(je=(fe=l.report)==null?void 0:fe.paymentType)==null?void 0:je.toLowerCase()])==null?void 0:Ue.swift),1)]),e.createElementVNode("div",y2,[t[25]||(t[25]=e.createElementVNode("label",null,"Intermediary Bank",-1)),e.createElementVNode("span",null,e.toDisplayString((d=(Pe=i.account)==null?void 0:Pe[(Ve=(Oe=l.report)==null?void 0:Oe.paymentType)==null?void 0:Ve.toLowerCase()])==null?void 0:d.intermediaryBank),1)]),e.createElementVNode("div",I2,[t[26]||(t[26]=e.createElementVNode("label",null,"SWIFT",-1)),e.createElementVNode("span",null,e.toDisplayString((Ye=(De=i.account)==null?void 0:De[(j=(ee=l.report)==null?void 0:ee.paymentType)==null?void 0:j.toLowerCase()])==null?void 0:Ye.intermediaryBankSwift),1)]),e.createElementVNode("div",p2,[t[27]||(t[27]=e.createElementVNode("label",null,"ABA NO.",-1)),e.createElementVNode("span",null,e.toDisplayString((we=(b=i.account)==null?void 0:b[(he=(Qe=l.report)==null?void 0:Qe.paymentType)==null?void 0:he.toLowerCase()])==null?void 0:we.intermediaryBankAbaNo),1)])],64))]),e.createElementVNode("div",V2,[e.createElementVNode("div",A2,[e.createElementVNode("div",T2,[t[29]||(t[29]=e.createElementVNode("div",null,"Finance Team",-1)),t[30]||(t[30]=e.createElementVNode("div",null,"Ocean Right Marine Service Co., Ltd.",-1)),t[31]||(t[31]=e.createElementVNode("div",null,[e.createTextVNode("Email: "),e.createElementVNode("a",{href:"mailto:op@ormwx.com"},"op@ormwx.com")],-1)),t[32]||(t[32]=e.createElementVNode("div",null,[e.createTextVNode("Tel: "),e.createElementVNode("a",{href:"tel:+86 532 68873968"},"+86 532 68873968")],-1)),e.createElementVNode("div",null,"Address: "+e.toDisplayString((c=(Be=i.account)==null?void 0:Be.usd)==null?void 0:c.address),1)]),t[33]||(t[33]=e.createElementVNode("div",{class:"thank-block"},"Thank You",-1)),t[34]||(t[34]=e.createElementVNode("div",{class:"electronic-seal"},[e.createElementVNode("img",{src:"https://osshz.idmwx.com/asset/electronic_seal.png",alt:""})],-1))])])])}const ps=Ze(QA,[["render",x2],["__scopeId","data-v-c4f2cd02"]]),Dh="",z2={name:"FliInvoice",props:{report:{type:Object,default:()=>({})}},data(){return{reservations4Route:[],reservations4Point:[],maxColspans:8,totalInUS:0}},computed:{computeTime(){return function(o,t="YYYY, MMM-DD/HHmm[LT]"){return o!=="-"?`${W(o).utcOffset(8).format(t)}`:"-"}}},watch:{report:{handler(){var o,t,l,r,i,a,M;this.reservations4Route=(t=(o=this.report)==null?void 0:o.reservations)==null?void 0:t.filter(s=>s.props),this.reservations4Point=(r=(l=this.report)==null?void 0:l.reservations)==null?void 0:r.filter(s=>!s.props),this.totalInUS=(a=(i=this.report)==null?void 0:i.reservations)==null?void 0:a.reduce((s,N)=>Math.round((s+N.amount)*100)/100,0),(M=this.reservations4Route)!=null&&M.length?this.maxColspans=8:this.maxColspans=2},immediate:!0}},mounted(){}},S2={class:"invoice-report"},C2={class:"section items-section"},k2={class:"flex-start"},f2=["innerHTML"],j2={class:"flex-space"},b2={class:"invoice-item"},U2={key:0,class:"invoice-item"},O2=["colspan"],Y2=["colspan"],Q2=["colspan"],h2={class:"total"},w2=["colspan"],B2={class:"total"},R2=["colspan"],F2={class:"total"},P2={key:1},G2=["colspan"],W2={class:"total"},L2={key:0,class:"memo-block"},Z2=["innerHTML"];function H2(o,t,l,r,i,a){var M,s,N,p,V,D,m,f,A,x,T,I,S;return e.openBlock(),e.createElementBlock("div",S2,[e.createElementVNode("div",C2,[e.createElementVNode("div",k2,[t[0]||(t[0]=e.createElementVNode("div",{class:"invoice-item"},"Bill To:",-1)),e.createElementVNode("div",{class:"invoice-item",style:{"font-weight":"500","margin-left":"4px"},innerHTML:(N=(s=(M=l.report)==null?void 0:M.invoiceTitle)==null?void 0:s.name)==null?void 0:N.replace(`
54
54
  `,"<br/>")},null,8,f2)]),e.createElementVNode("div",j2,[e.createElementVNode("div",b2,"Invoice No. "+e.toDisplayString(l.report.number),1),(p=l.report)!=null&&p.paymentDate?(e.openBlock(),e.createElementBlock("div",U2,"Paid: "+e.toDisplayString(a.computeTime(l.report.paymentDate)),1)):e.createCommentVNode("",!0)]),e.createElementVNode("table",null,[(V=i.reservations4Route)!=null&&V.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t[1]||(t[1]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("td",null,"NO."),e.createElementVNode("td",null,"VoyNum."),e.createElementVNode("td",null,"Vessel"),e.createElementVNode("td",null,"Load Condition"),e.createElementVNode("td",null,"Departure"),e.createElementVNode("td",null,"ATD"),e.createElementVNode("td",null,"Destination"),e.createElementVNode("td",null,"ATA"),e.createElementVNode("td",null,"Amounts")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.reservations4Route,(z,k)=>{var g,U,Q,h,w,B,R,P,L,Z,H,_,X,O,le,oe,ne,ae,ie,n,J,$,u,v;return e.openBlock(),e.createElementBlock("tr",{key:k},[e.createElementVNode("td",null,e.toDisplayString((Q=(U=(g=z.props)==null?void 0:g[0])==null?void 0:U.voyage)==null?void 0:Q.number),1),e.createElementVNode("td",null,e.toDisplayString(((B=(w=(h=z.props)==null?void 0:h[0])==null?void 0:w.voyage)==null?void 0:B.voyNum)||"-"),1),e.createElementVNode("td",null,e.toDisplayString((L=(P=(R=z.props)==null?void 0:R[0])==null?void 0:P.vessel)==null?void 0:L.name),1),e.createElementVNode("td",null,e.toDisplayString((_=(H=(Z=z.props)==null?void 0:Z[0])==null?void 0:H.voyage)==null?void 0:_.loadCondition),1),e.createElementVNode("td",null,e.toDisplayString((le=(O=(X=z.props)==null?void 0:X[0])==null?void 0:O.departure)==null?void 0:le.name),1),e.createElementVNode("td",null,e.toDisplayString((ae=(ne=(oe=z.props)==null?void 0:oe[0])==null?void 0:ne.departure)==null?void 0:ae.atd),1),e.createElementVNode("td",null,e.toDisplayString((J=(n=(ie=z.props)==null?void 0:ie[0])==null?void 0:n.destination)==null?void 0:J.name),1),e.createElementVNode("td",null,e.toDisplayString((v=(u=($=z.props)==null?void 0:$[0])==null?void 0:u.destination)==null?void 0:v.ata),1),e.createElementVNode("td",null,"$"+e.toDisplayString(z.amount),1)])}),128))])],64)):e.createCommentVNode("",!0),(D=i.reservations4Point)!=null&&D.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[t[2]||(t[2]=e.createElementVNode("td",null,"NO.",-1)),e.createElementVNode("td",{colspan:i.maxColspans-1},"Items.",8,O2),t[3]||(t[3]=e.createElementVNode("td",null,"Amounts",-1))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.reservations4Point,(z,k)=>(e.openBlock(),e.createElementBlock("tr",{key:k},[e.createElementVNode("td",null,e.toDisplayString(z.number),1),e.createElementVNode("td",{colspan:i.maxColspans-1},e.toDisplayString(z.items),9,Y2),e.createElementVNode("td",null,"$"+e.toDisplayString(z.amount),1)]))),128))])],64)):e.createCommentVNode("",!0),e.createElementVNode("tfoot",null,[((m=l.report)==null?void 0:m.paymentType)==="CNY"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},t[4]||(t[4]=[e.createElementVNode("span",null,"Total in USD",-1)]),8,Q2),e.createElementVNode("td",h2,[e.createElementVNode("span",null,e.toDisplayString(`$${i.totalInUS}`),1)])]),e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},t[5]||(t[5]=[e.createElementVNode("span",null,"Exchange Rate",-1)]),8,w2),e.createElementVNode("td",B2,[e.createElementVNode("span",null,e.toDisplayString((f=l.report)==null?void 0:f.rate),1)])]),e.createElementVNode("tr",null,[e.createElementVNode("td",{colspan:i.maxColspans},"Total in CNY",8,R2),e.createElementVNode("td",F2,"¥"+e.toDisplayString((A=l.report)==null?void 0:A.paymentAmount),1)])],64)):(e.openBlock(),e.createElementBlock("tr",P2,[e.createElementVNode("td",{colspan:i.maxColspans},t[6]||(t[6]=[e.createElementVNode("span",null,"Total in USD",-1)]),8,G2),e.createElementVNode("td",W2,[e.createElementVNode("span",null,e.toDisplayString(`$${(x=l.report)==null?void 0:x.paymentAmount}`),1)])]))])]),(T=l.report)!=null&&T.memo?(e.openBlock(),e.createElementBlock("div",L2,[t[7]||(t[7]=e.createElementVNode("div",{class:"invoice-item",style:{"font-weight":"600"}},"MEMO",-1)),e.createElementVNode("div",{class:"invoice-item",innerHTML:(S=(I=l.report)==null?void 0:I.memo)==null?void 0:S.replace(`