1"use strict";(self.webpackChunkapp=self.webpackChunkapp||[]).push([[9589],{89589:(O,g,u)=>{u.d(g,{v:()=>_});var h=u(12299),a=u(71827),o=u(11979),l=u(49010),v=u(61368),c=u(85498),d=u(46885);let _=(()=>{class p{constructor(e,r,s){this.http=e,this.authService=r,this.languageSwitcher=s}listIssues(e={}){e.scheduled_at_after&&"string"!=typeof e.scheduled_at_after&&(e.scheduled_at_after=e.scheduled_at_after.toISO()),e.scheduled_at_before&&"string"!=typeof e.scheduled_at_before&&(e.scheduled_at_before=e.scheduled_at_before.toISO());const r=new URLSearchParams(e);return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>this.http.get(`${s}/api/v1/issues/?${r}`,t)))}getIssue(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/${e}/`,s)))}updateIssue(e,r){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>this.http.patch(`${s}/api/v1/issues/${e}/`,r,t)))}assignUrgent(e={}){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>{const t=new URLSearchParams(e);return this.http.post(`${r}/api/v1/issues/assign_urgent/?${t}`,{},s)}))}createPayment(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.post(`${r}/api/v1/issues/payment/`,e,s)))}createImage(e,r){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>{const i=`${s}/api/v1/issues/images/`,n=new FormData;return n.append("issue",e),n.append("image",r),t.headers=t.headers.delete("Content-Type"),this.http.post(i,n,t)}))}getImage(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/images/${e}/`,s)))}listImages(e={}){const r=new URLSearchParams(e);return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>this.http.get(`${s}/api/v1/issues/images/?${r}`,t)))}createFile(e,r){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>{const i=`${s}/api/v1/issues/files/`,n=new FormData;return n.append("issue",e),n.append("file",r),t.headers=t.headers.delete("Content-Type"),this.http.post(i,n,t)}))}getFile(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/files/${e}/`,s)))}downloadFile(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/files/${e}/download/`,{...s,responseType:"blob"})))}getSignedFileLink(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/files/${e}/download_link/`,s)))}generatePdf(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/${e}/download/`,{...s,responseType:"blob"})))}getSignedJournalLink(e){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:r,options:s})=>this.http.get(`${r}/api/v1/issues/${e}/download_link/`,s)))}listFiles(e={}){const r=new URLSearchParams(e);return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:s,options:t})=>this.http.get(`${s}/api/v1/issues/files/?${r}`,t)))}listCategories(e={}){return(0,h.D)([this.authService.getOptions(),this.languageSwitcher.getCurrentLocale()]).pipe((0,a.zg)(([{rootUrl:r,options:s},t])=>{const i=new URLSearchParams({language_code:t,...e});return this.http.get(`${r}/api/v1/issues/categories/?${i}`,s)}))}getCategory(e){return(0,h.D)([this.authService.getOptions(),this.languageSwitcher.getCurrentLocale()]).pipe((0,a.zg)(([{rootUrl:r,options:s},t])=>{const i=new URLSearchParams({language_code:t});return this.http.get(`${r}/api/v1/issues/categories/${e}/?${i}`,s)}))}enableCategories(){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:e,options:r})=>this.http.put(`${e}/api/v1/issues/categories/enable/`,{},r)))}disableCategories(){return this.authService.getOptions().pipe((0,a.zg)(({rootUrl:e,options:r})=>this.http.put(`${e}/api/v1/issues/categories/disable/`,{},r)))}filterCategories(e,r){return this.listCategories(r).pipe((0,o.U)(s=>s.map(t=>(t.services=t.services.filter(i=>i.queue===e.queue&&(!e.demography||i.demography===e.demography)&&i.visit_kind===e.visit_kind),t)).filter(t=>t.services.length>0)))}getService(e,r){return(0,h.D)([this.authService.getOptions(),this.languageSwitcher.getCurrentLocale()]).pipe((0,a.zg)(([{rootUrl:s,options:t},i])=>{const n=new URLSearchParams({...r}),$=`${s}/api/v1/services/${e}/?${n}`;return t.headers=t.headers.append("Accept-Language",i),this.http.get($,t)}))}listServices(e={}){return(0,h.D)([this.authService.getOptions(),this.languageSwitcher.getCurrentLocale()]).pipe((0,a.zg)(([{rootUrl:r,options:s},t])=>{const n=`${r}/api/v1/services/?${new URLSearchParams({...e})}`;return s.headers=s.headers.append("Accept-Language",t),this.http.get(n,s)}))}downloadJournal(e){return(0,h.D)([this.authService.getOptions(),this.languageSwitcher.getCurrentLocale()]).pipe((0,a.zg)(([{rootUrl:r},t])=>this.http.get(`${r}/api/v1/issues/document/${e}`,{responseType:"blob"})))}}
1return p.\u0275fac=function(e){return new(e||p)(c.\u0275\u0275inject(d.eN),c.\u0275\u0275inject(l.e),c.\u0275\u0275inject(v.r))},p.\u0275prov=c.\u0275\u0275defineInjectable({token:p,factory:p.\u0275fac,providedIn:"root"}),p})()}}]); 2//# sourceMappingURL=9589.e38f8e60dc8a7194.js.map
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.