1import"./chunk-HPR56E4D.js";import{e as te}from"./chunk-WMRU57XF.js";import"./chunk-R5SKJBW7.js";import"./chunk-5TCV45H4.js";import{a as oe}from"./chunk-NYVDAJB7.js";import"./chunk-GB2WSFFS.js";import{d as ie}from"./chunk-Q4T33MZU.js";import"./chunk-OF3OGEL4.js";import"./chunk-CTKN23UO.js";import{a as Y,c as Z,g as ee}from"./chunk-OOA2KA62.js";import"./chunk-XDDB3LLJ.js";import"./chunk-NCIRC5DM.js";import"./chunk-SKB7ILOS.js";import"./chunk-QMAG4BWY.js";import{a as W}from"./chunk-5K743D74.js";import{a as X}from"./chunk-3CQRRRZV.js";import"./chunk-H6I7XK57.js";import{a as Q}from"./chunk-WPMNZPPL.js";import"./chunk-WGZCF5DN.js";import"./chunk-B275JHVK.js";import"./chunk-YV5QVYWX.js";import{a as H}from"./chunk-5X4PMUIT.js";import"./chunk-D7JDKWT2.js";import"./chunk-C35E7GN7.js";import{b as G}from"./chunk-A567B254.js";import"./chunk-KNNOOAHA.js";import{r as R}from"./chunk-JZXPDQLU.js";import"./chunk-XFNHHABQ.js";import"./chunk-3BQJ62SG.js";import{g as $,h as A}from"./chunk-IH3UVG7Z.js";import{a as q}from"./chunk-GAI4YS2G.js";import{b as K}from"./chunk-OBCWNPG6.js";import{a as B}from"./chunk-LWZ7UAH7.js";import"./chunk-XCHEWPXX.js";import"./chunk-FJJ22O3L.js";import"./chunk-INQP6W3T.js";import"./chunk-ISZ4SYN4.js";import"./chunk-DVUPNCXC.js";import"./chunk-Z363I5P4.js";import"./chunk-VVLCT7WP.js";import"./chunk-T57XMV5N.js";import"./chunk-2YQAHAAN.js";import"./chunk-R7CPL746.js";import{c as V}from"./chunk-ABVTBNVI.js";import"./chunk-XOXRHTDQ.js";import"./chunk-YIID3PB7.js";import"./chunk-Y4RSGNTJ.js";import"./chunk-MEC6NMYA.js";import"./chunk-K5EQQNE4.js";import"./chunk-23JPNHYP.js";import"./chunk-6DW22RYB.js";import"./chunk-MXFX3FXD.js";import{d as N,h as z}from"./chunk-JWKVSGAR.js";import"./chunk-JTSMOHW2.js";import{I as U,g as O,n as E}from"./chunk-BSQE3NDD.js";import{D as S,x as I,z as F}from"./chunk-AG7GDSWE.js";import{Aa as M,Ba as x,Gb as T,Hb as C,Lc as j,Ma as n,Oc as v,Pc as k,_b as y,ac as w,dc as D,ec as P,fc as r,gc as d,hc as p,ic as b,pb as s,qa as _,rc as L,ua as h,xc as f,yd as J,zc as c}from"./chunk-YBFBE3DL.js";import"./chunk-F7VHCFNS.js";var re=(t,m)=>m.id;function de(t,m){if(t&1){let e=L();d(0,"dcds-data-grid",12),f("sortChange",function(i){M(e);let g=c(2);return x(g.onSortChange(i))}),p()}if(t&2){let e=c(2);r("columns",e.columns)("data",e.rows())("sortState",e.sortState())("loading",e.loading())}}function le(t,m){if(t&1&&b(0,"dcds-meta",19),t&2){let e=c().$implicit,o=c(3);r("items",o.getCardMetaFields(e))}}function ce(t,m){if(t&1&&b(0,"dcds-meta",20),t&2){let e=c().$implicit,o=c(3);r("items",o.getListMetaFields(e))}}function me(t,m){if(t&1&&(d(0,"dcds-row",14)(1,"dcds-entity-content",15)(2,"div",16)(3,"h3",17),v(4),p()(),d(5,"div",18),y(6,le,1,1,"dcds-meta",19)(7,ce,1,1,"dcds-meta",20),p()()()),t&2){let e=m.$implicit,o=c(3);r("view",o.viewMode())("noMediaSlot",!0)("interactive",!0)("selectable",!1)("ariaLabel","Job task: "+e.subject),s(),r("listRow",o.viewMode()==="list"),s(3),k(e.subject),s(2),w(o.viewMode()==="grid"?6:7)}}function pe(t,m){if(t&1&&(d(0,"div",13),D(1,me,8,8,"dcds-row",14,re),p()),t&2){let e=c(2);j("configure-jobtasks__row-view--grid",e.viewMode()==="grid"),s(),P(e.rows())}}function ge(t,m){if(t&1&&y(0,de,1,4,"dcds-data-grid",10)(1,pe,3,2,"div",11),t&2){let e=c();w(e.viewMode()==="table"?0:1)}}function ue(t,m){t&1&&b(0,"dcds-empty-state",8),t&2&&r("showButton",!1)}var u=(()=>{class t{constructor(){this.themeService=h(B),this.router=h(F),this.route=h(I),this.jobTaskService=h(ie),this.userId=null,this.rows=n([]),this.page=n(1),this.pageSize=n(25),this.pageSizeOptions=[10,25,50,100],this.totalPages=n(1),this.total=n(0),this.search=n(""),this.loading=n(!1),this.sortState=n({key:"",direction:""}),this.statusMessage=n(""),this.viewMode=n("list"),this.viewOptions=["list","grid","table"],this.listSummary=J(()=>{let e=(this.page()-1)*this.pageSize()+1,o=Math.min(e+this.pageSize()-1,this.total());return this.total()>0?`Showing ${e}-${o} of ${this.total()} job tasks`:"No job tasks match the current search"}),this.columns=[]}ngOnInit(){this.route.params.subscribe(e=>{this.userId=e.userId??null,this.loadPage()}),this.rebuildColumns()}rebuildColumns(){this.columns=[{key:"fullUserName",label:"User",width:"minmax(60px, 0.5fr)",sortable:!0},{key:"subject",label:"Subject",width:"minmax(120px, 0.5fr)",sortable:!0},{key:"body",label:"Message",width:"minmax(0, 1fr)"},{key:"beginDate",label:"Started",width:"minmax(140px, 0.4fr)",sortable:!0},{key:"updatedDate",label:"Updated",width:"minmax(140px, 0.4fr)",sortable:!0},{key:"createdDate",label:"Created",width:"minmax(140px, 0.4fr)",sortable:!0}]}loadPage(){this.loading.set(!0);let e=new N;e.search=this.search(),this.userId&&e.addFilter(z.stringEquals("userId",this.userId));let o=this.sortState(),i=o.key&&o.direction?o.key:null,g=o.key&&o.direction?o.direction:null;this.jobTaskService.search(this.page()-1,this.pageSize(),null,e,i,g,null).subscribe({next:a=>{let se=a.content??[];this.rows.set(se.map(l=>({id:l.id,fullUserName:l.fullUserName??"\u2014",subject:l.subject??"\u2014",body:l.body??"",beginDate:l.beginDate?new Date(l.beginDate).toLocaleStr
1ing():"\u2014",updatedDate:l.updateDate?new Date(l.updateDate).toLocaleString():"\u2014",createdDate:l.createdDate?new Date(l.createdDate).toLocaleString():"\u2014"}))),this.totalPages.set(a.page?.totalPages??1),this.total.set(a.page?.totalElements??0),this.loading.set(!1)},error:a=>{console.error("Error loading job tasks",a),this.rows.set([]),this.loading.set(!1)}})}onSearchChange(e){this.search.set(e),this.page.set(1),this.loadPage()}onPageChange(e){this.page.set(e),this.loadPage()}onPageSizeChange(e){this.pageSize.set(e),this.page.set(1),this.loadPage()}onSortChange(e){let o=this.sortState(),i=o.key===e&&o.direction==="asc"?"desc":"asc";this.sortState.set({key:e,direction:i}),this.page.set(1),this.loadPage()}onViewModeChange(e){this.viewMode.set(e==="list"||e==="grid"||e==="table"?e:"list")}getCardMetaFields(e){return[{key:"message",label:"Message",value:e.body||"\u2014"},{key:"user",label:"User",value:e.fullUserName},{key:"started",label:"Started",value:e.beginDate},{key:"updated",label:"Updated",value:e.updatedDate}]}getListMetaFields(e){return[{key:"message",label:"Message",value:e.body||"\u2014"},{key:"user",label:"User",value:e.fullUserName},{key:"started",label:"Started",value:e.beginDate},{key:"updated",label:"Updated",value:e.updatedDate}]}static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275cmp=T({type:t,selectors:[["dc-list-jobtask"]],decls:13,vars:16,consts:[[1,"p-4"],["dcdsPageTemplateHeader","","eyebrow","Configure","title","Job Tasks","description","Monitor background job tasks queued and processed across the system.",3,"count"],["description","Browse all queued and completed job tasks, search by subject or user, and review task details.","ariaLabel","Job tasks data view"],["dcdsAdminCollectionToolbar","","ariaLabel","Job tasks controls","defaultView","list","persistenceKey","job-tasks",3,"viewChange","summary","showPagination","showPageSize","showViewToggle","useBuiltInViewToggle","viewOptions","currentView"],["listControlsPagination","","mode","table",3,"pageChange","pageSizeChange","currentPage","totalPages","pageSize","totalItems","pageSizeOptions"],["listControlsSearch","","density","compact"],["format","complex","placeholder","Search job tasks","ariaLabel","Search job tasks",3,"ngModelChange","ngModel"],["dcdsAdminCollectionBody",""],["title","No job tasks found","description","Try a different search term or clear the current query.",3,"showButton"],["aria-live","polite",1,"configure-jobtasks__status"],["trackByKey","id","density","admin","ariaLabel","Job task records",3,"columns","data","sortState","loading"],[1,"configure-jobtasks__row-view",3,"configure-jobtasks__row-view--grid"],["trackByKey","id","density","admin","ariaLabel","Job task records",3,"sortChange","columns","data","sortState","loading"],[1,"configure-jobtasks__row-view"],["density","compact",3,"view","noMediaSlot","interactive","selectable","ariaLabel"],[3,"listRow"],["entityTitle",""],[1,"dcds-entity-title"],["entityMetadata",""],["layout","labeled","density","compact","ariaLabel","Job task details",3,"items"],["layout","inline","density","compact","ariaLabel","Job task details",3,"items"]],template:function(o,i){o&1&&(d(0,"main",0)(1,"dcds-page-template-list"),b(2,"dcds-page-header",1),d(3,"dcds-admin-collection-shell",2)(4,"dcds-list-controls",3),f("viewChange",function(a){return i.onViewModeChange(a)}),d(5,"dcds-pagination",4),f("pageChange",function(a){return i.onPageChange(a)})("pageSizeChange",function(a){return i.onPageSizeChange(a)}),p(),d(6,"dcds-field",5)(7,"dcds-text-input",6),f("ngModelChange",function(a){return i.onSearchChange(a)}),p()()(),d(8,"div",7),y(9,ge,2,1)(10,ue,1,1,"dcds-empty-state",8),p()(),d(11,"p",9),v(12),p()()()),o&2&&(s(2),r("count",i.total()),s(2),r("summary",i.listSummary())("showPagination",!0)("showPageSize",!1)("showViewToggle",!0)("useBuiltInViewToggle",!0)("viewOptions",i.viewOptions)("currentView",i.viewMode()),s(),r("currentPage",i.page())("totalPages",i.totalPages())("pageSize",i.pageSize())("totalItems",i.total())("pageSizeOptions",i.pageSizeOptions),s(2),r("ngModel",i.search()),s(2),w(i.rows().length?9:10),s(3),k(i.statusMessage()))},dependencies:[U,O,E,te,oe,q,K,W,X,H,V,ee,Z,Q,Y],styles:[".configure-jobtasks__row-view[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.configure-jobtasks__row-view--grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr))}dcds-data-grid[_ngcontent-%COMP%]{--dcds-data-grid-row-min-inline-size: 100%}.configure-jobtasks__body-text[_ngcontent-%COMP%]{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;color:var(--dcds-color-text-secondary, var(--text-secondary));font-size:var(--dcds-font-size-sm, .875rem)}.configure-jobtasks__date-empty[_ngcontent-%COMP%]{color:var(--dcds-color-text-tertiary, var(--text-tertiary))}"]})}}return t})();var he=[{path:"",component:A,data:{activeTab:$.CONFIGURE_JOBS,routeCategory:["Configure","Jobs"]},children:[{path:"",component:u},{path:"list",component:u},{path:"user/:userId",component:u}]}],ne=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=C({type:t})}static{this.\u0275inj=_({imports:[S.forChild(he),S]})}}return t})();var He=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=C({type:t})}static{this.\u0275inj=_({imports:[R,G,ne,u]})}}return t})();export{He as JobTaskModule};
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.