PageSourceSearch

https://www.cjisonline.com/chunk-JKEO2AWO.js

js cjisonline.com collected 2026-10-04 08:21:18 UTC 45,933 bytes, 94 lines download raw bytes

1import{a as Qt,b as Jt,d as Si}from"./chunk-2KOZ26EZ.js";import{a as Ht,b as bi}from"./chunk-SXCGASDC.js";import{T as qt,U as gi,V as zt,W as hi,e as ft,f as di,kc as Bt,lc as vi,mc as Gt,nc as $t,oc as Wt}from"./chunk-B4XB2QA3.js";import{a as St,b as Ct,c as xt}from"./chunk-CY6C6FAX.js";import{q as Me,r as _i}from"./chunk-T6U4K77C.js";import{c as J,d as Xt}from"./chunk-KONLULWK.js";import{c as we,d as Ut}from"./chunk-LBGW2BW5.js";import{a as jt,b as fi}from"./chunk-DKSWNRHR.js";import{A as Tt,B as Ot,C as Nt,D as Ft,E as Pt,F as Vt,a as yt,b as Dt,c as wt,f as xe,g as ye,h as De,l as At,m as ui}from"./chunk-4DF2OAU7.js";import{G as be,H as ve,I as Se,o as N,q as dt}from"./chunk-6BN364I6.js";import{Pa as pi,i as _t,j as ci,n as bt,o as vt,oa as Rt,p as fe,q as _e,z as Lt}from"./chunk-JRFTMGTN.js";import{A as Et,C as kt,H as mi,m as Mt}from"./chunk-27UOFEJY.js";import{B as me,F as gt,G as ue,H as ht,I as pe,J as ge,K as he,a as st,c as si,k as se,l as U,n as le,o as de,q as mt,s as R,t as ut,u as pt,y as ce}from"./chunk-K5RLKVU4.js";import{F as lt,L as li,Pa as ct,Ta as z,Xa as re,_a as Q,jc as Ce,nc as It,t as ae,w as at}from"./chunk-G36HCZ2W.js";import{Aa as b,Ac as m,Bc as G,Cc as M,Dc as Ae,Ec as nt,F as Ge,Fd as A,Gc as ie,Hc as ne,Ic as oe,Nd as rt,O as q,Ob as L,Pc as Te,Qb as g,Qc as I,Rd as ri,Sb as h,Vb as ee,Wb as te,Xb as u,Yb as l,Zb as r,_b as p,ba as $e,cb as Xe,cd as $,db as s,fc as D,gd as Oe,ha as B,hd as C,ia as We,id as W,jc as v,lc as c,ma as S,n as Be,od as X,pc as Je,pd as E,qc as Ze,qd as ot,ra as f,rc as Ye,s as H,sa as _,sb as K,tb as Qe,tc as Ke,uc as et,ud as Ne,vc as tt,xc as it,yb as V,yc as O}from"./chunk-DCYYLYWQ.js";import{a as F,b as He,d as P}from"./chunk-NB54P2KK.js";var Fe,Pe,Ve,k,Ee=P(()=>{Fe=(function(e){return e.SecurityAddendumCertification="FBIADDENDUM",e.TexasSecurityAddendumCertification="TX_ADDENDUM",e.CaliforniaSecurityAddendumCertification="CA_ADDENDUM",e.DriversLicense="DRIVERS_LICENSE",e.StateID="STATE_ID",e.Passport="PASSPORT",e.UserAgreement="USER_AGREEMENT",e.AgencyForm="AGENCY_FORM",e.Certification="CERTIFICATION",e.BackgroundDocument="BACKGROUND_DOC",e.ClearanceDocument="CLEARANCE_DOC",e.SupportingDocumentation="SUPPORTING_DOC",e.OtherGeneralDocument="OTHER",e})(Fe||{}),Pe=(function(e){return e.LocalAgency="LocalAgency",e.StateFederal="StateFederal",e.NoOrganization="NoOrganization",e})(Pe||{}),Ve=(function(e){return e.All="All",e.LocalAgency="LocalAgency",e.StateFederal="StateFederal",e.NoOrganization="NoOrganization",e})(Ve||{}),k=(function(e){return e.Success="Success",e.NotFound="NotFound",e.Unauthorized="Unauthorized",e.CannotOverwrite="CannotOverwrite",e.UnknownError="UnknownError",e.ImageTooLarge="ImageTooLarge",e.OrgAssociationRequired="OrgAssociationRequired",e.DescriptionRequired="DescriptionRequired",e})(k||{})});var Zt,Yt=P(()=>{Zt=`
2    .p-textarea {
3        font-family: inherit;
4        font-feature-settings: inherit;
5        font-size: 1rem;
6        color: dt('textarea.color');
7        background: dt('textarea.background');
8        padding-block: dt('textarea.padding.y');
9        padding-inline: dt('textarea.padding.x');
10        border: 1px solid dt('textarea.border.color');
11        transition:
12            background dt('textarea.transition.duration'),
13            color dt('textarea.transition.duration'),
14            border-color dt('textarea.transition.duration'),
15            outline-color dt('textarea.transition.duration'),
16            box-shadow dt('textarea.transition.duration');
17        appearance: none;
18        border-radius: dt('textarea.border.radius');
19        outline-color: transparent;
20        box-shadow: dt('textarea.shadow');
21    }
22
23    .p-textarea:enabled:hover {
24        border-color: dt('textarea.hover.border.color');
25    }
26
27    .p-textarea:enabled:focus {
28        border-color: dt('textarea.focus.border.color');
29        box-shadow: dt('textarea.focus.ring.shadow');
30        outline: dt('textarea.focus.ring.width') dt('textarea.focus.ring.style') dt('textarea.focus.ring.color');
31        outline-offset: dt('textarea.focus.ring.offset');
32    }
33
34    .p-textarea.p-invalid {
35        border-color: dt('textarea.invalid.border.color');
36    }
37
38    .p-textarea.p-variant-filled {
39        background: dt('textarea.filled.background');
40    }
41
42    .p-textarea.p-variant-filled:enabled:hover {
43        background: dt('textarea.filled.hover.background');
44    }
45
46    .p-textarea.p-variant-filled:enabled:focus {
47        background: dt('textarea.filled.focus.background');
48    }
49
50    .p-textarea:disabled {
51        opacity: 1;
52        background: dt('textarea.disabled.background');
53        color: dt('textarea.disabled.color');
54    }
55
56    .p-textarea::placeholder {
57        color: dt('textarea.placeholder.color');
58    }
59
60    .p-textarea.p-invalid::placeholder {
61        color: dt('textarea.invalid.placeholder.color');
62    }
63
64    .p-textarea-fluid {
65        width: 100%;
66    }
67
68    .p-textarea-resizable {
69        overflow: hidden;
70        resize: none;
71    }
72
73    .p-textarea-sm {
74        font-size: dt('textarea.sm.font.size');
75        padding-block: dt('textarea.sm.padding.y');
76        padding-inline: dt('textarea.sm.padding.x');
77    }
78
79    .p-textarea-lg {
80        font-size: dt('textarea.lg.font.size');
81        padding-block: dt('textarea.lg.padding.y');
82        padding-inline: dt('textarea.lg.padding.x');
83    }
84`});var Nn,Kt,ei=P(()=>{A();Yt();Nn=`
85    ${Zt}
86
87    /* For PrimeNG */
88    .p-textarea.ng-invalid.ng-dirty {
89        border-color: dt('textarea.invalid.border.color');
90    }
91    .p-textarea.ng-invalid.ng-dirty::placeholder {
92        color: dt('textarea.invalid.placeholder.color');
93    }
94`,Kt=(()=>{class e{static \u0275fac=function(t){return new(t||e)};static \u0275mod=Qe({type:e});static \u0275inj=We({})}return e})()});var Ie,Le=P(()=>{ri();A();si();A();Ie=(()=>{let a=class a{constructor(){this.http=S(rt),this.apiUrl=S(st)}listDocuments(t){return this.http.post(`${this.apiUrl}${t.userID}/enhanced-documents`,t,{responseType:"json"})}updateDocumentDetails(t,i){return this.http.patch(`${this.apiUrl}${i.userID}/enhanced-document/${t}`,i)}uploadEnhancedDocument(t,i){let n=this.gatherDocumentFormData(i);return n.append("fileData",i.file),this.http.post(`${this.apiUrl}${t}
94/enhanced-document`,n)}uploadUserDocument(t,i){let n=this.gatherDocumentFormData(i);return n.append("fileData",i.file),this.http.post(`${this.apiUrl}${t}/user-document`,n)}gatherDocumentFormData(t){let i=new FormData;return i.append("orgAssociation",t.orgAssociation),i.append("documentTypeID",t.documentTypeID.toString()),i.append("description",t.description),t.customer&&i.append("custID",t.customer),t.orgID&&i.append("orgID",t.orgID.toString()),i}};a.\u0275fac=function(i){return new(i||a)},a.\u0275prov=B({token:a,factory:a.\u0275fac,providedIn:"root"});let e=a;return e})()});var ti,ii=P(()=>{A();Q();Ee();A();ti=(()=>{let a=class a{constructor(){this.messageService=S(z),this.toastMap={[k.Success]:{severity:"success",summary:"Success",detail:"Operation completed successfully.",life:3500},[k.NotFound]:{severity:"error",summary:"Not Found",detail:"Document was not found or is associated with an e-signature. Please refresh the page to load the latest information, or contact support if the problem persists.",life:1e4},[k.Unauthorized]:{severity:"error",summary:"Unauthorized",detail:"You do not have necessary permissions to perform this action.",life:1e4},[k.CannotOverwrite]:{severity:"error",summary:"Cannot Overwrite",detail:"An existing CJIS Security Addendum Certification that is not associated to an organization already exists for this user. A new document must be uploaded to overwrite it.",life:1e4},[k.UnknownError]:{severity:"error",summary:"Error",detail:"An unknown error occurred. Please refresh the page and try again.",life:1e4},[k.ImageTooLarge]:{severity:"error",summary:"Image Too Large",detail:"Image dimensions exceeded the 6000\xD76000 limit. Please upload a smaller image.",life:1e4},[k.OrgAssociationRequired]:{severity:"error",summary:"Organization Required",detail:"This document type must be associated with a Local Agency or a State / Federal Organization.",life:1e4},[k.DescriptionRequired]:{severity:"error",summary:"Description Required",detail:"A description is required for the selected document type.",life:1e4}}}showResult(t,i,n=!0){let d=Object.values(k).includes(t)?t:null,x=F({},this.toastMap[d]);i&&(n?!d:!0)&&Object.assign(x,i),this.messageService.add(x)}};a.\u0275fac=function(i){return new(i||a)},a.\u0275prov=B({token:a,factory:a.\u0275fac,providedIn:"root"});let e=a;return e})()});function ki(e,a){if(e&1&&(l(0,"h5",27),m(1),r()),e&2){let o=c();s(),M("",o.documentID()?"Update":"Upload"," Document")}}function Ii(e,a){if(e&1&&(l(0,"div",36)(1,"p",37),p(2,"i",38),m(3),r()()),e&2){let o=c(3);s(3),M("",o.selectedFile().name," ")}}function Ai(e,a){if(e&1){let o=D();l(0,"div",31),p(1,"i",32),l(2,"p",33)(3,"button",34),v("click",function(){f(o),c();let i=tt(5);return _(i.choose())}),m(4," Choose a file "),r(),m(5," or drag it here. "),r(),l(6,"p",35),m(7," PDF, JPG, or PNG \u2014 Max 10 MB "),r(),g(8,Ii,4,1,"div",36),r()}if(e&2){let o=c(2);s(8),h(o.selectedFile()?8:-1)}}function Ti(e,a){}function Oi(e,a){}function Ni(e,a){}function Fi(e,a){if(e&1&&(l(0,"small",30),m(1),r()),e&2){let o=c(2);s(),M(" ",o.errors().file," ")}}function Pi(e,a){if(e&1){let o=D();l(0,"div")(1,"label",28),m(2," Upload File "),r(),p(3,"cjo-required",11),l(4,"p-fileupload",29,1),v("onSelect",function(i){f(o);let n=c();return _(n.onFileSelect(i))}),V(6,Ai,9,1,"ng-template",null,2,$)(8,Ti,0,0,"ng-template",null,3,$)(10,Oi,0,0,"ng-template",null,4,$)(12,Ni,0,0,"ng-template",null,5,$),r(),g(14,Fi,2,1,"small",30),r()}if(e&2){let o=c();s(4),u("maxFileSize",10485760)("multiple",!1)("customUpload",!0),s(10),h(o.errors().file?14:-1)}}function Vi(e,a){e&1&&(l(0,"div",24),p(1,"p-checkbox",39),l(2,"label",40),m(3," Create another document after uploading "),r(),p(4,"i",41),r()),e&2&&(s(),u("binary",!0),s(3),u("escape",!1))}function Li(e,a){if(e&1&&p(0,"fa-icon",45),e&2){let o=c(2);u("icon",o.faSpinner)}}function Ri(e,a){if(e&1&&p(0,"fa-icon",43),e&2){let o=c(2);u("icon",o.faSave)}}function qi(e,a){if(e&1){let o=D();l(0,"button",42),v("click",function(){f(o);let i=c();return _(i.close())}),p(1,"fa-icon",43),m(2," Cancel "),r(),l(3,"button",44),v("click",function(){f(o);let i=c();return _(i.save())}),g(4,Li,1,1,"fa-icon",45)(5,Ri,1,1,"fa-icon",43),m(6),r()}if(e&2){let o=c();u("disabled",o.isLoading()||o.isSaving()),s(),u("icon",o.faTimes),s(2),u("disabled",o.isLoading()||o.isSaving()||!o.isFormValid()||!o.selectedFile()||o.errors().file),s(),h(o.isSaving()?4:5),s(2),M(" ",o.mode()==="ADD"?"Upload":"Update"," ")}}var Mi,Re,Ei,ni,oi=P(()=>{at();A();he();It();mi();
94dt();li();_i();hi();gi();Xt();fi();Ut();Q();ci();_e();De();xt();Se();Wt();ui();Nt();ei();di();wt();$e();Ee();Le();ii();A();he();_e();Q();Se();Nt();De();wt();Wt();xt();Mi=()=>({width:"600px",maxHeight:"90vh"}),Re=()=>({width:"100%"}),Ei=()=>({width:"700px"});ni=(()=>{let a=class a{constructor(){this.agencySelect=ot(Me),this.messageService=S(z),this.messageHelperService=S(we),this.confirmationService=S(ct),this.enhancedDocumentListService=S(Ie),this.route=S(lt),this.resultService=S(ti),this.docService=S(J),this.lookupListService=S(jt),this.showDialog=Ne(!1),this.documentID=Ne(0),this.userID=E(0),this.documentInsert=X(),this.faTimes=Et,this.faSpinner=kt,this.faSave=Mt,this.mode=C(()=>this.documentID()?"EDIT":"ADD"),this.DocumentOrganizationAssociationType=Pe,this.form=new mt({orgAssociation:new R(null,U.required),customer:new R(null),agency:new R(null),documentType:new R(null),description:new R("",U.required),createAnother:new R(!1)}),this.ctlOrgAssociation=this.form.get("orgAssociation"),this.ctlCustomer=this.form.get("customer"),this.ctlAgency=this.form.get("agency"),this.ctlDocumentType=this.form.get("documentType"),this.ctlDescription=this.form.get("description"),this.ctlCreateAnother=this.form.get("createAnother"),this.selectedFile=b(null),this.selectedAgency=b(null),this.selectedAgencyCustID=C(()=>this.selectedAgency()?.customerCode),this.isCustomerVisible=b(!1),this.isAgencyVisible=b(!1),this.isCreateAnotherVisible=C(()=>this.mode()==="ADD"),this.isSubmitted=b(!1),this.ctlOrgAssociationValueChange=N(this.ctlOrgAssociation.valueChanges),this.onOrgAssociationValueChange=W(()=>{!this.ctlOrgAssociationValueChange()||this.ctlOrgAssociationValueChange()==="NO_ORG"?(this.hideControl("customer"),this.hideControl("agency")):this.ctlOrgAssociationValueChange()==="LOCAL"?(this.hideControl("customer"),this.presentControl("agency")):this.ctlOrgAssociationValueChange()==="STATE/FEDERAL"&&(this.hideControl("agency"),this.presentControl("customer"))}),this.paramUserID=N(this.route.paramMap.pipe(H(t=>+t.get("userID"))),{initialValue:0}),this.resolvedUserID=C(()=>this.userID()||this.paramUserID()||0),this.organizationAssociationOptions=[{label:"Local Agency",value:"LOCAL"},{label:"State / Federal Organization",value:"STATE/FEDERAL"},{label:"No Organization",value:"NO_ORG"}],this.customerOptions=N(this.lookupListService.getCustomerStates().pipe(H(t=>t.map(i=>({label:i.description,value:i.code}))),Ge(t=>(this.messageService.add(this.messageHelperService.errorMessage(t,"loading state data")),Be([]))))),this.documentTypeOptions=N(this.docService.getDocumentTypes().pipe(H(t=>t.value?.sort((i,n)=>i.shortLabel.localeCompare(n.shortLabel,void 0,{sensitivity:"base"}))))),this.isLoadingDocumentTypes=C(()=>!this.documentTypeOptions()),this.isLoadingCustomerOptions=C(()=>!this.customerOptions()),this.isLoading=C(()=>this.isLoadingDocumentTypes()||this.isLoadingCustomerOptions()),this.isSaving=b(!1),this.isFormValid=N(this.form.statusChanges.pipe(H(t=>t==="VALID")),{initialValue:this.form.valid}),this.errors=b({}),this.ALLOWED_FILE_TYPES=["application/pdf","image/jpeg","image/png"],this.MAX_FILE_SIZE=10*1024*1024}presentControl(t){t==="customer"?(this.isCustomerVisible.set(!0),this.selectedAgency.set(null)):t==="agency"&&this.isAgencyVisible.set(!0),this.form.get(t).addValidators(U.required),this.form.get(t).updateValueAndValidity()}hideControl(t){t==="customer"?this.isCustomerVisible.set(!1):t==="agency"&&this.isAgencyVisible.set(!1),this.form.get(t).clearValidators(),this.form.get(t).reset(null),this.form.get(t).updateValueAndValidity()}onFileSelect(t){let i=t.files[0];i&&this.validateAndSetFile(i)}validateAndSetFile(t){if(!this.ALLOWED_FILE_TYPES.includes(t.type)){this.errors.set({file:"Unsupported file type. Please upload a PDF, JPEG, or PNG file."}),this.selectedFile.set(null);return}if(t.size>this.MAX_FILE_SIZE){this.errors.set({file:"File size exceeds 10 MB. Please choose a smaller file."}),this.selectedFile.set(null);return}this.selectedFile.set(t),this.errors.set({file:void 0})}resetDialog(){this.form.reset(),this.selectedFile.set(null),this.errors.set({}),this.documentID.set(0),this.isSubmitted.set(!1)}save(){if(this.isSubmitted.set(!0),this.mode()==="ADD"&&!this.selectedFile()){this.errors.set({file:"A file must be selected before uploading."});return}if(!this.isFormValid())return;this.isSaving.set(!0);let t={orgAssociation:this.ctlOrgAssociation.value,customer:this.ctlCustomer.value??this.selectedAgencyCustID(),orgID:this.ctlAgency.value,orgType:null,documentTypeID:this.ctlDocumentType.value,description:this.ctlDescription.value},i;if(this.mode()==="ADD"){let y=He(F({},t),{file:this.selectedFile()});i=this.enhancedDocumentListService.uploadEnhancedDocument(this.resolvedUserID(),y)}i=i.pipe(q(()=>this.isSaving.set(!1)));let n={next:y=>{if(y.resultCode===k.Success){let T=`Document ${this.mode()==="ADD"?"uploaded":"updated"} successfully.`,j=3500;this.mode()==="ADD"&&this.ctlCreateAnother.value===!0?(T+=" You can now upload another document",j=1e4,this.ctlDocumentType.reset(null),this.ctlDescription.reset(""),this.selectedFile.set(null),this.isSubmitted.set(!1)):this.close(),this.documentInsert.emit(y.value),this.messageService.add(this.messageHelperService.successMessage(T,"Success",j)),this.errors.set({})}else this.messageService.add(this.messageHelperService.serviceResultErrorMessage(y.resultCode,`${this.mode()==="ADD"?"uploading":"updating"} the document`));this.isSaving.set(!1)},error:y=>{let T=y.error;this.resultService.showResult(T?.resultCode,{severity:"error",summary:"Error",detail:"There was an error retrieving the document list. Please refresh and try again.",life:1e4},!0),this.isSaving.set(!1)}},d=null,x=this.documentTypeOptions().find(y=>y.shortLabel===Fe.SecurityAddendumCertification)?.documentTypeID;t.documentTypeID===x&&(!t.orgAssociation||t.orgAssociation==="NO_ORG")&&!t.customer&&!t.orgID&&this.selectedFile()!=null&&(d=this.docService.doesUserHaveUnassociatedSecurityAddendumDocument(this.resolvedUserID())),d!=null?d.subscribe({next:y=>{y.resultCode==="100"?y.value===!0?this.confirmationService.confirm({message:"A CJIS Security Addendum Certification that is not associated to an organization already exists for this user. Uploading another one will over
94write the original document. Do you wish to proceed?",header:"Overwrite Original CJIS Security Addendum Certification?",icon:"pi pi-exclamation-triangle",key:"securityAddendumOverwriteConfirmation",rejectButtonStyleClass:"p-button-text",acceptIcon:"pi pi-check",rejectIcon:"pi pi-times",accept:()=>{i.subscribe(n)},reject:()=>{this.isSaving.set(!1)}}):i.subscribe(n):this.messageService.add(this.messageHelperService.errorMessage(null,"checking for an existing CJIS Security Addendum Certification"))},error:y=>{this.messageService.add(this.messageHelperService.errorMessage(y,"checking for an existing CJIS Security Addendum Certification"))}}):i.subscribe(n)}close(){this.showDialog.set(!1),this.resetDialog()}onAgencySelectChange(t){this.selectedAgency.set(t)}};a.\u0275fac=function(i){return new(i||a)},a.\u0275cmp=K({type:a,selectors:[["cjo-add-edit-enhanced-document"]],viewQuery:function(i,n){i&1&&Ke(n.agencySelect,Me,5),i&2&&et()},inputs:{showDialog:[1,"showDialog"],documentID:[1,"documentID"],userID:[1,"userID"]},outputs:{showDialog:"showDialogChange",documentID:"documentIDChange",documentInsert:"documentInsert"},decls:41,vars:70,consts:[["agencySelect",""],["fu",""],["content",""],["header",""],["file",""],["empty",""],[3,"visibleChange","onHide","visible","modal","closable","draggable","resizable","closeOnEscape","focusOnShow"],["pTemplate","header"],[1,"d-flex","flex-column","gap-4",3,"formGroup"],[1,"pb-3","border-bottom"],["for","orgAssociationSelect",1,"fw-medium"],[1,"ps-1"],["formControlName","orgAssociation","optionLabel","label","optionValue","value","placeholder","Select Organization Association...","inputId","orgAssociationSelect","required","",3,"options"],[3,"id","valid","dirty","message"],[1,"form-text","text-muted","d-block","mt-2"],[3,"hidden"],[3,"agencyChangeEmitter","parent","bindValue","allowAgencyAll","ctrlNameOverride","showStateAgencyName","submittedForm"],["for","customerSelect",1,"fw-medium"],["formControlName","customer","optionLabel","label","optionValue","value","placeholder","Select State / Federal Agency...","inputId","customerSelect","required","",3,"options","loading"],["for","documentTypeSelect",1,"fw-medium"],["formControlName","documentType","optionLabel","mainLabel","optionValue","documentTypeID","placeholder","Select Document Type...","inputId","documentTypeSelect","required","",3,"options","loading"],[1,"form-text","text-muted","d-block","mt-1"],["for","description",1,"fw-medium"],["maxlength","255","id","description","rows","3","placeholder","Enter a descriptive name for this document","formControlName","description","required","",1,"form-control"],[1,"d-flex","align-items-center","gap-2","pt-3","border-top"],["pTemplate","footer"],["key","securityAddendumOverwriteConfirmation","appendTo","body"],[1,"mb-0"],["for","fileUpload",1,"fw-medium"],["mode","advanced","name","file","accept",".pdf,.jpg,.jpeg,.png",1,"w-100",3,"onSelect","maxFileSize","multiple","customUpload"],[1,"text-danger","d-block","mt-1"],[1,"border-2","border-dashed","rounded","p-5","text-center","bg-white"],[1,"pi","pi-upload",2,"font-size","4rem","color","#6c757d"],[1,"small","mb-1","mt-3"],["type","button",1,"btn","btn-link","p-0","text-primary",3,"click"],[1,"small","text-muted"],[1,"p-2","bg-primary","bg-opacity-10","border","border-primary","rounded","d-inline-flex","align-items-center"],[1,"small","text-white","mb-0","d-flex","align-items-center"],[1,"pi","pi-file","me-2"],["formControlName","createAnother","inputId","createAnother",3,"binary"],["for","createAnother",1,"mb-0","small","cursor-pointer"],["pTooltip","Keep the form open after uploading to quickly add multiple documents. Only the document type, description, and file upload fields will reset.","tooltipPosition","top",1,"pi","pi-info-circle","text-muted",2,"cursor","help",3,"escape"],["pButton","","type","button",1,"p-button-outlined",3,"click","disabled"],[3,"icon"],["pButton","","type","button",1,"btn","btn-primary",3,"click","disabled"],["animation","spin",3,"icon"]],template:function(i,n){if(i&1){let d=D();l(0,"p-dialog",6),oe("visibleChange",function(w){return f(d),ne(n.showDialog,w)||(n.showDialog=w),_(w)}),v("onHide",function(){return f(d),_(n.close())}),V(1,ki,2,1,"ng-template",7),l(2,"div",8)(3,"div",9)(4,"label",10),m(5," Organization Association "),r(),p(6,"cjo-required",11)(7,"p-select",12)(8,"cjo-invalid-form-feedback",13),l(9,"small",14),m(10,"Who is this document for?"),r()(),l(11,"div",15)(12,"agency-select",16,0),v("agencyChangeEmitter",function(w){return f(d),_(n.onAgencySelectChange(w))}),r(),p(14,"cjo-invalid-form-feedback",13),r(),l(15,"div",15)(16,"label",17),m(17," Select State / Federal Organization "),r(),p(18,"cjo-required",11)(19,"p-select",18)(20,"cjo-invalid-form-feedback",13),r(),l(21,"div")(22,"label",19),m(23," Document Type "),r(),p(24,"cjo-required",11)(25,"p-select",20)(26,"cjo-invalid-form-feedback",13),l(27,"small",21),m(28," Document types may vary by agency in the future. "),r()(),l(29,"div")(30,"label",22),m(31," Description "),r(),p(32,"cjo-required",11),l(33,"textarea",23),m(34,"        "),r(),p(35,"cjo-invalid-form-feedback",13)(36,"cjo-invalid-form-feedback",13),r(),g(37,Pi,15,4,"div"),g(38,Vi,5,2,"div",24),r(),V(39,qi,7,5,"ng-template",25),r(),p(40,"p-confirmDialog",26)}if(i&2){let d,x,w,y,T,j,qe,ze,Z,Ue,Y,je;O(I(65,Mi)),ie("visible",n.showDialog),u("modal",!0)("closable",!0)("draggable",!1)("resizable",!1)("closeOnEscape",!0)("focusOnShow",!1),s(2),u("formGroup",n.form),s(5),O(I(66,Re)),u("options",n.organizationAssociationOptions),L("aria-describedby","org-association-error")("aria-invalid",n.form.get("orgAssociation").dirty&&!n.form.get("orgAssociation").valid),s(),u("id","org-association-error")("valid",(d=n.form.get("orgAssociation"))==null?null:d.valid)("dirty",((x=n.form.get("orgAssociation"))==null?null:x.touched)||n.isSubmitted())("message","Organization Association is required"),s(3),u("hidden",!n.isAgencyVisible()),s(),u("parent",n.form)("bindValue","agencyI
94D")("allowAgencyAll",!0)("ctrlNameOverride","agency")("showStateAgencyName",!0)("submittedForm",n.isSubmitted()),s(2),u("id","agency-error")("valid",(w=n.form.get("agency"))==null?null:w.valid)("dirty",((y=n.form.get("agency"))==null?null:y.touched)||n.isSubmitted())("message","Agency is required"),s(),u("hidden",!n.isCustomerVisible()),s(4),O(I(67,Re)),u("options",n.customerOptions())("loading",n.isLoadingCustomerOptions()),L("aria-describedby","customer-error")("aria-invalid",n.form.get("customer").dirty&&!n.form.get("orgAssociation").valid),s(),u("id","customer-error")("valid",(T=n.form.get("customer"))==null?null:T.valid)("dirty",((j=n.form.get("customer"))==null?null:j.touched)||n.isSubmitted())("message","Customer is required"),s(5),O(I(68,Re)),u("options",n.documentTypeOptions())("loading",n.isLoadingDocumentTypes()),L("aria-describedby","document-type-error")("aria-invalid",n.form.get("documentType").dirty&&!n.form.get("documentType").valid),s(),u("id","document-type-error")("valid",(qe=n.form.get("documentType"))==null?null:qe.valid)("dirty",((ze=n.form.get("documentType"))==null?null:ze.touched)||n.isSubmitted())("message","Document Type is required"),s(7),L("aria-describedby","description-required-error description-maxlength-error")("aria-invalid",n.form.get("description").dirty&&!n.form.get("description").valid),s(2),u("id","description-required-error")("valid",((Z=n.form.get("description"))==null?null:Z.errors)==null||((Z=n.form.get("description"))==null?null:Z.errors.required)!==!0)("dirty",((Ue=n.form.get("description"))==null?null:Ue.touched)||n.isSubmitted())("message","Description is required"),s(),u("id","description-maxlength-error")("valid",((Y=n.form.get("description"))==null?null:Y.errors)==null||!((Y=n.form.get("description"))!=null&&Y.errors.maxlength))("dirty",((je=n.form.get("description"))==null?null:je.touched)||n.isSubmitted())("message","Description cannot exceed 255 characters"),s(),h(n.mode()==="ADD"?37:-1),s(),h(n.mode()==="ADD"?38:-1),s(2),O(I(69,Ei))}},dependencies:[ae,pe,se,le,de,gt,ue,fe,bt,re,ve,be,Kt,Ot,Tt,At,ye,xe,_t,Dt,yt,ft,$t,Gt,Me,zt,Ct,St,qt,ge,ce,me,Ce],styles:["[_nghost-%COMP%]     .p-datatable{border:none}[_nghost-%COMP%]     .p-dropdown:not(.p-disabled):hover{border-color:var(--bs-primary)}[_nghost-%COMP%]     .p-dropdown:not(.p-disabled).p-focus{border-color:var(--bs-primary);box-shadow:0 0 0 .25rem rgba(var(--bs-primary-rgb),.25)}[_nghost-%COMP%]     .p-checkbox .p-checkbox-box{border-radius:var(--bs-border-radius)}[_nghost-%COMP%]     .p-checkbox .p-checkbox-box.p-highlight{background-color:var(--bs-primary);border-color:var(--bs-primary)}[_nghost-%COMP%]     .p-dialog-footer{display:flex;justify-content:flex-end;gap:.5rem}"]});let e=a;return e})()});function Bi(e,a){if(e&1&&(l(0,"div",23),m(1),r()),e&2){let o=c(2);s(),nt(" ",o.employeeName(),"",o.employeeName()&&o.agencyName()?" \xB7 ":"","",o.agencyName()," ")}}function Gi(e,a){if(e&1){let o=D();l(0,"div",18)(1,"div")(2,"div",19)(3,"span",20),m(4),r(),l(5,"span",21),p(6,"fa-icon",22),m(7," Peak Managed "),r()(),g(8,Bi,2,3,"div",23),r(),l(9,"button",24),v("click",function(){f(o);let i=c();return _(i.cancel())}),r()()}if(e&2){let o=c();s(4),M(" ",o.mode()==="create"?"Add Submission":"Edit Submission"," "),s(2),u("icon",o.faLock),s(2),h(o.employeeName()||o.agencyName()?8:-1)}}function $i(e,a){if(e&1){let o=D();l(0,"li",27),p(1,"fa-icon",28),l(2,"a",29),v("click",function(){let i=f(o).$implicit,n=c(2);return _(n.downloadRequiredForm(i))}),m(3),r()()}if(e&2){let o=a.$implicit,t=c(2);s(),u("icon",t.faFile),s(),L("aria-label","Download "+o.fileName),s(),M(" ",o.fileName," ")}}function Wi(e,a){if(e&1&&(l(0,"div",5)(1,"div",25),m(2," Required documents for this agency (from agency profile) "),r(),l(3,"ul",26),ee(4,$i,4,3,"li",27,Hi),r()()),e&2){let o=c();s(4),te(o.requiredDocuments())}}function Xi(e,a){if(e&1&&m(0),e&2){let o=c();M(" Documents included (",o.includedDocuments().length,") ")}}function Qi(e,a){if(e&1&&m(0),e&2){let o=c();M(" Documents on file (",o.documentsTotalCount(),") ")}}function Ji(e,a){if(e&1){let o=D();l(0,"button",30),v("click",function(){f(o);let i=c();return _(i.uploadDialogOpen.set(!0))}),p(1,"i",31),m(2," Upload document "),r()}}function Zi(e,a){e&1&&(l(0,"p",13),m(1,"No documents included."),r())}function Yi(e,a){if(e&1&&(l(0,"li",33),p(1,"fa-icon",28),l(2,"span"),m(3),r()()),e&2){let o=a.$implicit,t=c(3);s(),u("icon",t.faFile),s(2),G(o.label)}}function Ki(e,a){if(e&1&&(l(0,"ul",32),ee(1,Yi,4,2,"li",33,ai),r()),e&2){let o=c(2);s(),te(o.includedDocuments())}}function en(e,a){if(e&1&&g(0,Zi,2,0,"p",13)(1,Ki,3,0,"ul",32),e&2){let o=c();h(o.includedDocuments().length?1:0)}}function tn(e,a){e&1&&(l(0,"p",13),m(1,"Loading documents..."),r())}function nn(e,a){e&1&&(l(0,"p",13),m(1,"No documents on file for this employee."),r())}function on(e,a){if(e&1){let o=D();l(0,"div",33)(1,"p-checkbox",37),v("ngModelChange",function(i){let n=f(o).$implicit,d=c(3);return _(d.toggleDocument(n.documentID,i))}),r(),l(2,"label",38),m(3),r(),l(4,"span",39),m(5),r()()}if(e&2){let o=a.$implicit,t=c(3);s(),u("binary",!0)("inputId","peak-doc-"+o.documentID)("ngModel",t.isDocumentSelected(o.documentID))("ngModelOptions",I(7,ji)),s(),u("for","peak-doc-"+o.documentID),s(),M(" ",o.label," "),s(2),G(o.typeLabel)}}function an(e,a){if(e&1){let o=D();l(0,"p-paginator",40),v("onPageChange",function(i){f(o);let n=c(3);return _(n.onDocumentsPageChange(i))}),r()}if(e&2){let o=c(3);u("rows",o.DOCS_PAGE_SIZE)("totalRecords",o.documentsTotalCount())("first",(o.documentsPage()-1)*o.DOCS_PAGE_SIZE)("showCurrentPageReport",!1)}}function rn(e,a){if(e&1&&(l(0,"div",35),ee(1,on,6,8,"div",33,ai),r(),g(3,an,1,4,"p-paginator",36)),e&2){let o=c(2);s(),te(o.checklistDocuments()),s(2),h(o.showDocumentsPaginator()?3:-1)}}function sn(e,a){if(e&1&&(g(0,tn,2,0,"p",13)(1,nn,2,0,"p",13)(2,rn,4,1),l(3,"p",34),m(4),r()),e&2){let o=c();h(o.loadingDocuments()?0:o.checklistDocuments().length?2:1),s(4),Ae(" ",o.selectedCount()," of ",o.documentsTotalCount()," selected \xB7 Uploaded documents are added to this employee's documents and included in the submission. ")}}function ln(e,a){e&1&&(l(0,"span",10),m(1,"(optional)"),r())}function dn(e,a){if(e&1){let o=D();l(0,"div",11)(1,"span",41),p(2,"fa-icon",28),l(3,"span",42),m(4),r()(),l(5,"button",43),v("click",function(){f(o);let i=c();return _(i.clearPackingSlip())}),p(6,"i",44),r()()}if(e&2){let o=c();s(2),u("icon",o.faFile),s(2),G(a.name)}}function cn(e,a){if(e&1){let o=D();l(0,"div",12),p(1,"fa-icon",28),l(2,"a",45),v("click",function(){f(o);let i=c();return _(i.viewPackingSlip())}),m(3,"Packing slip (PDF)"),r()()}if(e&2){let o=c();s(),u("icon",o.faFile)}}function mn(e,a){e&1&&(l(0,"p",13),m(1,"No packing slip attached."),r())}function un(e,a){if(e&1&&(l(0,"div",49),m(1),r()),e&2){let o=c(2);s(),G(o.packingSlipError())}}function pn(e,a){if(e&1){let o=D();l(0,"label",46),p(1,"i",47),m(2),l(3,"input",48),v("change",function(i){f(o);let n=c();return _(n.onPackingSlipSelected(i))}),r()(),g(4,un,2,1,"div",49)}if(e&2){let o=c();
94s(2),M(" ",o.existingPackingSlipId()!==null||o.packingSlip()?"Replace packing slip (PDF)":"Upload packing slip (PDF)"," "),s(2),h(o.packingSlipError()?4:-1)}}function gn(e,a){if(e&1&&m(0),e&2){let o=c(2);M(" ",o.submission().notes," ")}}function hn(e,a){e&1&&(l(0,"span",50),m(1,"No notes."),r())}function fn(e,a){if(e&1&&(l(0,"p",15),g(1,gn,1,1)(2,hn,2,0,"span",50),r()),e&2){let o,t=c();s(),h((o=t.submission())!=null&&o.notes?1:2)}}function _n(e,a){if(e&1&&(l(0,"span",53),m(1),r()),e&2){let o=c(2);s(),M(" These notes were saved before the ",o.MAX_NOTES,"-character limit. Shorten them to save. ")}}function bn(e,a){e&1&&p(0,"span")}function vn(e,a){if(e&1&&(p(0,"textarea",51),l(1,"div",52),g(2,_n,2,1,"span",53)(3,bn,1,0,"span"),l(4,"span",39),m(5),r()()),e&2){let o=c();u("maxlength",o.MAX_NOTES),s(2),h(o.notesOverCapOnLoad()?2:3),s(2),it("text-danger",o.notesLength()>o.MAX_NOTES),s(),Ae(" ",o.notesLength(),"/",o.MAX_NOTES," ")}}function Sn(e,a){e&1&&(l(0,"span",55),m(1," Saving sends this submission to the Ready for Submission queue. "),r())}function Cn(e,a){e&1&&p(0,"span")}function xn(e,a){if(e&1){let o=D();l(0,"p-button",58),v("onClick",function(){f(o);let i=c(2);return _(i.cancel())}),r()}}function yn(e,a){if(e&1){let o=D();l(0,"p-button",59),v("onClick",function(){f(o);let i=c(2);return _(i.cancel())}),r(),l(1,"p-button",60),v("onClick",function(){f(o);let i=c(2);return _(i.save())}),r()}if(e&2){let o=c(2);u("outlined",!0),s(),u("label",o.mode()==="create"?"Send to Queue":"Save Submission")("disabled",!o.canSave())}}function Dn(e,a){if(e&1&&(l(0,"div",54),g(1,Sn,2,0,"span",55)(2,Cn,1,0,"span"),l(3,"div",56),g(4,xn,1,0,"p-button",57)(5,yn,2,3),r()()),e&2){let o=c();s(),h(o.readOnly()?2:1),s(3),h(o.readOnly()?4:5)}}var zi,Ui,ji,Hi,ai,ea,wn=P(()=>{A();at();dt();he();$e();Q();_e();De();Se();Vt();It();pi();vi();Xt();Ut();Si();Ee();oi();Le();bi();A();he();_e();Q();De();Se();Vt();zi=["pdfViewer"],Ui=()=>({width:"42rem"}),ji=()=>({standalone:!0}),Hi=(e,a)=>a.documentId,ai=(e,a)=>a.documentID;ea=(()=>{let a=class a{constructor(){this.messageService=S(z),this.messageHelperService=S(we),this.clearanceService=S(Ht),this.documentService=S(J),this.edlService=S(Ie),this.fb=S(ht),this.visible=E.required(),this.mode=E.required(),this.clearanceId=E.required(),this.userId=E.required(),this.agencyId=E(0),this.customerId=E(""),this.employeeName=E(""),this.agencyName=E(""),this.canManage=E(!1),this.viewOnly=E(!1),this.submission=E(null),this.saved=X(),this.closed=X(),this.MAX_NOTES=500,this.DOCS_PAGE_SIZE=10,this.faLock=Lt,this.faFile=Rt,this.peakForm=this.fb.group({notes:this.fb.control("",{nonNullable:!0,validators:[U.maxLength(this.MAX_NOTES)]})}),this.formValue=N(this.peakForm.valueChanges,{initialValue:this.peakForm.getRawValue()}),this.onFileDocuments=b([]),this.insertedDocuments=b([]),this.loadingDocuments=b(!1),this.documentsPage=b(1),this.documentsTotalCount=b(0),this.documentTypes=b([]),this.selectedDocumentIds=b(new Set),this.packingSlip=b(null),this.packingSlipError=b(null),this.requiredDocuments=b([]),this.requiredDocumentsLoaded=b(!1),this.saving=b(!1),this.uploadDialogOpen=b(!1),this.seededNotes=b(""),this.seedEffect=W(()=>{let t=this.submission(),i=this.mode()==="edit";Oe(()=>{if(!i||!t)return;let n=t.notes??"";this.seededNotes.set(n),this.peakForm.controls.notes.setValue(n),this.selectedDocumentIds.set(new Set(t.documents.map(d=>d.documentId)))})}),this.loadEffect=W(()=>{let t=this.clearanceId();Oe(()=>{t&&(this.loadRequiredDocuments(t),this.loadDocumentTypes(),this.loadOnFileDocuments())})}),this.readOnly=C(()=>this.mode()==="create"?!this.canManage()||this.viewOnly():this.submission()?.status==="SUBMITTED"||this.viewOnly()||!this.canManage()),this.checklistDocuments=C(()=>[...this.insertedDocuments(),...this.onFileDocuments()]),this.selectedCount=C(()=>this.selectedDocumentIds().size),this.showDocumentsPaginator=C(()=>this.documentsTotalCount()>this.DOCS_PAGE_SIZE),this.includedDocuments=C(()=>{let t=this.submission();if(!t)return[];let i=new Map(this.checklistDocuments().map(n=>[n.documentID,n]));return t.documents.map(n=>({documentID:n.documentId,label:i.get(n.documentId)?.label||n.documentTypeLabel||`Document ${n.documentId}`,typeLabel:i.get(n.documentId)?.typeLabel||n.documentTypeLabel||""}))}),this.notesLength=C(()=>this.formValue().notes?.length??0),this.notesOverCapOnLoad=C(()=>this.seededNotes().length>this.MAX_NOTES),this.canSave=C(()=>!(this.readOnly()||this.saving()||this.notesLength()>this.MAX_NOTES||this.packingSlipError())),this.existingPackingSlipI
94d=C(()=>this.submission()?.packingSlipDocumentId??null)}isDocumentSelected(t){return this.selectedDocumentIds().has(t)}toggleDocument(t,i){this.selectedDocumentIds.update(n=>{let d=new Set(n);return i?d.add(t):d.delete(t),d})}onInlineDocumentCreated(t){if(!t?.documentID)return;let i=this.documentTypes().find(d=>d.value===t.documentTypeID)?.label??"",n={documentID:t.documentID,label:t.description||i||`Document ${t.documentID}`,typeLabel:i};this.insertedDocuments.update(d=>[n,...d.filter(x=>x.documentID!==n.documentID)]),this.onFileDocuments.update(d=>d.filter(x=>x.documentID!==n.documentID)),this.documentsTotalCount.update(d=>d+1),this.toggleDocument(n.documentID,!0)}onDocumentsPageChange(t){this.documentsPage.set((t?.page??0)+1),this.loadOnFileDocuments()}onPackingSlipSelected(t){let i=t.target,n=i.files?.[0]??null;if(this.packingSlipError.set(null),n&&n.type!=="application/pdf"){this.packingSlipError.set("The packing slip must be a PDF."),this.packingSlip.set(null),i.value="";return}this.packingSlip.set(n),i.value=""}clearPackingSlip(){this.packingSlip.set(null),this.packingSlipError.set(null)}downloadRequiredForm(t){this.clearanceService.downloadRequiredForm(this.clearanceId(),t.documentId).subscribe({next:i=>Jt(i,Qt(t.fileName||`required_form_${t.documentId}`,i.type)),error:i=>{console.error(i);let n=i?.status;this.messageService.add(n===404?this.messageHelperService.serviceResultErrorMessage("This form is no longer available.","while opening the required form","Not Found"):this.messageHelperService.errorMessage(i,"while opening the required form"))}})}viewPackingSlip(){let t=this.submission()?.id;t==null||this.existingPackingSlipId()==null||this.clearanceService.downloadPackingSlip(t).subscribe({next:i=>{this.pdfViewer?.viewPDF(i,`packing_slip_${t}.pdf`)},error:i=>{console.error(i),this.messageService.add(this.messageHelperService.errorMessage(i,"while opening the packing slip"))}})}cancel(){this.closed.emit()}onEscapeKey(){!this.visible()||this.saving()||this.uploadDialogOpen()||this.cancel()}save(){this.canSave()&&(this.mode()==="edit"?this.saveEdit():this.saveCreate())}saveCreate(){let t=this.packingSlip();this.saving.set(!0),this.clearanceService.createPeakSubmission(this.clearanceId(),F({clearanceId:this.clearanceId(),notes:this.peakForm.controls.notes.value,existingDocumentIds:[...this.selectedDocumentIds()]},t?{packingSlip:t}:{})).pipe(q(()=>this.saving.set(!1))).subscribe({next:()=>this.onWriteSuccess("Peak Managed Submission created successfully"),error:i=>this.handlePeakWriteError(i,"while creating the Peak Managed Submission")})}saveEdit(){let t=this.submission()?.id;if(t==null)return;let i=this.packingSlip();this.saving.set(!0),this.clearanceService.updatePeakSubmission(t,F({id:t,notes:this.peakForm.controls.notes.value,documentIds:[...this.selectedDocumentIds()]},i?{packingSlip:i}:{})).pipe(q(()=>this.saving.set(!1))).subscribe({next:()=>this.onWriteSuccess("Peak Managed Submission updated successfully"),error:n=>this.handlePeakWriteError(n,"while updating the Peak Managed Submission")})}onWriteSuccess(t){this.messageService.add(this.messageHelperService.successMessage(t,"Success")),this.saved.emit(),this.closed.emit()}loadRequiredDocuments(t){this.clearanceService.getRequiredForms(t).subscribe({next:i=>{this.requiredDocuments.set(i??[]),this.requiredDocumentsLoaded.set(!0)},error:i=>{console.error(i),this.requiredDocuments.set([]),this.requiredDocumentsLoaded.set(!0)}})}loadDocumentTypes(){this.documentTypes().length||this.documentService.getDocumentTypes().subscribe({next:t=>{this.documentTypes.set((t?.value??[]).map(i=>({label:i.mainLabel??i.description,value:i.documentTypeID})))},error:t=>{console.error(t),this.messageService.add(this.messageHelperService.errorMessage(t,"while loading document types"))}})}loadOnFileDocuments(){this.loadingDocuments.set(!0),this.edlService.listDocuments(this.buildDocRequest()).pipe(q(()=>this.loadingDocuments.set(!1))).subscribe({next:t=>{let i=new Set(this.insertedDocuments().map(d=>d.documentID)),n=(t?.value?.documents??[]).filter(d=>!i.has(d.documentID)).map(d=>({documentID:d.documentID,label:d.description||d.documentTypeName,typeLabel:d.documentTypeName}));this.onFileDocuments.set(n),this.documentsTotalCount.set(t?.value?.totalCount??n.length)},error:t=>{console.error(t),this.onFileDocuments.set([]),this.documentsTotalCount.set(0),this.messageService.add(this.messageHelperService.errorMessage(t,"while loading documents on file"))}})}buildDocRequest(){return{userID:this.userId(),pageSize:this.DOCS_PAGE_SIZE,pageNumber:this.documentsPage(),sortField:"uploadedOn",sortOrder:-1,filter:{filterType:Ve.All}}}handlePeakWriteError(t,i){let n=t?.status;if(n===409){let d=this.messageHelperService.firstResultMessage(t)||"This submission has already been submitted and is locked.";this.messageService.add(this.messageHelperService.serviceResultErrorMessage(d,i,"Submission Locked")),this.saved.emit(),this.closed.emit
94();return}if(n===415){this.messageService.add(this.messageHelperService.serviceResultErrorMessage("Editing a submission failed. Please refresh and try again.",i));return}if(n===404){this.messageService.add(this.messageHelperService.serviceResultErrorMessage("This submission is no longer available.",i,"Not Found")),this.saved.emit(),this.closed.emit();return}if(n===400){this.messageService.add(this.messageHelperService.serviceResultErrorMessage(this.messageHelperService.firstResultMessage(t),i));return}console.error(t),this.messageService.add(this.messageHelperService.errorMessage(t,i))}};a.\u0275fac=function(i){return new(i||a)},a.\u0275cmp=K({type:a,selectors:[["cjo-peak-submission-modal"]],viewQuery:function(i,n){if(i&1&&Je(zi,5),i&2){let d;Ze(d=Ye())&&(n.pdfViewer=d.first)}},hostBindings:function(i,n){i&1&&v("keydown.escape",function(){return n.onEscapeKey()},Xe)},inputs:{visible:[1,"visible"],mode:[1,"mode"],clearanceId:[1,"clearanceId"],userId:[1,"userId"],agencyId:[1,"agencyId"],customerId:[1,"customerId"],employeeName:[1,"employeeName"],agencyName:[1,"agencyName"],canManage:[1,"canManage"],viewOnly:[1,"viewOnly"],submission:[1,"submission"]},outputs:{saved:"saved",closed:"closed"},features:[Te([J])],decls:30,vars:20,consts:[["pdfViewer",""],[3,"onHide","visible","modal","closable","focusOnShow","focusTrap","draggable"],["pTemplate","header"],[3,"formGroup"],[1,"d-flex","flex-column","gap-3"],[1,"alert","alert-info","mb-0","py-2","px-3"],[1,"d-flex","align-items-center","justify-content-between","gap-2","mb-1"],[1,"form-label","fw-semibold","mb-0"],["type","button","aria-label","Upload document",1,"btn","btn-link","btn-sm","p-0","text-decoration-none","fw-medium","d-inline-flex","align-items-center","gap-1"],[1,"form-label","fw-semibold"],[1,"fw-normal","text-body-secondary"],[1,"d-flex","align-items-center","justify-content-between","gap-3","border","rounded","px-3","py-2"],[1,"d-flex","align-items-center","gap-2","border","rounded","px-3","py-2"],[1,"text-body-secondary","small","mb-0"],["for","peak-notes",1,"form-label","fw-semibold"],[1,"border","rounded","px-3","py-2","mb-0"],["pTemplate","footer"],[3,"showDialogChange","documentInsert","showDialog","userID"],[1,"d-flex","justify-content-between","align-items-start","w-100"],[1,"d-flex","flex-wrap","align-items-center","gap-2"],[1,"fw-semibold","fs-5"],[1,"badge","rounded-pill","bg-light","text-body-secondary","border","fw-normal","d-inline-flex","align-items-center","gap-1"],["aria-hidden","true",3,"icon"],[1,"text-body-secondary","small","mt-1"],["type","button","aria-label","Close",1,"btn-close",3,"click"],[1,"small","fw-semibold","mb-1"],[1,"list-unstyled","mb-0"],[1,"d-flex","align-items-center","gap-2"],["aria-hidden","true",1,"text-body-secondary",3,"icon"],["href","javascript:void(0)",1,"text-break",3,"click"],["type","button","aria-label","Upload document",1,"btn","btn-link","btn-sm","p-0","text-decoration-none","fw-medium","d-inline-flex","align-items-center","gap-1",3,"click"],[1,"pi","pi-upload","small"],[1,"list-unstyled","border","rounded","mb-0"],[1,"d-flex","align-items-center","gap-2","px-3","py-2","border-bottom"],[1,"text-body-secondary","small","mt-1","mb-0"],[1,"border","rounded"],[3,"rows","totalRecords","first","showCurrentPageReport"],[3,"ngModelChange","binary","inputId","ngModel","ngModelOptions"],[1,"mb-0","flex-grow-1","text-break",3,"for"],[1,"text-body-secondary","small","text-nowrap"],[3,"onPageChange","rows","totalRecords","first","showCurrentPageReport"],[1,"d-inline-flex","align-items-center","gap-2","text-truncate"],[1,"text-truncate"],["type","button","aria-label","Remove packing slip",1,"btn","btn-link","btn-sm","p-0","text-body-secondary",3,"click"],[1,"pi","pi-times"],["href","javascript:void(0)",3,"click"],[1,"d-flex","align-items-center","justify-content-center","gap-2","border","border-dashed","rounded","px-3","py-2","mt-2","mb-0",2,"border-style","dashed !important","cursor","pointer"],[1,"pi","pi-upload","text-body-secondary"],["type","file","accept","application/pdf",1,"d-none",3,"change"],[1,"text-danger","small","mt-1"],[1,"text-body-secondary"],["id","peak-notes","rows","3","formControlName","notes","placeholder","e.g. Stamp ORI on card, send 3 cards",1,"form-control",3,"maxlength"],[1,"d-flex","justify-content-between","align-items-start","gap-2","mt-1"],[1,"text-danger","small"],[1,"d-flex","align-items-center","justify-content-between","gap-3","w-100"],[1,"text-body-secondary","small"],[1,"d-flex","flex-shrink-0","gap-2"],["rounded","","label","Close"],["rounded","","label","Close",3,"onClick"],["rounded","","label","Cancel","severity","secondary",3,"onClick","outlined"],["rounded","","icon","pi pi-send",3,"onClick","label","disabled"]],template:function(i,n){if(i&1){let d=D();l(0,"p-dialog",1),v("onHide",function(){return f(d),_(n.closed.emit
94())}),V(1,Gi,10,3,"ng-template",2),l(2,"form",3)(3,"div",4),g(4,Wi,6,0,"div",5),l(5,"div")(6,"div",6)(7,"div",7),g(8,Xi,1,1)(9,Qi,1,1),r(),g(10,Ji,3,0,"button",8),r(),g(11,en,2,1)(12,sn,5,3),r(),l(13,"div")(14,"div",9),m(15," Packing Slip (PDF) "),g(16,ln,2,0,"span",10),r(),g(17,dn,7,2,"div",11)(18,cn,4,1,"div",12)(19,mn,2,0,"p",13),g(20,pn,5,2),r(),l(21,"div")(22,"label",14),m(23,"Notes for submitter"),r(),g(24,fn,3,1,"p",15)(25,vn,6,6),r()()(),V(26,Dn,6,2,"ng-template",16),r(),l(27,"cjo-add-edit-enhanced-document",17),oe("showDialogChange",function(w){return f(d),ne(n.uploadDialogOpen,w)||(n.uploadDialogOpen=w),_(w)}),v("documentInsert",function(w){return f(d),_(n.onInlineDocumentCreated(w))}),r(),p(28,"pdf-viewer",null,0)}if(i&2){let d;O(I(19,Ui)),u("visible",n.visible())("modal",!0)("closable",!1)("focusOnShow",!0)("focusTrap",!0)("draggable",!1),s(2),u("formGroup",n.peakForm),s(2),h(n.requiredDocuments().length?4:-1),s(4),h(n.readOnly()?8:9),s(2),h(n.readOnly()?-1:10),s(),h(n.readOnly()?11:12),s(5),h(n.readOnly()?-1:16),s(),h((d=n.packingSlip())?17:n.existingPackingSlipId()!==null?18:n.readOnly()?19:-1,d),s(3),h(n.readOnly()?-1:20),s(4),h(n.readOnly()?24:25),s(3),ie("showDialog",n.uploadDialogOpen),u("userID",n.userId())}},dependencies:[ae,pe,pt,se,le,de,ue,ut,ge,ce,me,fe,vt,re,ye,xe,ve,be,Pt,Ft,Ce,Bt,ni],encapsulation:2,changeDetection:0});let e=a;return e})()});export{Fe as a,Pe as b,Ve as c,k as d,Ee as e,Kt as f,ei as g,Ie as h,Le as i,ti as j,ii as k,ni as l,oi as m,ea as n,wn as o};

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.