1(self.webpackChunkacurovet=self.webpackChunkacurovet||[]).push([[4010],{2578:function($,R){var o,v;void 0!==(v="function"==typeof(o=function(){"use strict";function D(i,l,g){var d=new XMLHttpRequest;d.open("GET",i),d.responseType="blob",d.onload=function(){S(d.response,l,g)},d.onerror=function(){console.error("could not download file")},d.send()}function k(i){var l=new XMLHttpRequest;l.open("HEAD",i,!1);try{l.send()}catch{}return 200<=l.status&&299>=l.status}function h(i){try{i.dispatchEvent(new MouseEvent("click"))}catch{var l=document.createEvent("MouseEvents");l.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),i.dispatchEvent(l)}}var u="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof global&&global.global===global?global:void 0,F=u.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),S=u.saveAs||("object"!=typeof window||window!==u?function(){}:"download"in HTMLAnchorElement.prototype&&!F?function(i,l,g){var d=u.URL||u.webkitURL,m=document.createElement("a");m.download=l=l||i.name||"download",m.rel="noopener","string"==typeof i?(m.href=i,m.origin===location.origin?h(m):k(m.href)?D(i,l,g):h(m,m.target="_blank")):(m.href=d.createObjectURL(i),setTimeout(function(){d.revokeObjectURL(m.href)},4e4),setTimeout(function(){h(m)},0))}:"msSaveOrOpenBlob"in navigator?function(i,l,g){if(l=l||i.name||"download","string"!=typeof i)navigator.msSaveOrOpenBlob(function E(i,l){return typeof l>"u"?l={autoBom:!1}:"object"!=typeof l&&(console.warn("Deprecated: Expected third argument to be a object"),l={autoBom:!l}),l.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(i.type)?new Blob(["\ufeff",i],{type:i.type}):i}(i,g),l);else if(k(i))D(i,l,g);else{var d=document.createElement("a");d.href=i,d.target="_blank",setTimeout(function(){h(d)})}}:function(i,l,g,d){if((d=d||open("","_blank"))&&(d.document.title=d.document.body.innerText="downloading..."),"string"==typeof i)return D(i,l,g);var m="application/octet-stream"===i.type,N=/constructor/i.test(u.HTMLElement)||u.safari,T=/CriOS\/[\d]+/.test(navigator.userAgent);if((T||m&&N||F)&&typeof FileReader<"u"){var f=new FileReader;f.onloadend=function(){var r=f.result;r=T?r:r.replace(/^data:[^;]*;/,"data:attachment/file;"),d?d.location.href=r:location=r,d=null},f.readAsDataURL(i)}else{var _=u.URL||u.webkitURL,w=_.createObjectURL(i);d?d.location=w:location.href=w,d=null,setTimeout(function(){_.revokeObjectURL(w)},4e4)}});u.saveAs=S.saveAs=S,$.exports=S})?o.apply(R,[]):o)&&($.exports=v)},19340:($,R,o)=>{"use strict";o.d(R,{L:()=>u});var c=o(21413),v=o(48021),E=o(17864),D=o(83586),k=o(97917),h=o(41360);let u=(()=>{class F{constructor(i){this.webSocketService=i,this.connectionCheck$=new c.B,this.connectionTransferred$=new c.B,this.fileDownloadRunning$=new c.B,this.fileDownloadCompleted$=new c.B,this.fileDownloadProgress$=new c.B,this.fileDownloadError$=new c.B,this.downloadFileInfo={},this.webSocketStatusEnum=k.F3,this.baseUrl=D.yT.socketApiUrl,this.prefix="api",this.version="v1",this.useSecureSocket=!0}initiateConnection(i,l,g={},d){this.baseUrl?(this.webSocketConnection=this.webSocketService.connect(`${this.baseUrl}/${this.prefix}/${this.version}/${i}`,this.useSecureSocket,{ping:l,...g}),this.defaultDownloadFileName=d,this.handleSocketEvents(l)):this.connectionCheck$.next({ping:l,connectionEstablished:!1})}terminateConnection(){this.webSocketConnection&&this.webSocketConnection.readyState===WebSocket.OPEN&&this.webSocketConnection.send(JSON.stringify({header:this.webSocketStatusEnum.CLOSE_CONNECTION,data:null})),this.webSocketService.disconnect(this.webSocketConnection)}handleSocketEvents(i){this.webSocketConnection.onopen=()=>{this.webSocketConnection.send((0,v.M2)()),this.connectionCheck$.next({ping:i,connectionEstablished:!0})},this.webSocketConnection.onerror=l=>{this.connectionCheck$.next({ping:i,connectionEstablished:!1}),this.fileDownloadRunning$.next(!1),this.fileDownloadError$.next(null)},this.webSocketConnection.onmessage=l=>{this.handleSocketMessage(l.data)}
1,this.webSocketConnection.onclose=()=>{this.downloadFileInfo={},this.connectionCheck$.next({ping:i,connectionEstablished:!1})}}handleSocketMessage(i){if("object"==typeof i)return void(this.downloadFileInfo={...this.downloadFileInfo,filename:this.downloadFileName||this.defaultDownloadFileName,blob:i});const l=JSON.parse(i);switch(l.header){case this.webSocketStatusEnum.PREPARING_DATA:case this.webSocketStatusEnum.RECEIVING_FILE:case this.webSocketStatusEnum.SAVING_FILE:this.setDownloadFileName(l),this.fileDownloadRunning$.next(!0);break;case this.webSocketStatusEnum.PROCESSING_DATA:this.setDownloadFileName(l),this.fileDownloadRunning$.next(!0),this.fileDownloadProgress$.next(l.data);break;case this.webSocketStatusEnum.RECEIVED_FILE:this.fileDownloadRunning$.next(!1),this.fileDownloadCompleted$.next(this.downloadFileInfo);break;case this.webSocketStatusEnum.SYNC_COMPLETED:this.fileDownloadRunning$.next(!1),this.fileDownloadCompleted$.next(null);break;case this.webSocketStatusEnum.TRANSFERRING_CONNECTION:this.fileDownloadRunning$.next(!1),this.connectionTransferred$.next(!0),this.terminateConnection();break;case this.webSocketStatusEnum.CLOSING_CONNECTION:this.fileDownloadRunning$.next(!1),this.terminateConnection();break;case this.webSocketStatusEnum.INTERNAL_SERVER_ERROR:case this.webSocketStatusEnum.UNAUTHORIZED:case this.webSocketStatusEnum.FORBIDDEN:case this.webSocketStatusEnum.ERROR_DOWNLOAD_CANCELLED:case this.webSocketStatusEnum.ERROR_PARSING_MESSAGE:case this.webSocketStatusEnum.ERROR_BAD_REQUEST:case this.webSocketStatusEnum.SYNC_ALREADY_IN_PROGRESS:case this.webSocketStatusEnum.ERROR_UNKNOWN:this.fileDownloadRunning$.next(!1),this.fileDownloadError$.next(l&&l.data&&"string"==typeof l.data?l.data:"")}}setDownloadFileName(i){this.downloadFileName=i&&i.data&&"string"!=typeof i.data?i.data.fileName:null}static{this.\u0275fac=function(l){return new(l||F)(h.KVO(E.V))}}static{this.\u0275prov=h.jDH({token:F,factory:F.\u0275fac})}}return F})()},31911:($,R,o)=>{"use strict";o.d(R,{c:()=>k});var c=o(32881),v=o(77883),E=o(59115),D=o(41360);let k=(()=>{class h{static{this.\u0275fac=function(S){return new(S||h)}}static{this.\u0275mod=D.$C({type:h})}static{this.\u0275inj=D.G2t({imports:[c.MD,E.Cn,v.t,v.t]})}}return h})()},32840:($,R,o)=>{"use strict";o.d(R,{j:()=>f});var c=o(41360),v=o(2578),D=o(7180),k=o(23294),h=o(19340),u=o(1187),F=o(98149),S=o(69508),i=o(7763),l=o(32881),g=o(59115),d=o(52426);const m=["connectionTransferredTooltip"];function N(_,w){if(1&_){const r=c.RV6();c.qex(0),c.j41(1,"app-button",1),c.bIt("onClick",function(){c.eBV(r);const C=c.XpG();return c.Njj(C.downloadFile())}),c.k0s(),c.bVm()}if(2&_){const r=c.XpG();c.R7$(),c.Y8G("label",r.label)("variant",r.variant)("isLoading",r.isFileDownloadRunning)("appearance",r.appearance)("iconSize",r.iconSize)("disabled",r.disabled)("icon",r.icon)("color",r.color)("iconTooltipText",r.iconTooltipText)("iconTooltipPosition",r.iconTooltipPosition)("iconColor",r.iconColor)("size",r.size)}}function T(_,w){if(1&_){const r=c.RV6();c.qex(0),c.j41(1,"a",2),c.bIt("click",function(){c.eBV(r);const C=c.XpG();return c.Njj(C.downloadFile())}),c.EFF(2),c.k0s(),c.bVm()}if(2&_){const r=c.XpG();c.R7$(2),c.JRh(r.label)}}let f=(()=>{class _ extends F.S{constructor(r,t,C){super(),this.snackbarService=r,this.changeDetectorRef=t,this.socketDownloadService=C,this.renderAs="button",this.disabled=!1,this.showTooltip=!0,this.fileType="XLSX",this.fileName=`acurovet-${(0,u.kT)(S.$.day,(0,u.BQ)(),u.ez)}.xlsx`,this.pageSize="all",this.onDownloadXlsx=new c.bkB,this.variant="flat",this.size="lg",this.type="button",this.color="primary",this.iconSize="lg",this.iconTooltipPosition="below",this.block=!1,this.isLoading=!1,this.tooltipPosition="below",this.intermediateState=!1,this.isFileDownloadRunning=!1,this.isConnectionEstablished=!1,this.isConnectionTransferred=!1,this.errorMessage="",this.downloadFilters={timezone:(0,u.vS)()||(0,u.P0)()}}ngOnDestroy(){super.ngOnDestroy(),this.isFileDownloadRunning||this.destroySubscriptions()}downloadFile(){this.isFileDownloadRunning=!0,this.errorMessage="",this.detectChanges(),this.checkFileUploadRunningStatus(),this.establishSocketDownloadConnection(!1),this.handleFileDownload(),this.handleFileDownloadError()}checkFileUploadRunningStatus(){this.socketDownloadService.fileDownloadRunning$.pipe(this.pickUntil(),(0,k.F)()).subscribe(r=>{this.isFileDownloadRunning=r,this.detectChanges()})}establishSocketDownloadConnection(r){const t=this.downloadFilters,C={...t,filters:{...t.filters,...this.filters.filters},sort:{...this.filters.sort}};this.socketDownloadService.initiateConnection(this.endpoint,r,C,this.fileName)}handleFileDownload(){this.downloadProgressSubscription=this.socketDownloadService.fileDownloadProgress$.subscribe(r=>{this.fileDownloadProgress=r,this.detectChanges()}),this.downloadSubscription=this.socketDownloadService.fileDownloadCompleted$.subscribe(r=>{this.isFileDownloadRunning=!1,this.intermediateState=!0,this.detectChanges(),r&&r.blob&&(0,v.saveAs)(r.blob,r.filename),this.intermediateState=!1,this.fileDownloadProgress=null,this.socketDownloadService.terminateConnection(),this.destroySubscriptions()})}handleFileDownloadError(){this.downloadErrorSubscription=this.socketDownloadService.fileDownloadError$.subscribe(r=>{this.errorMessage=`Error while exporting report : ${r||"Unknown Error"}`,this.snackbarService.closeActionSnackBar(this.errorMessage),this.isFileDownloadRunning=!1,this.fileDownloadProgress=null,this.socketDownloadService.terminateConnection(),this.detectChanges(),this.destroySubscriptions()})}destroySubscriptions(){this.downloadSubscription&&this.downloadSubscription?.unsubscribe(),this.downloadErrorSubscription&&this.downloadErrorSubscription?.unsubscribe(),this.downloadProgressSubscription&&this.downloadProgressSubscription?.unsubscribe()}detectChanges(){this.changeDetectorRef.detectChanges()}static{this.\u0275fac=function(t){return new(t||_)(c.rXU(i.z),c.rXU(c.gRc),c.rXU(h.L))}}static{this.\u0275cmp=c.VBU({type:_,selectors:[["app-socket-download-button"]],viewQuery:function(t,C){if
1(1&t&&c.GBs(m,5),2&t){let y;c.mGM(y=c.lsd())&&(C.connectionTransferredTooltip=y.first)}},inputs:{renderAs:"renderAs",label:"label",endpoint:"endpoint",disabled:"disabled",showTooltip:"showTooltip",fileType:"fileType",fileExtension:"fileExtension",fileName:"fileName",pageSize:"pageSize",filters:"filters",variant:"variant",appearance:"appearance",size:"size",type:"type",color:"color",icon:"icon",iconSize:"iconSize",iconColor:"iconColor",iconTooltipText:"iconTooltipText",iconTooltipPosition:"iconTooltipPosition",class:"class",block:"block",isLoading:"isLoading",toolTipText:"toolTipText",tooltipClass:"tooltipClass",showToolTip:"showToolTip",tooltipHideDelay:"tooltipHideDelay",tooltipPosition:"tooltipPosition"},outputs:{onDownloadXlsx:"onDownloadXlsx"},standalone:!1,features:[c.Jv_([{provide:D.Lt,useValue:"petOwner"},h.L]),c.Vt3],decls:2,vars:2,consts:[[4,"ngIf"],[3,"onClick","label","variant","isLoading","appearance","iconSize","disabled","icon","color","iconTooltipText","iconTooltipPosition","iconColor","size"],["mat-menu-item","",3,"click"]],template:function(t,C){1&t&&c.DNE(0,N,2,12,"ng-container",0)(1,T,3,1,"ng-container",0),2&t&&(c.Y8G("ngIf","button"===C.renderAs),c.R7$(),c.Y8G("ngIf","menu-item"===C.renderAs))},dependencies:[l.bT,g.fb,d.Q],encapsulation:2,changeDetection:0})}}return _})()},74010:($,R,o)=>{"use strict";o.r(R),o.d(R,{FeedbackIssueModule:()=>ce});var c=o(32881),v=o(66682),E=o(7180),D=o(25207),k=o(70980),h=o(97e3),u=o(80216),F=o(41100),S=o(56119),i=o(1187),l=o(61381),g=o(98149),d=o(96354),m=o(46463),N=o(48021),T=o(72187),f=o(5362);class _{static mapFromApi(s){const e=new _;return e.fileName=s.fileName,e.logicalName=s.logicalName,e.type=s?.logicalName.split(".").pop(),e.icon=this.getIcon(e.type),e}static getIcon(s){switch(s){case f.bN.APPLICATION_WPS_OFFICE_XLSX:case f.bN.APPLICATION_WPS_OFFICE_XLS:case f.bN.XLS:return"xlsx";case f.bN.PPT:return"ppt";case f.bN.APPLICATION_WPS_OFFICE_PDF:case f.bN.PDF:return"pdf";case f.bN.PNG:case f.bN.JPEG:case f.bN.IMAGE_PNG:case f.bN.JPG:return"image";case f.bN.APPLICATION_WPS_OFFICE_DOCX:case f.bN.APPLICATION_WPS_OFFICE_DOC:return"doc"}}}class w extends m.U{static mapFromApi(s){const e=new w;return e.id=s.id,e.userId=s.userId,e.title=s.title,e.firstName=s.firstName,e.lastName=s.lastName,e.fullName=(0,N.o$)(s.firstName,s.lastName),e.type=s.type,e.status=s.status,e.statusLabel=this.getFeedbackStatus(s.status),e.email=s.email,e.comment=s.comment,e.rating=s.rating,e.isAcurovetContact=s.isAcurovetContact,e.createdDate=s.createdAt,e.attachments=(0,h.cy)(s.files)&&s.files.map(a=>_.mapFromApi(a)),e.mapToConcurrencyModel(s),e}static getFeedbackStatus(s){switch(s){case T.G.open:return"Open";case T.G.inProgress:return"In Progress";case T.G.done:return"Done";default:return}}}var r=o(7488),t=o(41360);let C=(()=>{class n{constructor(e){this.baseHttpService=e,this.endpoint="super-admin/user/feedback"}listFeedbackIssues(e){return this.baseHttpService.get(this.endpoint,(0,F.R6)(e))}getFeedbackIssue(e){return this.baseHttpService.get(`${this.endpoint}/${e}`)}updateFeedbackIssue(e,a){return this.baseHttpService.put(`${this.endpoint}/${e}`,a)}static{this.\u0275fac=function(a){return new(a||n)(t.KVO(r.F))}}static{this.\u0275prov=t.jDH({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),y=(()=>{class n{constructor(e){this.httpService=e}listFeedbackIssues(e){return this.httpService.listFeedbackIssues(e).pipe((0,d.T)(a=>{const{items:p,...b}=a&&a.data;return{items:(0,h.cy)(p)&&p.map(P=>w.mapFromApi(P))||[],...b}}))}getFeedbackIssue(e){return this.httpService.getFeedbackIssue(e).pipe((0,d.T)(a=>a.data))}updateFeedbackIssue(e,a){return this.httpService.updateFeedbackIssue(e,a).pipe((0,d.T)(p=>p.data))}static{this.\u0275fac=function(a){return new(a||n)(t.KVO(C))}}static{this.\u0275prov=t.jDH({token:n,factory:n.\u0275fac})}}return n})();var x=o(89417),A=o(69508);class K{constructor(){this.startDate=new x.MJ((0,i.ei)((0,i.BQ)(),1,A.$.month)),this.endDate=new x.MJ((0,i.BQ)())}}var H=o(10467),z=o(18811);class Q extends m.U{}var Z=o(30338),O=o(45565),L=o(88498),B=o(96955),q=o(19458),j=o(52426),G=o(25596),tt=o(58346),et=o(99974),U=o(9183),X=o(13043),V=o(56027);
1function nt(n,s){if(1&n){const e=t.RV6();t.j41(0,"div",19),t.bIt("click",function(){const p=t.eBV(e).$implicit,b=t.XpG(4);return t.Njj(b.onAttachmentClick(p))}),t.nrm(1,"app-icon",20),t.k0s()}if(2&n){const e=s.$implicit;t.R7$(),t.Y8G("icon",e.icon)("size","lg")}}function at(n,s){if(1&n&&(t.j41(0,"div")(1,"span",16),t.EFF(2),t.k0s(),t.j41(3,"div",17),t.DNE(4,nt,2,2,"div",18),t.k0s()()),2&n){const e=t.XpG(2).$implicit,a=t.XpG();t.R7$(2),t.JRh(e("Attachments")),t.R7$(2),t.Y8G("ngForOf",null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.attachments)}}function ot(n,s){if(1&n){const e=t.RV6();t.j41(0,"div",10)(1,"div",11)(2,"div",12),t.EFF(3),t.nI1(4,"isEmpty"),t.k0s(),t.j41(5,"div"),t.EFF(6),t.nI1(7,"isEmpty"),t.k0s()(),t.j41(8,"div",11)(9,"div",12),t.EFF(10),t.k0s(),t.j41(11,"div"),t.EFF(12),t.nI1(13,"titlecase"),t.nI1(14,"isEmpty"),t.k0s()(),t.j41(15,"div",11)(16,"div",12),t.EFF(17),t.k0s(),t.j41(18,"div"),t.EFF(19),t.nI1(20,"isEmpty"),t.k0s()(),t.j41(21,"div",11)(22,"div",12),t.EFF(23),t.k0s(),t.j41(24,"div"),t.EFF(25),t.nI1(26,"dateFormat"),t.k0s()(),t.j41(27,"div",13)(28,"app-static-data-dropdown",14),t.bIt("optionSelected",function(p){t.eBV(e);const b=t.XpG(2);return t.Njj(b.updateFeedBackIssue(p))}),t.k0s()(),t.j41(29,"div",11),t.DNE(30,at,5,2,"div",15),t.k0s()()}if(2&n){const e=t.XpG().$implicit,a=t.XpG();t.R7$(3),t.JRh(t.bMT(4,11,null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.fullName)),t.R7$(3),t.JRh(t.bMT(7,13,null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.email)),t.R7$(4),t.JRh(e("Type")),t.R7$(2),t.JRh(t.bMT(14,17,t.bMT(13,15,null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.type))),t.R7$(5),t.JRh(e("Comment")),t.R7$(2),t.JRh(t.bMT(20,19,null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.comment)),t.R7$(4),t.JRh(e("Date")),t.R7$(2),t.JRh(t.i5U(26,21,null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.createdDate,"MMM DD, YYYY hh:mm A")),t.R7$(3),t.Y8G("control",a.statusControl)("label",e("Status")),t.R7$(2),t.Y8G("ngIf",(null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.attachments)&&(null==a.feedBackIssueDetails?null:a.feedBackIssueDetails.attachments.length))}}function st(n,s){if(1&n&&(t.j41(0,"mat-card",2)(1,"app-card-title",3)(2,"div",4),t.nrm(3,"app-button",5),t.k0s()(),t.j41(4,"div",6),t.DNE(5,ot,31,24,"div",7),t.k0s(),t.j41(6,"div",8),t.nrm(7,"app-button",9),t.k0s()()),2&n){const e=s.$implicit,a=t.XpG(),p=t.sdS(2);t.R7$(),t.Y8G("title",e("Feedback / Issue")),t.R7$(4),t.Y8G("ngIf",!a.isLoading)("ngIfElse",p),t.R7$(2),t.Y8G("label",e("Close"))}}function it(n,s){1&n&&(t.j41(0,"div",21),t.nrm(1,"mat-spinner",22),t.k0s())}let ct=(()=>{class n extends g.S{constructor(e,a,p,b,M,P){super(),this.changeDetectorRef=e,this.s3FileUploadService=a,this.errorHandlerService=p,this.feedbackIssueService=b,this.feedbackId=M,this.dialogRef=P,this.isLoading=!1,this.statusControl=new x.MJ(void 0)}ngOnInit(){this.getFeedbackIssue()}getFeedbackIssue(){this.feedbackId&&(this.isLoading=!0,this.detectChanges(),this.feedbackIssueService.getFeedbackIssue(this.feedbackId).pipe(this.pickFirstOrUntil(),(0,k.j)(()=>{this.isLoading=!1,this.detectChanges()})).subscribe({next:e=>{e&&(this.feedBackIssueDetails=w.mapFromApi(e),this.statusControl.setValue(this.feedBackIssueDetails.status),this.detectChanges())},error:e=>this.errorHandlerService.handle(e)}))}onAttachmentClick(e){var a=this;return(0,H.A)(function*(){if(!e?.logicalName)return;const p=`${z.t.feedbackAttachment(a.feedBackIssueDetails.userId)}/${e.logicalName}`,b=yield a.s3FileUploadService.getSignedUrl(p);window.open(b)})()}updateFeedBackIssue(e){const a=new Q;a.status=e&&e.id,a.updatedAt=this.feedBackIssueDetails?.updatedAt,this.feedbackIssueService.updateFeedbackIssue(this.feedbackId,a).pipe(this.pickUntil()).subscribe({next:p=>{},error:p=>this.errorHandlerService.handle(p)})}closeDialog(){this.dialogRef.close()}detectChanges(){this.changeDetectorRef.detectChanges()}static{this.\u0275fac=function(a){return new(a||n)(t.rXU(t.gRc),t.rXU(Z.p),t.rXU(S.c),t.rXU(y),t.rXU(O.e),t.rXU(O.m))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["app-feedback-issue-detail-dialog"]],standalone:!1,features:[t.Jv_([y,{provide:E.Lt,useValue:"admin"}]),t.Vt3],decls:3,vars:1,consts:[["loader",""],["class","mat-card-box",4,"transloco","translocoRead"],[1,"mat-card-box"],[3,"title"],["slotActionRight",""],["variant","icon","icon","cancel","iconSize","md","color","warn","mat-dialog-close",""],["mat-card-content",""],["gdColumns","repeat(2, minmax(0, 1fr))","gdGap","16px","class","px-16px py-1",4,"ngIf","ngIfElse"],["mat-card-action","","fxLayoutAlign","end center","fxLayoutGap","16px",1,"border-t","border-hr","p-1","bg-background"],["variant","stroked","mat-dialog-close","",3,"label"],["gdColumns","repeat(2, minmax(0, 1fr))","gdGap","16px",1,"px-16px","py-1"],["gdColumn","span 2"],[1,"font-bold"],[1,"w-25"],["type","FEEDBACK_STATUS","formFieldClass","input-with-no-bottom-padding",3,"optionSelected","control","label"],[4,"ngIf"],[1,"color-secondary-text","text-small"],[1,"mt-5px","flex"],["class","radius-xl mr-1 bg-hr p-1 relative","fxLayoutAlign","start center",3,"click",4,"ngFor","ngForOf"],["fxLayoutAlign","start center",1,"radius-xl","mr-1","bg-hr","p-1","relative",3,"click"],[1,"color-primary-dark",3,"icon","size"],["fxLayoutAlign","center center",1,"h-50vh"],["diameter","30"]],template:function(a,p){1&a&&t.DNE(0,st,8,4,"mat-card",1)(1,it,2,0,"ng-template",null,0,t.C5r),2&a&&t.Y8G("translocoRead","admin")},dependencies:[c.Sq,c.bT,E.bA,L.BO,L.sA,B.ZS,B.EK,B.BV,q.R,j.Q,G.RN,tt.y,et.D,U.LG,O.a,c.PV,X.Y,V.a],encapsulation:2,changeDetection:0})}}return n})();
1var lt=o(7763),rt=o(72243),dt=o(13600),pt=o(83716),ut=o(1066),mt=o(78359),ht=o(27082),ft=o(13912),gt=o(34378),_t=o(32840),I=o(3570),Y=o(67575),J=o(75862);const bt=n=>({"h-full":n}),Dt=(n,s,e)=>({"color-error-light":n,"color-green-light":s,"color-wild-blue-yonder":e});function vt(n,s){1&n&&t.nrm(0,"mat-progress-bar",39)}function Et(n,s){if(1&n&&(t.j41(0,"th",40),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("User"))}}function Ft(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.nI1(2,"isEmpty"),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.JRh(t.bMT(2,1,e.fullName))}}function Ct(n,s){if(1&n&&(t.j41(0,"th",40),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Email"))}}function It(n,s){if(1&n&&(t.j41(0,"td",41)(1,"div",42),t.EFF(2),t.nI1(3,"isEmpty"),t.k0s()()),2&n){const e=s.$implicit;t.R7$(2),t.JRh(t.bMT(3,1,e.email))}}function kt(n,s){if(1&n&&(t.j41(0,"th",43),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Comment"))}}function St(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.nI1(2,"isEmpty"),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.JRh(t.bMT(2,1,e.comment))}}function Rt(n,s){if(1&n&&(t.j41(0,"th",44),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Rating"))}}function wt(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.nI1(2,"isEmpty"),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.JRh(t.bMT(2,1,e.rating))}}function Tt(n,s){if(1&n&&(t.j41(0,"th",45),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Is Contact ?"))}}function xt(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.JRh(e.isAcurovetContact?"Yes":"No")}}function yt(n,s){if(1&n&&(t.j41(0,"th",46),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Type"))}}function $t(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.nI1(2,"titlecase"),t.nI1(3,"isEmpty"),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.JRh(t.bMT(3,3,t.bMT(2,1,e.type)))}}function Nt(n,s){if(1&n&&(t.j41(0,"th",47),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Date"))}}function Pt(n,s){if(1&n&&(t.j41(0,"td",41),t.EFF(1),t.nI1(2,"dateFormat"),t.nI1(3,"isEmpty"),t.nrm(4,"br"),t.EFF(5),t.nI1(6,"dateFormat"),t.nI1(7,"isEmpty"),t.k0s()),2&n){const e=s.$implicit;t.R7$(),t.SpI(" ",t.bMT(3,4,t.bMT(2,2,e.createdDate))," "),t.R7$(4),t.SpI(" ",t.bMT(7,9,t.i5U(6,6,e.createdDate,"hh:mm A"))," ")}}function At(n,s){if(1&n&&(t.j41(0,"th",45),t.EFF(1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.JRh(e("Status"))}}function Ot(n,s){if(1&n&&(t.j41(0,"td",41)(1,"span",48),t.EFF(2),t.nI1(3,"titlecase"),t.nI1(4,"isEmpty"),t.k0s()()),2&n){const e=s.$implicit,a=t.XpG(2);t.R7$(),t.Y8G("ngClass",t.sMw(6,Dt,e.status===a.feedbackIssueStatusEnum.open,e.status===a.feedbackIssueStatusEnum.done,e.status===a.feedbackIssueStatusEnum.inProgress)),t.R7$(),t.SpI(" ",t.bMT(4,4,t.bMT(3,2,e.statusLabel))," ")}}function Lt(n,s){1&n&&t.nrm(0,"th",49)}function Bt(n,s){if(1&n){const e=t.RV6();t.j41(0,"td",41)(1,"div",50)(2,"app-button",51),t.bIt("onClick",function(){const p=t.eBV(e).$implicit,b=t.XpG(2);return t.Njj(b.openFeedBackDialog(p.id))}),t.k0s()()()}}function Gt(n,s){if(1&n&&(t.j41(0,"td",54)(1,"span",55),t.EFF(2),t.k0s()()),2&n){const e=t.XpG(2).$implicit,a=t.XpG();t.Y8G("colSpan",a.displayedColumns.length),t.R7$(2),t.JRh(e("No Records Found"))}}function Mt(n,s){if(1&n&&(t.j41(0,"tr",52),t.DNE(1,Gt,3,2,"td",53),t.k0s()),2&n){const e=t.XpG(2);t.R7$(),t.Y8G("ngIf",!e.isLoading&&!e.dataSource.length)}}function jt(n,s){1&n&&t.nrm(0,"tr",56)}function Ut(n,s){1&n&&t.nrm(0,"tr",57)}function Xt(n,s){if(1&n){const e=t.RV6();t.j41(0,"app-paginator",58),t.bIt("page",function(p){t.eBV(e);const b=t.XpG(2);return t.Njj(b.handlePaginator(p))}),t.k0s()}if(2&n){const e=t.XpG(2);t.Y8G("length",e.totalItems)("pageIndex",e.pageConfig.page-1)}}function Vt(n,s){if(1&n){const e=t.RV6();t.j41(0,"app-page")(1,"app-page-header"),t.nrm(2,"app-page-title",1),t.j41(3,"div",2)(4,"app-search",3),t.bIt("search",function(p){t.eBV(e);const b=t.XpG();return t.Njj(b.handleSearch(p))}),t.k0s(),t.nrm(5,"app-socket-download-button",4),t.k0s()(),t.j41(6,"app-page-content",5)(7,"div",6)(8,"div",7)(9,"form",8)(10,"div",9)(11,"div"),t.nrm(12,"app-date-picker",10),t.k0s(),t.j41(13,"div"),t.nrm(14,"app-date-picker",11),t.k0s(),t.j41(15,"div")(16,"app-button",12),t.bIt("onClick",function(){t.eBV(e);const p=t.XpG();return t.Njj(p.handleFilter())}),t.k0s()()()()(),t.j41(17,"div",13)(18,"mat-card",14)(19,"div",15),t.DNE(20,vt,1,0,"mat-progress-bar",16),t.j41(21,"table",17),t.qex(22,18),t.DNE(23,Et,2,1,"th",19)(24,Ft,3,3,"td",20),t.bVm(),t.qex(25,21),t.DNE(26,Ct,2,1,"th",19)(27,It,4,3,"td",20),t.bVm(),t.qex(28,22),t.DNE(29,kt,2,1,"th",23)(30,St,3,3,"td",20),t.bVm(),t.qex(31,24),t.DNE(32,Rt,2,1,"th",25)(33,wt,3,3,"td",20),t.bVm(),t.qex(34,26),t.DNE(35,Tt,2,1,"th",27)(36,xt,2,1,"td",20),t.bVm(),t.qex(37,28),t.DNE(38,yt,2,1,"th",29)(39,$t,4,5,"td",20),t.bVm(),t.qex(40,30),t.DNE(41,Nt,2,1,"th",31)(42,Pt,8,11,"td",20),t.bVm(),t.qex(43,32),t.DNE(44,At,2,1,"th",27)(45,Ot,5,10,"td",20),t.bVm(),t.qex(46,33),t.DNE(47,Lt,1,0,"th",34)(48,Bt,3,0,"td",20),t.bVm(),t.DNE(49,Mt,2,1,"tr",35)(50,jt,1,0,"tr",36)(51,Ut,1,0,"tr",37),t.k0s()(),t.DNE(52,Xt,1,2,"app-paginator",38),t.k0s()()()()()}if(2&n){const e=s.$implicit,a=t.XpG();t.R7$(2),t.FS9("title",e("Feedback/Issue")),t.R7$(3),t.Y8G("label",e("Download CSV"))("endpoint","super-admin/user/feedback/download")("filters",a.pageConfig),t.R7$(),t.Y8G("noSpace",!0),t.R7$(3),t.Y8G("formGroup",a.filterForm),t.R7$(3),t.Y8G("label",e("Start Date"))("control",a.filterForm.controls.startDate)("max",a.filterForm.controls.endDate.value),t.R7$(2),t.Y8G("label",e("End Date"))("control",a.filterForm.controls.endDate)("min",a.filterForm.controls.startDate.value)("max",a.currentDate),t.R7$(2),t.Y8G("label",e("Submit")),t.R7$(4),t.Y8G("ngIf",a.isLoading),t.R7$(),t.Y8G("dataSource",a.dataSource)("ngClass",t.eq3(20,bt,!a.isLoading&&!a.dataSource.length)),t.R7$(29),t.Y8G("matHeaderRowDef",a.displayedColumns),t.R7$(),t.Y8G("matRowDefColumns",a.displayedColumns),t.R7$(),t.Y8G("ngIf",a.dataSource.length)}}const Yt=[{path:"",component:(()=>{class n extends g.S{constructor(e,a,p,b,M,P,le){super(),this.fb=e,this.dialogService=a,this.snackbarService=p,this.changeDetectorRef=b,this.translationService=M,this.errorHandlerService=P,this.feedbackIssueService=le,this.feedbackIssueStatusEnum=T.G,this.currentDate=(0,i.BQ)(),this.monthAgoDate=(0,i.ei)(this.currentDate,1,A.$.month),this.isLoading=!1,this.displayedColumns=["user","email","comment","rating","isContact","type","date","status","action"],this.dataSource=[],this.pageConfig={page:1,limit:l.D
17,filters:{startDate:(0,i.JM)(this.monthAgoDate,i.ez),endDate:(0,i.JM)(this.currentDate,i.ez)}}}ngOnInit(){this.initFilterForm(),this.listFeedbackIssues()}initFilterForm(){this.filterForm=this.fb.group(new K),this.detectChanges()}listFeedbackIssues(){this.isLoading=!0,this.detectChanges(),this.feedbackIssueService.listFeedbackIssues(this.pageConfig).pipe(this.pickFirstOrUntil(),(0,k.j)(()=>{this.isLoading=!1,this.detectChanges()})).subscribe({next:e=>{const{items:a,totalItems:p}=e;this.dataSource=a,this.totalItems=p,this.detectChanges()},error:e=>this.errorHandlerService.handle(e)})}openFeedBackDialog(e){this.dialogService.open(ct,{width:"900px",restoreFocus:!1,autoFocus:!1,panelClass:"modal-content-no-padding",data:e}).afterClosed().pipe(this.pickFirstOrUntil()).subscribe({next:()=>{this.listFeedbackIssues()},error:a=>this.errorHandlerService.handle(a)})}resetPage(){this.pageConfig.page=1}handleSearch(e){this.resetPage(),this.pageConfig={...this.pageConfig,filters:{...this.pageConfig.filters,globalSearch:(0,h.QG)(e)||void 0}},this.listFeedbackIssues()}handleSort(e){this.resetPage(),this.pageConfig={...this.pageConfig,sort:(0,F.qM)(e)},this.listFeedbackIssues()}handlePaginator(e){this.pageConfig={...this.pageConfig,page:e.pageIndex+1,limit:e.pageSize},this.listFeedbackIssues()}handleFilter(){const{startDate:e,endDate:a}=this.filterForm.value;this.resetPage(),this.pageConfig.filters={...this.pageConfig.filters,startDate:(0,i.JM)((0,i.Tv)(A.$.day,e),i.ez)||void 0,endDate:(0,i.JM)((0,i.kT)(A.$.day,a),i.ez)||void 0},this.listFeedbackIssues()}detectChanges(){this.changeDetectorRef.detectChanges()}static{this.\u0275fac=function(a){return new(a||n)(t.rXU(x.ok),t.rXU(u.o),t.rXU(lt.z),t.rXU(t.gRc),t.rXU(rt.L),t.rXU(S.c),t.rXU(y))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["app-feedback-issue"]],standalone:!1,features:[t.Jv_([y,{provide:E.Lt,useValue:"admin"}]),t.Vt3],decls:1,vars:1,consts:[[4,"transloco","translocoRead"],["slotTitle","",3,"title"],["slotActionRight","","fxLayoutAlign","start center","fxLayoutGap","16px"],["variant","secondary",3,"search"],[3,"label","endpoint","filters"],[3,"noSpace"],["gdRows","auto 1fr",1,"h-full","overflow-auto"],[1,"bg-surface","px-2","py-12px"],[3,"formGroup"],["fxLayoutAlign","end center","fxLayoutGap","15px"],[1,"input-with-no-bottom-padding",3,"label","control","max"],[1,"input-with-no-bottom-padding",3,"label","control","min","max"],[3,"onClick","label"],[1,"p-16px","h-full","overflow-auto"],["gdRows","1fr auto",1,"mat-card-box","overflow-hidden","h-full"],[1,"overflow-auto","h-full","progress-wrapper"],["mode","indeterminate",4,"ngIf"],["mat-table","","fixedLayout","true",1,"sticky-thead","sticky-tfoot",3,"dataSource","ngClass"],["matColumnDef","user"],["mat-header-cell","","mat-sort-header","","width","14%",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","email"],["matColumnDef","comment","sticky",""],["mat-header-cell","","mat-sort-header","","width","15%",4,"matHeaderCellDef"],["matColumnDef","rating"],["mat-header-cell","","mat-sort-header","","width","9%",4,"matHeaderCellDef"],["matColumnDef","isContact"],["mat-header-cell","","mat-sort-header","","width","10%",4,"matHeaderCellDef"],["matColumnDef","type"],["mat-header-cell","","mat-sort-header","","width","11%",4,"matHeaderCellDef"],["matColumnDef","date"],["mat-header-cell","","mat-sort-header","","width","12%",4,"matHeaderCellDef"],["matColumnDef","status"],["matColumnDef","action"],["mat-header-cell","","width","5%",4,"matHeaderCellDef"],["class","mat-row",4,"matNoDataRow"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["class","sticky bottom-0",3,"length","pageIndex","page",4,"ngIf"],["mode","indeterminate"],["mat-header-cell","","mat-sort-header","","width","14%"],["mat-cell",""],[1,"text-ellipsis"],["mat-header-cell","","mat-sort-header","","width","15%"],["mat-header-cell","","mat-sort-header","","width","9%"],["mat-header-cell","","mat-sort-header","","width","10%"],["mat-header-cell","","mat-sort-header","","width","11%"],["mat-header-cell","","mat-sort-header","","width","12%"],[1,"font-bold",3,"ngClass"],["mat-header-cell","","width","5%"],["fxLayoutAlign","flex-end center","fxLayoutGap","1rem"],["variant","icon","icon","eye-open","color","primary","iconSize","sm",3,"onClick"],[1,"mat-row"],["class","mat-cell text-center",3,"colSpan",4,"ngIf"],[1,"mat-cell","text-center",3,"colSpan"],[1,"color-hint-text"],["mat-header-row",""],["mat-row",""],[1,"sticky","bottom-0",3,"page","length","pageIndex"]],template:function(a,p){1&a&&t.DNE(0,Vt,53,22,"app-page",0),2&a&&t.Y8G("translocoRead","admin")},dependencies:[c.YU,c.bT,E.bA,L.BO,L.sA,dt.PW,B.EV,pt.S,ut.h,mt.y,ht.H,ft.j,gt.U,j.Q,_t.j,I.Zl,I.tL,I.ji,I.cC,I.YV,I.iL,I.KS,I.$R,I.YZ,I.NB,I.ky,G.RN,Y.HM,x.qT,x.cb,x.j4,J.I,c.PV,X.Y,V.a],encapsulation:2,changeDetection:0})}}return n})()}];let Jt=(()=>{class n{static{this.\u0275fac=function(a){return new(a||n)}}static{this.\u0275mod=t.$C({type:n})}static{this.\u0275inj=t.G2t({imports:[D.iI.forChild(Yt),D.iI]})}}return n})();var Wt=o(37213),Kt=o(87594),Ht=o(10735),zt=o(31911),Qt=o(77883),Zt=o(96733),qt=o(98107),te=o(57829),ee=o(96073),W=o(27799);const ne=[O.n],ae=[te.o,W.Y,Qt.t,G.Hu,Zt.p,qt.c,ee.K,U.D6],se=[I.tP,G.Hu],ie=[Wt.t,Kt.I,Ht.S,zt.c,(()=>{class n{static{this.\u0275fac=function(a){return new(a||n)}}static{this.\u0275mod=t.$C({type:n})}static{this.\u0275inj=t.G2t({imports:[c.MD,E.Q8,v.YF,ae,ne]})}}return n})()];let ce=(()=>{class n{static{this.\u0275fac=function(a){return new(a||n)}}static{this.\u0275mod=t.$C({type:n})}static{this.\u0275inj=t.G2t({imports:[c.MD,E.Q8,v.YF,Jt,ie,se,W.Y,Y.PO,x.X1,J.I]})}}return n})()}}]);
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.