1"use strict";(self.webpackChunkapp=self.webpackChunkapp||[]).push([[3524],{23524(M,d,o){o.d(d,{ShowInvoiceItemPage:()=>g});var p=o(86330),_=o(22281),i=o(10036),h=o(26185),E=o(36069),m=o(591),f=o(2313),D=o(33026),I=o(72730),e=o(22618);const R=()=>["edit"];function P(a,O){1&a&&(e.j41(0,"ion-fab",5)(1,"ion-fab-button",10),e.nrm(2,"ion-icon",11),e.k0s()()),2&a&&(e.R7$(),e.Y8G("routerLink",e.lJ4(1,R)))}let g=(()=>{class a extends h.X{constructor(){super(),this.invoice=(0,_.vPA)(null),this.invoiceItem=(0,_.vPA)(null),(0,E.d)({arrowBack:m.$$C,pencilOutline:m.SNL})}arrCallReloadDynamicDataOnChanges(){return[this.repoSvc.liveInvoiceRepo.change$,this.repoSvc.liveInvoiceItemRepo.change$]}doReloadDynamicData(u,l,t){var n=this;return(0,p.A)(function*(){const c=l.get("invoiceId"),r=l.get("invoiceItemId");if(!c||!r)return void console.error("Can not edit invoice item without invoice ID and invoice item ID in params.");const s=yield n.repoSvc.liveInvoiceRepo.getAsync(c);if(!s)return void console.error("Invoice not found for invoice item show",{invoiceId:c});s.fIsEditable()||console.error("Invoice item show loaded for non-editable invoice",{invoiceId:c,nStatus:s.nStatus}),n.invoice.set(s);const v=yield n.repoSvc.liveInvoiceItemRepo.getAsync(r);v&&(yield I.rIH.loadRelations([v],n.repoSvc),yield I.rIH.loadHvacrRelations([v],n.repoSvc.liveHvacrSystemRepo,n.repoSvc.liveHvacrEquipmentRepo)),n.invoiceItem.set(v),(!n.invoice()||!n.invoiceItem())&&console.error("Invoice or invoice item could not be found in the repository.")})()}static{this.\u0275fac=function(l){return new(l||a)}}static{this.\u0275cmp=e.VBU({type:a,selectors:[["app-show-invoice-item-page"]],features:[e.Vt3],decls:17,vars:7,consts:[[3,"translucent"],["slot","start"],[3,"defaultHref"],["slot","icon-only","name","arrow-back"],[3,"fullscreen"],["slot","fixed","vertical","bottom","horizontal","end"],["collapse","condense"],["size","large"],[1,"mb7"],[3,"invoiceItem"],["color","primary",3,"routerLink"],["name","pencil-outline"]],template:function(l,t){if(1&l&&(e.j41(0,"ion-header",0)(1,"ion-toolbar")(2,"ion-buttons",1)(3,"ion-back-button",2),e.nrm(4,"ion-icon",3),e.k0s()(),e.j41(5,"ion-title"),e.EFF(6),e.k0s()()(),e.j41(7,"ion-content",4),e.nVh(8,P,3,2,"ion-fab",5),e.j41(9,"ion-header",6)(10,"ion-toolbar"),e.nrm(11,"ion-buttons",1),e.j41(12,"ion-title",7),e.EFF(13),e.k0s()()(),e.j41(14,"ion-card",8)(15,"ion-card-content"),e.nrm(16,"app-show-invoice-item",9),e.k0s()()()),2&l){let n,c,r,s;e.Y8G("translucent",!0),e.R7$(3),e.Y8G("defaultHref","/t/"+(null==(n=t.invoice())?null:n.tenantId)+"/d/"+(null==(n=t.invoice())?null:n.divisionId)+"/invoices/"+(null==(n=t.invoice())?null:n.id)),e.R7$(3),e.JRh(null==(c=t.invoiceItem())?null:c.sItemNumberDashName()),e.R7$(),e.Y8G("fullscreen",!0),e.R7$(),e.vxM(t.appStateSvc.fHasPerm(t.AppPermission.INVOICE_E)&&null!=(r=t.invoice())&&r.fIsEditable()?8:-1),e.R7$(5),e.JRh(null==(s=t.invoiceItem())?null:s.sItemNumberDashName()),e.R7$(3),e.Y8G("invoiceItem",t.invoiceItem())}},dependencies:[i.IonHeader,i.IonToolbar,i.IonButtons,i.IonBackButton,i.IonIcon,i.IonTitle,i.IonContent,f.h,i.IonCardContent,i.IonCard,D.Wk,i.IonFab,i.IonFabButton],encapsulation:2})}}return a})()}}]);
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.