import{a as p}from"./chunk-ABXDWOZI.js";import"./chunk-4NGHU5PZ.js";import"./chunk-NWOU67BD.js";import"./chunk-TBSUMTHM.js";import"./chunk-CKJJI5MU.js";import"./chunk-TAT3HGQ4.js";import"./chunk-4SWKWV3M.js";import"./chunk-DY645AKB.js";import"./chunk-5I5ZFUTL.js";import"./chunk-QN66BDDM.js";import"./chunk-JBNKEIUX.js";import"./chunk-5SW267PH.js";import"./chunk-PU7DBJLZ.js";import"./chunk-3DDBG3AR.js";import"./chunk-5MLUVH77.js";import"./chunk-SMMBZMNL.js";import"./chunk-S5GA3KRV.js";import"./chunk-EFONMPAR.js";import"./chunk-YQXLYYOT.js";import"./chunk-6RITFGP2.js";import"./chunk-HGXDKXJP.js";import"./chunk-WQUXAKOL.js";import"./chunk-LYNKRDJC.js";import"./chunk-SKY4LXUD.js";import"./chunk-BZT47AWD.js";import"./chunk-5WQBRAHK.js";import"./chunk-4FTRQKHH.js";import"./chunk-BYXBJQAS.js";import"./chunk-TTWRMELT.js";import"./chunk-EMJ4QQUL.js";import"./chunk-QPCAJSKO.js";import"./chunk-QV67LFVX.js";import"./chunk-4O3FVBGX.js";import"./chunk-TGWIHQDX.js";import"./chunk-Q5KZV54I.js";import"./chunk-YHVRQUSB.js";import"./chunk-N7PBPSN6.js";import"./chunk-3Z7PXZF3.js";import"./chunk-43BLBOSI.js";import"./chunk-IWSLIKCG.js";import"./chunk-2DXJE6G7.js";import"./chunk-7RP244JU.js";import"./chunk-LHGSJXTX.js";import"./chunk-ZKNPBXGB.js";import{b as c}from"./chunk-S3ADKFO2.js";import"./chunk-I5MYHHJE.js";import{Fb as l,Gb as n,Hb as r,Wb as d,Xb as m,gb as s,lb as a}from"./chunk-CKLXM6EG.js";import"./chunk-TSRGIXR5.js";var h=[[["","test",""]]],y=["[test]"],u=class o{constructor(i){this.translate=i;this.buildHighlightStyles(),this.translate.onLangChange.subscribe(()=>{this.buildHighlightStyles()})}itemss;floorsHeaders=["id","employee_code","full_name","email","position","department.name","created_at","last_update","is_active.value"];tableHighlightedFields={};activeStyle={color:"#1D8702",backgroundColor:"#1D870214",fontWeight:"bold",padding:"10px",borderRadius:"5px",whiteSpace:"nowrap"};inactiveStyle={color:"red",backgroundColor:"#DA303014",fontWeight:"bold",padding:"10px",borderRadius:"5px",whiteSpace:"nowrap"};otherStyle={color:"grey",backgroundColor:"#1f028709",fontWeight:"bold",padding:"10px",borderRadius:"5px",whiteSpace:"nowrap"};fields=[{type:"input",title:"code",controlName:"code"},{type:"input",title:"name",controlName:"name"}];titlesOfMenu=[{label:"show",action:"show",routerLink:"/my-team/show-employee"},{label:"edit",action:"edit",routerLink:"/my-team/edit-employee"},{label:"delete",action:"delete",permission:"delete purchase_employees"}];buildHighlightStyles(){let i=this.translate.instant("status.active");console.log(i,"ACTIVE");let e=this.translate.instant("status.Not Active");this.tableHighlightedFields={"is_active.value":{fieldToCheck:"is_active.value",stylesByValue:{[i]:this.activeStyle,[e]:this.inactiveStyle,__other__:this.otherStyle}}}}Field;ngOnInit(){this.Field=[{type:"dateWithOptions",title:"date_range",controlName:"date",fromControlName:"from",toControlName:"to",showQuickButtons:!0,class:"col-6",parentClass:"col-8"},{type:"select",title:"status",class:"col-4",options:[{name:this.translate.instant("status.active"),id:1},{name:this.translate.instant("status.Not Active"),id:7},{name:this.translate.instant("status.Suspended"),id:5}],controlName:"is_active"}]}static \u0275fac=function(e){return new(e||o)(s(c))};static \u0275cmp=a({type:o,selectors:[["app-employees-list"]],ngContentSelectors:y,decls:2,vars:17,consts:[["routeOfButton2","/my-team/add-employee","titleOfButton2","add_employee","url","procurement/employees/list","translationPrefixx","my-team","title","my-team","deleteRowUrl","procurement/employees/delete","classesForTable","designOne","iconOfBtn2","fa-solid fa-plus","translationPrefix","my-team",3,"ShowButton","Menu","showIconORTITLE","filterKeyData","ShowModal","menuList","headers","titleOfPage","showMenubar","ShowButton3","showFilter","tableHighlightedFields","showTitle","showBreadcrumb","useCustomStatusStyling","filterSearchField"]],template:function(e,t){e&1&&(d(h),n(0,"app-page-body",0),m(1),r()),e&2&&l("ShowButton",!1)("Menu",t.titlesOfMenu)("showIconORTITLE",!0)("filterKeyData",t.floorsHeaders)("ShowModal",!1)("menuList",t.itemss)("headers",t.floorsHeaders)("titleOfPage","my-team")("showMenubar",!0)("ShowButton3",!0)("showFilter",!0)("ShowButton",!0)("tableHighlightedFields",t.tableHighlightedFields)("showTitle",!0)("showBreadcrumb",!0)("useCustomStatusStyling",!1)("filterSearchField",t.Field)},dependencies:[p],encapsulation:2})};export{u as EmployeesList};
