@studio-west/employees 0.5.32 → 0.5.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/WorkTable.cjs +3 -3
- package/dist/WorkTable.js +55 -53
- package/package.json +1 -1
package/dist/WorkTable.cjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),ie=require("file-saver"),de=require("exceljs"),c=require("./index-DxdyeKnm.cjs"),se=require("vue-i18n"),i=require("element-plus"),
|
|
2
|
-
`+(h-1),l.getColumn(h).width=6,l.getColumn(h).alignment=t,l.getCell(4,h).border=d;l.getRow(1).height=40,l.getRow(2).height=30,l.getRow(3).height=20,l.getColumn(1).width=15,l.getColumn(u.value.length+2).width=5,l.getColumn(u.value.length+3).width=6,l.getColumn(u.value.length+4).width=13,l.getColumn(u.value.length+5).width=13,l.getColumn(1).alignment=t,l.getCell("A2").alignment=o,l.getCell("A3").alignment=o,l.getCell("B3").alignment=o,l.getCell(3,u.value.length+2).alignment=o,l.getColumn(u.value.length+2).alignment=t,l.getColumn(u.value.length+3).alignment=t,l.getColumn(u.value.length+4).alignment=o,l.getColumn(u.value.length+5).alignment=o,l.getCell("A3").border=d,l.getCell("B3").border=d,l.getCell(3,u.value.length+2).border=d,l.getCell(4,u.value.length+2).border=d,l.getCell(3,u.value.length+4).border=d,l.getCell(3,u.value.length+5).border=d,l.getCell(4,u.value.length+3).border=d;let s=0;for(const h of n.value){let Y=[h.name];for(let T=1;T<=u.value.length;T++){const{ind:
|
|
3
|
-
`+t.day.toString()
|
|
1
|
+
"use strict";const e=require("vue"),ie=require("file-saver"),de=require("exceljs"),c=require("./index-DxdyeKnm.cjs"),se=require("vue-i18n"),i=require("element-plus"),W=require("@imengyu/vue3-context-menu");function ce(k){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(k){for(const C in k)if(C!=="default"){const f=Object.getOwnPropertyDescriptor(k,C);Object.defineProperty(r,C,f.get?f:{enumerable:!0,get:()=>k[C]})}}return r.default=k,Object.freeze(r)}const ve=ce(de),me={class:"work"},ge={class:"nav"},he={style:{height:"100px",width:"100%",display:"inline-block"}},fe=["innerHTML"],pe={key:0,class:"controls-container",style:{"margin-top":".5rem"}},ye={key:0,style:{padding:"0.5em 1.5em"}},we={key:1,style:{padding:"0.5em 1.5em"}},ke={__name:"WorkTable",props:{checkEdit:{type:Boolean,default:()=>!0},odata:Object,workSchedule:Object,fullName:{type:String,default:"Вы"}},setup(k){const{t:r,d:C}=se.useI18n(),f=k,M=e.ref(!1),n=e.ref([]),H=e.ref(new Date().getMonth()+1),L=e.ref(!1),b=e.ref([]),w=e.ref(new Date(new Date().getFullYear(),new Date().getMonth(),1)),u=e.ref([]),A=e.ref(0),x=e.ref(9),p=e.ref(8),I=e.ref(!1),G=e.ref(!0),E=e.ref(!1),R=e.ref("5"),$=e.ref(1),V=e.ref(""),j=e.ref([]),S=e.ref([]),z=e.ref([]),v=e.ref({name:"Имя",length:0,code:""}),F=e.ref(!1),q=e.ref({zIndex:30,minWidth:220,x:500,y:200}),J=e.ref({}),D=e.ref("100%");e.watch(V,async(a,l)=>{a!==l&&(S.value=[],I.value=!1,f.odata.personal.forEach(o=>{o.divisionName===a&&(S.value.some(d=>(d==null?void 0:d.activeText)===o.roleName)||S.value.push({val:!0,activeText:o.roleName}))}),O())}),e.watch(H,async a=>{let l=new Date().getMonth(),o=a===null?l:a-1;o=l-1<=o?o:o+12,w.value=new Date(new Date().getFullYear(),o,1),Z()});const _=(a,l,o,d)=>{v.value.ids=a.ids,v.value.key=a.key,v.value.add=a.days.length>0&&a.days[a.days.length-1].cont,v.value.level=l.level,v.value.day=o.cellIndex,q.value.y=d.clientY,q.value.x=d.clientX,l.level===2&&l.no===0&&f.checkEdit&&(v.value.name=r("workSchedule.autocomplete"),F.value=!0),l.level===3&&o.cellIndex-l.no===1&&f.checkEdit&&(N(o.cellIndex,a.ids),v.value.name=r("workSchedule.modeSelection"),F.value=!0)},ee=a=>{console.log(a);let l="ee";if(a="2025.04.21",!b.value||b.value.length===0)return"";const o=new Date(c.parseDate(a)).getTime();for(let d of b.value){const{dateStart:t,dateEnd:s,code:g}=d;if(t&&s&&g===l){const m=new Date(c.parseDate(t)).getTime(),y=new Date(c.parseDate(s)).getTime();if(o>=m&&o<=y)return"vacation"}}return""},Z=()=>{const a=J.value,l=new Date(w.value),o=new Date(l.getFullYear(),l.getMonth()+1,0).getDate();let d=[],t=0;for(let s=1;s<=o;s++){const g=c.parseTime(l.setDate(s),"{Y}-{m}-{dd}");t+=a.nowork.includes(g)||a.holidays.includes(g)?0:a.preholidays.includes(g)?7:8;const m=a.nowork.includes(g)?"nowork":a.holidays.includes(g)?"holiday":a.preholidays.includes(g)?"preholiday":"";d.push({day:s,holidays:m,weekday:C(new Date(l.getFullYear(),l.getMonth(),s),"day")})}A.value=t,u.value=d,f.odata.getPersonal({}).then(s=>{var g;V.value.length===0&&(V.value=(g=s.find(m=>m.employeeName===f.fullName))==null?void 0:g.divisionName),s.forEach(m=>{j.value.some(y=>(y==null?void 0:y.value)===m.divisionName)||j.value.push({value:m.divisionName,label:m.divisionName,key:m.divisionName}),m.divisionName===V.value&&!S.value.some(y=>(y==null?void 0:y.activeText)===m.roleName)&&S.value.push({val:!0,activeText:m.roleName})}),O(),G.value=!1})},K=(a,l)=>{var s,g,m;const o=new Date(w.value),d=`${o.getFullYear()}-${(o.getMonth()+1).toString().padStart(2,"0")}-${a.toString().padStart(2,"0")}`,t=(s=n.value[l])==null?void 0:s.days.findIndex(y=>y.day===d);return l===-1||t===-1?"":((g=n.value[l].days[t])==null?void 0:g.tips)+"<br>"+((m=n.value[l].days[t])==null?void 0:m.time)},O=()=>{n.value=[],z.value=[],b.value=[],f.odata.personal.forEach(a=>{if(a.divisionName===V.value&&S.value.some(l=>l.val&&l.activeText===a.roleName)){let l=c.byInitials(a.employeeName);z.value.push(a.employeeKey),n.value.push({name:l+" ("+a.roleName+")",days:[],contHour:0,code:a.employeeKey,id:!1,ids:n.value.length})}}),f.workSchedule.getUsersYear({code:z.value,year:new Date(w.value).getFullYear()}).then(a=>{a.forEach(l=>{l.dateStart&&b.value.push({code:l.code,dateStart:l.dateStart,dateEnd:l.dateEnd})}),console.log(a),le(),E.value=!1})},le=()=>{f.workSchedule.getWorkSchedule({code:z.value,date:c.parseTime(new Date(w.value),"{Y}-{m}-{dd}")}).then(a=>{a.forEach((l,o)=>{l!==null&&(n.value[o].days=l.data.days,n.value[o].id=l.id)}),B()})},B=()=>{n.value.forEach(a=>{a.contHour=a.days.reduce((l,o)=>l+o.time,0)})},te=a=>{n.value[a].days=[],B()},ae=a=>{switch(R.value){case"5":for(let l=$.value;l<=u.value.length;l++)u.value[l-1].holidays===""&&N(l,a,!0),u.value[l-1].holidays==="preholiday"&&(p.value-=1,N(l,a,!0),p.value+=1);break;case"2x2":for(let l=$.value;l<=u.value.length;l+=4)N(l,a,!0),l+1<=u.value.length&&N(l+1,a,!0);break;case"2x5":for(let l=$.value;l<=u.value.length;l+=7)for(let o=l;o<l+5&&o<=u.value.length;o++)u.value[o-1].holidays==="preholiday"?(p.value-=1,N(o,a,!0),p.value+=1):N(o,a,!0);break}},N=(a,l,o=!1)=>{const{date:d,ind:t}=U(a,l);t===-1?(n.value[l].days.push({day:d,time:p.value,tips:`(${x.value}:00 - ${x.value+p.value+1}:00)`}),B()):o||(p.value=n.value[l].days[t].time,x.value=parseInt(n.value[l].days[t].tips.slice(1,-12)))},ne=(a,l)=>{const{ind:o}=U(a,l);n.value[l].days.splice(o,1),B(),document.querySelector(".app-main").click()},Q=(a,l)=>{const{date:o,ind:d}=U(a,l);n.value[l].days[d]={day:o,time:p.value,tips:`(${x.value}:00 - ${x.value+p.value+1}:00)`},B()},U=(a,l)=>{var t;const o=c.parseTime(new Date(w.value).setDate(a),"{Y}-{m}-{dd}"),d=(t=n.value[l])==null?void 0:t.days.findIndex(s=>s.day===o);return{date:o,ind:d}},oe=async()=>{var X;M.value=!0;const a=new ve.Workbook,l=a.addWorksheet(C(w.value,"month"),{pageSetup:{paperSize:9,orientation:"landscape",fitToPage:!0}}),o={vertical:"middle",horizontal:"center"},d={top:{style:"thin"},left:{style:"thin"},bottom:{style:"thin"},right:{style:"thin"}},t={vertical:"middle",horizontal:"center",wrapText:!0};l.mergeCells(`A1:${c.cellsDynamically("A1",u.value.length+5)}1`),l.mergeCells(`A2:${c.cellsDynamically("A2",u.value.length+5)}2`),l.mergeCells("A3:A4"),l.mergeCells(`B3:${c.cellsDynamically("B3",u.value.length)}3`),l.mergeCells(`${c.cellsDynamically("B3",u.value.length+1)}3:${c.cellsDynamically("B3",u.value.length+2)}3`),l.mergeCells(`${c.cellsDynamically("B3",u.value.length+3)}3:${c.cellsDynamically("B4",u.value.length+3)}4`),l.mergeCells(`${c.cellsDynamically("B3",u.value.length+4)}3:${c.cellsDynamically("B4",u.value.length+4)}4`),l.getCell("A1").value=r("workSchedule.firm"),l.getCell("A2").value=r("workSchedule.title",{name:V.value})+C(w.value,"month")+` ${new Date(w.value).getFullYear()}`,l.getCell("A3").value=r("workSchedule.month"),l.getCell("B3").value=r("workSchedule.numbersMonth"),l.getCell(3,u.value.length+2).value=r("workSchedule.onSchedule"),l.getCell(3,u.value.length+4).value=r("workSchedule.acquainted"),l.getCell(3,u.value.length+5).value=r("workSchedule.date"),l.getCell(4,u.value.length+2).value=r("workSchedule.days"),l.getCell(4,u.value.length+3).value=`${r("workSchedule.hours")} (${A.value})`;for(let h=2;h<=u.value.length+1;h++)l.getCell(4,h).value=u.value[h-2].weekday+`
|
|
2
|
+
`+(h-1),l.getColumn(h).width=6,l.getColumn(h).alignment=t,l.getCell(4,h).border=d;l.getRow(1).height=40,l.getRow(2).height=30,l.getRow(3).height=20,l.getColumn(1).width=15,l.getColumn(u.value.length+2).width=5,l.getColumn(u.value.length+3).width=6,l.getColumn(u.value.length+4).width=13,l.getColumn(u.value.length+5).width=13,l.getColumn(1).alignment=t,l.getCell("A2").alignment=o,l.getCell("A3").alignment=o,l.getCell("B3").alignment=o,l.getCell(3,u.value.length+2).alignment=o,l.getColumn(u.value.length+2).alignment=t,l.getColumn(u.value.length+3).alignment=t,l.getColumn(u.value.length+4).alignment=o,l.getColumn(u.value.length+5).alignment=o,l.getCell("A3").border=d,l.getCell("B3").border=d,l.getCell(3,u.value.length+2).border=d,l.getCell(4,u.value.length+2).border=d,l.getCell(3,u.value.length+4).border=d,l.getCell(3,u.value.length+5).border=d,l.getCell(4,u.value.length+3).border=d;let s=0;for(const h of n.value){let Y=[h.name];for(let T=1;T<=u.value.length;T++){const{ind:P}=U(T,s);P!==-1?Y[T]=`${h.days[P].time} ${h.days[P].tips}`:Y[T]=" "}Y.push(((X=h.days)==null?void 0:X.length)||" ",h.contHour||0);const re=l.addRow(Y);re.border=d,s++}let g="Щербина Е. В.";f.odata.personal.forEach(h=>{h.roleName==="Начальник отдела правовой и кадровой работы"&&(g=h.employeeName)}),l.mergeCells(`A${n.value.length+6}:P${n.value.length+6}`),l.mergeCells(`Q${n.value.length+6}:AG${n.value.length+6}`),l.mergeCells(`B${n.value.length+8}:E${n.value.length+8}`),l.mergeCells(`F${n.value.length+8}:L${n.value.length+8}`),l.mergeCells(`M${n.value.length+8}:P${n.value.length+8}`),l.mergeCells(`S${n.value.length+8}:V${n.value.length+8}`),l.mergeCells(`W${n.value.length+8}:AC${n.value.length+8}`),l.mergeCells(`AD${n.value.length+8}:AG${n.value.length+8}`),l.mergeCells(`Z${n.value.length+9}:AA${n.value.length+9}`),l.getCell(`A${n.value.length+6}`).value=r("workSchedule.byInitials"),l.getCell(`Q${n.value.length+6}`).value=r("workSchedule.supervisorHR"),l.getCell(`B${n.value.length+8}`).value=r("workSchedule.compiled")+":",l.getCell(`S${n.value.length+8}`).value=r("workSchedule.approved")+":",l.getCell(`M${n.value.length+8}`).value=c.byInitials(f.fullName),l.getCell(`AD${n.value.length+8}`).value=c.byInitials(g),l.getCell(`Z${n.value.length+9}`).value=r("workSchedule.printPlace"),l.getCell(`A${n.value.length+6}`).alignment={vertical:"middle",horizontal:"right"},l.getCell(`Q${n.value.length+6}`).alignment={vertical:"middle",horizontal:"right"},l.getCell(`B${n.value.length+8}`).alignment={vertical:"middle",horizontal:"right"},l.getCell(`F${n.value.length+8}`).alignment={vertical:"middle",horizontal:"right"},l.getCell(`M${n.value.length+8}`).alignment={vertical:"middle",horizontal:"left"},l.getCell(`AD${n.value.length+8}`).alignment={vertical:"middle",horizontal:"left"},l.getCell(`Z${n.value.length+9}`).alignment=o,l.getCell(`F${n.value.length+8}`).border={bottom:{style:"thin"}},l.getCell(`W${n.value.length+8}`).border={bottom:{style:"thin"}};const m="export_"+c.parseTime(Date.now(),"{dd}.{m}.{Y}")+".xlsx",y=await a.xlsx.writeBuffer();ie.saveAs(new Blob([y]),m),M.value=!1},ue=async()=>{I.value||f.workSchedule.addWorkSchedule({data:n.value,date:c.parseTime(new Date(w.value),"{Y}-{m}-{dd}")}).then(a=>I.value=a)};return c.holidays().then(a=>{J.value=a,Z()}),(a,l)=>{const o=e.resolveComponent("el-date-picker"),d=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock("div",me,[e.createElementVNode("div",ge,[k.checkEdit?(e.openBlock(),e.createBlock(e.unref(i.ElSelect),{key:0,modelValue:V.value,"onUpdate:modelValue":l[0]||(l[0]=t=>V.value=t),placeholder:"Select",style:{width:"240px"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(j.value,t=>(e.openBlock(),e.createBlock(e.unref(i.ElOption),{key:t.value,label:t.label,value:t.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])):e.createCommentVNode("",!0),k.checkEdit?(e.openBlock(),e.createBlock(e.unref(i.ElButton),{key:1,plain:"",onClick:l[1]||(l[1]=t=>E.value=!0)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.jobTitle")),1)]),_:1})):e.createCommentVNode("",!0),e.createVNode(o,{modelValue:H.value,"onUpdate:modelValue":l[2]||(l[2]=t=>H.value=t),type:"month",placeholder:"Выберите месяц",format:"MMM","value-format":"M"},null,8,["modelValue"]),l[19]||(l[19]=e.createElementVNode("div",{class:"expander"},null,-1)),e.createVNode(e.unref(i.ElSwitch),{modelValue:D.value,"onUpdate:modelValue":l[3]||(l[3]=t=>D.value=t),"active-text":a.$t("bids.currentHeight"),"active-value":"100%","inactive-value":"calc(100vh - var(--el-component-size)*4 - var(--el-main-padding)*2 - var(--header-height))"},null,8,["modelValue","active-text"]),e.createVNode(e.unref(i.ElSwitch),{modelValue:L.value,"onUpdate:modelValue":l[4]||(l[4]=t=>L.value=t),"active-text":"Отпуска","active-value":!0,"inactive-value":!1},null,8,["modelValue"])]),e.createVNode(e.unref(i.ElSkeleton),{style:{width:"100%"},loading:G.value,animated:""},{template:e.withCtx(()=>[e.createVNode(e.unref(i.ElSkeletonItem),{variant:"text",style:{width:"100%",height:"2rem"}}),e.createVNode(e.unref(i.ElSkeletonItem),{variant:"text",style:{width:"180px",height:"4rem","margin-right":"4px"}}),e.createVNode(e.unref(i.ElSkeletonItem),{variant:"text",style:{width:"calc( 100% - 184px)",height:"4rem"}}),e.createVNode(e.unref(i.ElSkeletonItem),{variant:"text",style:{width:"180px",height:"8rem","margin-right":"4px"}}),e.createVNode(e.unref(i.ElSkeletonItem),{variant:"text",style:{width:"calc( 100% - 184px)",height:"8rem"}})]),default:e.withCtx(()=>[e.createVNode(e.unref(i.ElTable),{id:"printTable",data:n.value,style:{width:"100%"},"max-height":D.value,size:"small",align:"center",onCellClick:_,"empty-text":e.unref(r)("workSchedule.emptyText"),"cell-class-name":ee()},{default:e.withCtx(()=>[e.createVNode(e.unref(i.ElTableColumn),{label:e.unref(r)("workSchedule.title",{name:V.value})+e.unref(C)(w.value,"month")+` ${new Date(w.value).getFullYear()}`,align:"center",height:"34"},{default:e.withCtx(()=>[e.createVNode(e.unref(i.ElTableColumn),{label:e.unref(r)("workSchedule.month"),width:"180",align:"center",fixed:D.value!=="100%"},{default:e.withCtx(t=>[e.createElementVNode("div",he,e.toDisplayString(n.value[t.$index].name),1)]),_:1},8,["label","fixed"]),e.createVNode(e.unref(i.ElTableColumn),{label:e.unref(r)("workSchedule.numbersMonth"),align:"center"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,t=>(e.openBlock(),e.createBlock(e.unref(i.ElTableColumn),{key:t.day,width:"46","class-name":t.holidays,align:"center",label:t.weekday+`
|
|
3
|
+
`+t.day.toString()},{default:e.withCtx(s=>[e.createElementVNode("div",{style:{height:"100px",width:"100%",display:"inline-block"},innerHTML:K(t.day,s.$index)||" "},null,8,fe)]),_:2},1032,["class-name","label"]))),128))]),_:1},8,["label"]),e.createVNode(e.unref(i.ElTableColumn),{label:e.unref(r)("workSchedule.onSchedule"),align:"center",fixed:D.value!=="100%"?"right":!1},{default:e.withCtx(()=>[e.createVNode(e.unref(i.ElTableColumn),{label:e.unref(r)("workSchedule.days"),align:"center"},{default:e.withCtx(t=>[e.createTextVNode(e.toDisplayString(n.value[t.$index].days.length||0),1)]),_:1},8,["label"]),e.createVNode(e.unref(i.ElTableColumn),{label:`${e.unref(r)("workSchedule.hours")} ( ${A.value} )`,align:"center"},{default:e.withCtx(t=>[e.createElementVNode("div",{style:e.normalizeStyle(`color: ${A.value===t.row.contHour?"green":"red"};`)},e.toDisplayString(t.row.contHour),5)]),_:1},8,["label"])]),_:1},8,["label","fixed"])]),_:1},8,["label"])]),_:1},8,["data","max-height","empty-text","cell-class-name"])]),_:1},8,["loading"]),k.checkEdit?(e.openBlock(),e.createElementBlock("div",pe,[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.chartsFilled"))+": ",1),I.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(i.ElButton),{key:0,type:"primary",onClick:ue},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.confirm")),1)]),_:1})),l[20]||(l[20]=e.createTextVNode()),e.createElementVNode("span",null,e.toDisplayString(k.fullName),1)])):e.createCommentVNode("",!0),e.withDirectives((e.openBlock(),e.createBlock(e.unref(i.ElButton),{disabled:M.value,plain:"",onClick:oe,style:{"margin-top":".5rem"}},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.exportExcel")),1)]),_:1},8,["disabled"])),[[d,M.value]]),e.createVNode(e.unref(i.ElDialog),{title:e.unref(r)("workSchedule.jobTitle"),modelValue:E.value,"onUpdate:modelValue":l[6]||(l[6]=t=>E.value=t),width:"400px"},{footer:e.withCtx(()=>[e.createVNode(e.unref(i.ElButton),{onClick:l[5]||(l[5]=t=>E.value=!1),size:"default"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.$t("workSchedule.cancel")),1)]),_:1}),e.createVNode(e.unref(i.ElButton),{size:"default",type:"primary",onClick:O},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.$t("workSchedule.select")),1)]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(i.ElForm),{ref:"dialogForm",model:S.value,autocomplete:"on"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,t=>(e.openBlock(),e.createBlock(e.unref(i.ElFormItem),null,{default:e.withCtx(()=>[e.createVNode(e.unref(i.ElSwitch),{modelValue:t.val,"onUpdate:modelValue":s=>t.val=s,"active-text":t.activeText},null,8,["modelValue","onUpdate:modelValue","active-text"])]),_:2},1024))),256))]),_:1},8,["model"])]),_:1},8,["title","modelValue"]),e.createVNode(e.unref(W.ContextMenu),{show:F.value,"onUpdate:show":l[18]||(l[18]=t=>F.value=t),options:q.value},{default:e.withCtx(()=>[e.createVNode(e.unref(W.ContextMenuItem),{label:v.value.name,disabled:""},null,8,["label"]),e.createVNode(e.unref(W.ContextMenuSeparator)),v.value.level===2?(e.openBlock(),e.createElementBlock("div",ye,[e.createVNode(e.unref(i.ElRadioGroup),{modelValue:R.value,"onUpdate:modelValue":l[7]||(l[7]=t=>R.value=t),size:"small"},{default:e.withCtx(()=>[e.createVNode(e.unref(i.ElRadioButton),{label:e.unref(r)("workSchedule.Days5"),value:"5"},null,8,["label"]),e.createVNode(e.unref(i.ElRadioButton),{label:"2 Х 2",value:"2x2"}),e.createVNode(e.unref(i.ElRadioButton),{label:"2 Х 5",value:"2x5"})]),_:1},8,["modelValue"]),l[21]||(l[21]=e.createElementVNode("br",null,null,-1)),e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("workSchedule.fromDate"))+":",1),e.createVNode(e.unref(i.ElSlider),{modelValue:$.value,"onUpdate:modelValue":l[8]||(l[8]=t=>$.value=t),step:1,min:1,max:u.value.length},null,8,["modelValue","max"]),e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("workSchedule.with"))+":",1),e.createVNode(e.unref(i.ElSlider),{modelValue:x.value,"onUpdate:modelValue":l[9]||(l[9]=t=>x.value=t),step:1,min:8,max:11},null,8,["modelValue"]),e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("workSchedule.duration"))+":",1),e.createVNode(e.unref(i.ElSlider),{modelValue:p.value,"onUpdate:modelValue":l[10]||(l[10]=t=>p.value=t),step:1,min:4,max:12},null,8,["modelValue"]),e.createVNode(e.unref(i.ElButton),{style:{"margin-top":".5rem"},size:"small",onClick:l[11]||(l[11]=t=>ae(v.value.ids))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.fillOut")),1)]),_:1}),e.createVNode(e.unref(i.ElButton),{style:{"margin-top":".5rem"},size:"small",onClick:l[12]||(l[12]=t=>te(v.value.ids))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.clearRow")),1)]),_:1})])):(e.openBlock(),e.createElementBlock("div",we,[e.createElementVNode("div",null,e.toDisplayString(K(v.value.day,v.value.ids)),1),l[22]||(l[22]=e.createElementVNode("br",null,null,-1)),e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("workSchedule.with"))+":",1),e.createVNode(e.unref(i.ElSlider),{modelValue:x.value,"onUpdate:modelValue":l[13]||(l[13]=t=>x.value=t),step:1,min:8,max:11,onChange:l[14]||(l[14]=t=>Q(v.value.day,v.value.ids))},null,8,["modelValue"]),e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("workSchedule.duration"))+":",1),e.createVNode(e.unref(i.ElSlider),{modelValue:p.value,"onUpdate:modelValue":l[15]||(l[15]=t=>p.value=t),step:1,min:4,max:12,onChange:l[16]||(l[16]=t=>Q(v.value.day,v.value.ids))},null,8,["modelValue"]),e.createVNode(e.unref(i.ElButton),{style:{"margin-top":".5rem"},size:"small",onClick:l[17]||(l[17]=t=>ne(v.value.day,v.value.ids))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)("workSchedule.delete")),1)]),_:1})]))]),_:1},8,["show","options"])])}}};module.exports=ke;
|
package/dist/WorkTable.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { ref as v, watch as fe, resolveComponent as Ee, resolveDirective as
|
|
1
|
+
import { ref as v, watch as fe, resolveComponent as Ee, resolveDirective as Me, createElementBlock as A, openBlock as f, createElementVNode as w, createVNode as i, createCommentVNode as X, withDirectives as Ne, createBlock as T, unref as a, withCtx as s, Fragment as oe, renderList as ue, createTextVNode as $, toDisplayString as h, normalizeStyle as Ae } from "vue";
|
|
2
2
|
import { saveAs as Te } from "file-saver";
|
|
3
3
|
import * as Be from "exceljs";
|
|
4
|
-
import { p as W, b as
|
|
4
|
+
import { p as W, b as de, h as ze, a as ie, c as D } from "./index-D4ZMBdCa.js";
|
|
5
5
|
import { useI18n as Fe } from "vue-i18n";
|
|
6
|
-
import { ElSelect as Ue, ElOption as Ye, ElButton as
|
|
6
|
+
import { ElSelect as Ue, ElOption as Ye, ElButton as M, ElSwitch as re, ElSkeleton as Ie, ElTable as He, ElTableColumn as B, ElSkeletonItem as P, ElDialog as Re, ElForm as We, ElFormItem as Pe, ElRadioGroup as je, ElRadioButton as se, ElSlider as j } from "element-plus";
|
|
7
7
|
import { ContextMenu as Le, ContextMenuItem as Oe, ContextMenuSeparator as Ge } from "@imengyu/vue3-context-menu";
|
|
8
8
|
const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "100px", width: "100%", display: "inline-block" } }, Ke = ["innerHTML"], Qe = {
|
|
9
9
|
key: 0,
|
|
@@ -37,7 +37,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
37
37
|
// code: '0000-00052'
|
|
38
38
|
// ids: 1
|
|
39
39
|
// }
|
|
40
|
-
]), _ = v((/* @__PURE__ */ new Date()).getMonth() + 1),
|
|
40
|
+
]), _ = v((/* @__PURE__ */ new Date()).getMonth() + 1), ve = v(!1), F = v([]), x = v(new Date((/* @__PURE__ */ new Date()).getFullYear(), (/* @__PURE__ */ new Date()).getMonth(), 1)), u = v([]), G = v(0), b = v(9), k = v(8), Z = v(!1), ge = v(!0), U = v(!1), ee = v("5"), Y = v(1), V = v(""), le = v([]), E = v([]), q = v([]), m = v({ name: "Имя", length: 0, code: "" }), J = v(!1), te = v({
|
|
41
41
|
zIndex: 30,
|
|
42
42
|
minWidth: 220,
|
|
43
43
|
x: 500,
|
|
@@ -46,24 +46,26 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
46
46
|
fe(V, async (t, e) => {
|
|
47
47
|
t !== e && (E.value = [], Z.value = !1, S.odata.personal.forEach((o) => {
|
|
48
48
|
o.divisionName === t && (E.value.some((r) => (r == null ? void 0 : r.activeText) === o.roleName) || E.value.push({ val: !0, activeText: o.roleName }));
|
|
49
|
-
}),
|
|
49
|
+
}), ae());
|
|
50
50
|
}), fe(_, async (t) => {
|
|
51
51
|
let e = (/* @__PURE__ */ new Date()).getMonth(), o = t === null ? e : t - 1;
|
|
52
52
|
o = e - 1 <= o ? o : o + 12, x.value = new Date((/* @__PURE__ */ new Date()).getFullYear(), o, 1), he();
|
|
53
53
|
});
|
|
54
54
|
const we = (t, e, o, r) => {
|
|
55
|
-
m.value.ids = t.ids, m.value.key = t.key, m.value.add = t.days.length > 0 && t.days[t.days.length - 1].cont, m.value.level = e.level, m.value.day = o.cellIndex,
|
|
56
|
-
}, ke = (t
|
|
57
|
-
|
|
58
|
-
|
|
55
|
+
m.value.ids = t.ids, m.value.key = t.key, m.value.add = t.days.length > 0 && t.days[t.days.length - 1].cont, m.value.level = e.level, m.value.day = o.cellIndex, te.value.y = r.clientY, te.value.x = r.clientX, e.level === 2 && e.no === 0 && S.checkEdit && (m.value.name = d("workSchedule.autocomplete"), J.value = !0), e.level === 3 && o.cellIndex - e.no === 1 && S.checkEdit && (N(o.cellIndex, t.ids), m.value.name = d("workSchedule.modeSelection"), J.value = !0);
|
|
56
|
+
}, ke = (t) => {
|
|
57
|
+
console.log(t);
|
|
58
|
+
let e = "ee";
|
|
59
|
+
if (t = "2025.04.21", !F.value || F.value.length === 0) return "";
|
|
60
|
+
const o = new Date(ie(t)).getTime();
|
|
59
61
|
for (let r of F.value) {
|
|
60
62
|
const { dateStart: l, dateEnd: g, code: p } = r;
|
|
61
63
|
if (l && g && p === e) {
|
|
62
|
-
const c = new Date(
|
|
63
|
-
if (o >= c && o <= C) return
|
|
64
|
+
const c = new Date(ie(l)).getTime(), C = new Date(ie(g)).getTime();
|
|
65
|
+
if (o >= c && o <= C) return "vacation";
|
|
64
66
|
}
|
|
65
67
|
}
|
|
66
|
-
return
|
|
68
|
+
return "";
|
|
67
69
|
}, he = () => {
|
|
68
70
|
const t = me.value, e = new Date(x.value), o = new Date(e.getFullYear(), e.getMonth() + 1, 0).getDate();
|
|
69
71
|
let r = [], l = 0;
|
|
@@ -76,17 +78,17 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
76
78
|
G.value = l, u.value = r, S.odata.getPersonal({}).then((g) => {
|
|
77
79
|
var p;
|
|
78
80
|
V.value.length === 0 && (V.value = (p = g.find((c) => c.employeeName === S.fullName)) == null ? void 0 : p.divisionName), g.forEach((c) => {
|
|
79
|
-
|
|
80
|
-
}),
|
|
81
|
+
le.value.some((C) => (C == null ? void 0 : C.value) === c.divisionName) || le.value.push({ value: c.divisionName, label: c.divisionName, key: c.divisionName }), c.divisionName === V.value && !E.value.some((C) => (C == null ? void 0 : C.activeText) === c.roleName) && E.value.push({ val: !0, activeText: c.roleName });
|
|
82
|
+
}), ae(), ge.value = !1;
|
|
81
83
|
});
|
|
82
84
|
}, ce = (t, e) => {
|
|
83
85
|
var g, p, c;
|
|
84
86
|
const o = new Date(x.value), r = `${o.getFullYear()}-${(o.getMonth() + 1).toString().padStart(2, "0")}-${t.toString().padStart(2, "0")}`, l = (g = n.value[e]) == null ? void 0 : g.days.findIndex((C) => C.day === r);
|
|
85
87
|
return e === -1 || l === -1 ? "" : ((p = n.value[e].days[l]) == null ? void 0 : p.tips) + "<br>" + ((c = n.value[e].days[l]) == null ? void 0 : c.time);
|
|
86
|
-
},
|
|
88
|
+
}, ae = () => {
|
|
87
89
|
n.value = [], q.value = [], F.value = [], S.odata.personal.forEach((t) => {
|
|
88
90
|
if (t.divisionName === V.value && E.value.some((e) => e.val && e.activeText === t.roleName)) {
|
|
89
|
-
let e =
|
|
91
|
+
let e = de(t.employeeName);
|
|
90
92
|
q.value.push(t.employeeKey), n.value.push({ name: e + " (" + t.roleName + ")", days: [], contHour: 0, code: t.employeeKey, id: !1, ids: n.value.length });
|
|
91
93
|
}
|
|
92
94
|
}), S.workSchedule.getUsersYear({ code: q.value, year: new Date(x.value).getFullYear() }).then((t) => {
|
|
@@ -109,22 +111,22 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
109
111
|
}, xe = (t) => {
|
|
110
112
|
n.value[t].days = [], H();
|
|
111
113
|
}, Se = (t) => {
|
|
112
|
-
switch (
|
|
114
|
+
switch (ee.value) {
|
|
113
115
|
case "5":
|
|
114
116
|
for (let e = Y.value; e <= u.value.length; e++)
|
|
115
|
-
u.value[e - 1].holidays === "" &&
|
|
117
|
+
u.value[e - 1].holidays === "" && N(e, t, !0), u.value[e - 1].holidays === "preholiday" && (k.value -= 1, N(e, t, !0), k.value += 1);
|
|
116
118
|
break;
|
|
117
119
|
case "2x2":
|
|
118
120
|
for (let e = Y.value; e <= u.value.length; e += 4)
|
|
119
|
-
|
|
121
|
+
N(e, t, !0), e + 1 <= u.value.length && N(e + 1, t, !0);
|
|
120
122
|
break;
|
|
121
123
|
case "2x5":
|
|
122
124
|
for (let e = Y.value; e <= u.value.length; e += 7)
|
|
123
125
|
for (let o = e; o < e + 5 && o <= u.value.length; o++)
|
|
124
|
-
u.value[o - 1].holidays === "preholiday" ? (k.value -= 1,
|
|
126
|
+
u.value[o - 1].holidays === "preholiday" ? (k.value -= 1, N(o, t, !0), k.value += 1) : N(o, t, !0);
|
|
125
127
|
break;
|
|
126
128
|
}
|
|
127
|
-
},
|
|
129
|
+
}, N = (t, e, o = !1) => {
|
|
128
130
|
const { date: r, ind: l } = K(t, e);
|
|
129
131
|
l === -1 ? (n.value[e].days.push({
|
|
130
132
|
day: r,
|
|
@@ -158,8 +160,8 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
158
160
|
for (const y of n.value) {
|
|
159
161
|
let Q = [y.name];
|
|
160
162
|
for (let R = 1; R <= u.value.length; R++) {
|
|
161
|
-
const { ind:
|
|
162
|
-
|
|
163
|
+
const { ind: ne } = K(R, g);
|
|
164
|
+
ne !== -1 ? Q[R] = `${y.days[ne].time} ${y.days[ne].tips}` : Q[R] = " ";
|
|
163
165
|
}
|
|
164
166
|
Q.push(((ye = y.days) == null ? void 0 : ye.length) || " ", y.contHour || 0);
|
|
165
167
|
const De = e.addRow(Q);
|
|
@@ -168,7 +170,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
168
170
|
let p = "Щербина Е. В.";
|
|
169
171
|
S.odata.personal.forEach((y) => {
|
|
170
172
|
y.roleName === "Начальник отдела правовой и кадровой работы" && (p = y.employeeName);
|
|
171
|
-
}), e.mergeCells(`A${n.value.length + 6}:P${n.value.length + 6}`), e.mergeCells(`Q${n.value.length + 6}:AG${n.value.length + 6}`), e.mergeCells(`B${n.value.length + 8}:E${n.value.length + 8}`), e.mergeCells(`F${n.value.length + 8}:L${n.value.length + 8}`), e.mergeCells(`M${n.value.length + 8}:P${n.value.length + 8}`), e.mergeCells(`S${n.value.length + 8}:V${n.value.length + 8}`), e.mergeCells(`W${n.value.length + 8}:AC${n.value.length + 8}`), e.mergeCells(`AD${n.value.length + 8}:AG${n.value.length + 8}`), e.mergeCells(`Z${n.value.length + 9}:AA${n.value.length + 9}`), e.getCell(`A${n.value.length + 6}`).value = d("workSchedule.byInitials"), e.getCell(`Q${n.value.length + 6}`).value = d("workSchedule.supervisorHR"), e.getCell(`B${n.value.length + 8}`).value = d("workSchedule.compiled") + ":", e.getCell(`S${n.value.length + 8}`).value = d("workSchedule.approved") + ":", e.getCell(`M${n.value.length + 8}`).value =
|
|
173
|
+
}), e.mergeCells(`A${n.value.length + 6}:P${n.value.length + 6}`), e.mergeCells(`Q${n.value.length + 6}:AG${n.value.length + 6}`), e.mergeCells(`B${n.value.length + 8}:E${n.value.length + 8}`), e.mergeCells(`F${n.value.length + 8}:L${n.value.length + 8}`), e.mergeCells(`M${n.value.length + 8}:P${n.value.length + 8}`), e.mergeCells(`S${n.value.length + 8}:V${n.value.length + 8}`), e.mergeCells(`W${n.value.length + 8}:AC${n.value.length + 8}`), e.mergeCells(`AD${n.value.length + 8}:AG${n.value.length + 8}`), e.mergeCells(`Z${n.value.length + 9}:AA${n.value.length + 9}`), e.getCell(`A${n.value.length + 6}`).value = d("workSchedule.byInitials"), e.getCell(`Q${n.value.length + 6}`).value = d("workSchedule.supervisorHR"), e.getCell(`B${n.value.length + 8}`).value = d("workSchedule.compiled") + ":", e.getCell(`S${n.value.length + 8}`).value = d("workSchedule.approved") + ":", e.getCell(`M${n.value.length + 8}`).value = de(S.fullName), e.getCell(`AD${n.value.length + 8}`).value = de(p), e.getCell(`Z${n.value.length + 9}`).value = d("workSchedule.printPlace"), e.getCell(`A${n.value.length + 6}`).alignment = { vertical: "middle", horizontal: "right" }, e.getCell(`Q${n.value.length + 6}`).alignment = { vertical: "middle", horizontal: "right" }, e.getCell(`B${n.value.length + 8}`).alignment = { vertical: "middle", horizontal: "right" }, e.getCell(`F${n.value.length + 8}`).alignment = { vertical: "middle", horizontal: "right" }, e.getCell(`M${n.value.length + 8}`).alignment = { vertical: "middle", horizontal: "left" }, e.getCell(`AD${n.value.length + 8}`).alignment = { vertical: "middle", horizontal: "left" }, e.getCell(`Z${n.value.length + 9}`).alignment = o, e.getCell(`F${n.value.length + 8}`).border = { bottom: { style: "thin" } }, e.getCell(`W${n.value.length + 8}`).border = { bottom: { style: "thin" } };
|
|
172
174
|
const c = "export_" + W(Date.now(), "{dd}.{m}.{Y}") + ".xlsx", C = await t.xlsx.writeBuffer();
|
|
173
175
|
Te(new Blob([C]), c), O.value = !1;
|
|
174
176
|
}, Ve = async () => {
|
|
@@ -177,7 +179,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
177
179
|
return ze().then((t) => {
|
|
178
180
|
me.value = t, he();
|
|
179
181
|
}), (t, e) => {
|
|
180
|
-
const o = Ee("el-date-picker"), r =
|
|
182
|
+
const o = Ee("el-date-picker"), r = Me("loading");
|
|
181
183
|
return f(), A("div", Ze, [
|
|
182
184
|
w("div", qe, [
|
|
183
185
|
z.checkEdit ? (f(), T(a(Ue), {
|
|
@@ -188,7 +190,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
188
190
|
style: { width: "240px" }
|
|
189
191
|
}, {
|
|
190
192
|
default: s(() => [
|
|
191
|
-
(f(!0), A(
|
|
193
|
+
(f(!0), A(oe, null, ue(le.value, (l) => (f(), T(a(Ye), {
|
|
192
194
|
key: l.value,
|
|
193
195
|
label: l.label,
|
|
194
196
|
value: l.value
|
|
@@ -196,7 +198,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
196
198
|
]),
|
|
197
199
|
_: 1
|
|
198
200
|
}, 8, ["modelValue"])) : X("", !0),
|
|
199
|
-
z.checkEdit ? (f(), T(a(
|
|
201
|
+
z.checkEdit ? (f(), T(a(M), {
|
|
200
202
|
key: 1,
|
|
201
203
|
plain: "",
|
|
202
204
|
onClick: e[1] || (e[1] = (l) => U.value = !0)
|
|
@@ -215,16 +217,16 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
215
217
|
"value-format": "M"
|
|
216
218
|
}, null, 8, ["modelValue"]),
|
|
217
219
|
e[19] || (e[19] = w("div", { class: "expander" }, null, -1)),
|
|
218
|
-
i(a(
|
|
220
|
+
i(a(re), {
|
|
219
221
|
modelValue: I.value,
|
|
220
222
|
"onUpdate:modelValue": e[3] || (e[3] = (l) => I.value = l),
|
|
221
223
|
"active-text": t.$t("bids.currentHeight"),
|
|
222
224
|
"active-value": "100%",
|
|
223
225
|
"inactive-value": "calc(100vh - var(--el-component-size)*4 - var(--el-main-padding)*2 - var(--header-height))"
|
|
224
226
|
}, null, 8, ["modelValue", "active-text"]),
|
|
225
|
-
i(a(
|
|
226
|
-
modelValue:
|
|
227
|
-
"onUpdate:modelValue": e[4] || (e[4] = (l) =>
|
|
227
|
+
i(a(re), {
|
|
228
|
+
modelValue: ve.value,
|
|
229
|
+
"onUpdate:modelValue": e[4] || (e[4] = (l) => ve.value = l),
|
|
228
230
|
"active-text": "Отпуска",
|
|
229
231
|
"active-value": !0,
|
|
230
232
|
"inactive-value": !1
|
|
@@ -266,7 +268,8 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
266
268
|
size: "small",
|
|
267
269
|
align: "center",
|
|
268
270
|
onCellClick: we,
|
|
269
|
-
"empty-text": a(d)("workSchedule.emptyText")
|
|
271
|
+
"empty-text": a(d)("workSchedule.emptyText"),
|
|
272
|
+
"cell-class-name": ke()
|
|
270
273
|
}, {
|
|
271
274
|
default: s(() => [
|
|
272
275
|
i(a(B), {
|
|
@@ -291,14 +294,13 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
291
294
|
align: "center"
|
|
292
295
|
}, {
|
|
293
296
|
default: s(() => [
|
|
294
|
-
(f(!0), A(
|
|
297
|
+
(f(!0), A(oe, null, ue(u.value, (l) => (f(), T(a(B), {
|
|
295
298
|
key: l.day,
|
|
296
299
|
width: "46",
|
|
297
300
|
"class-name": l.holidays,
|
|
298
301
|
align: "center",
|
|
299
302
|
label: l.weekday + `
|
|
300
|
-
` + l.day.toString()
|
|
301
|
-
"cell-class-name": () => ee.value && ke(l.day, l.code) ? "vacation" : ""
|
|
303
|
+
` + l.day.toString()
|
|
302
304
|
}, {
|
|
303
305
|
default: s((g) => [
|
|
304
306
|
w("div", {
|
|
@@ -307,7 +309,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
307
309
|
}, null, 8, Ke)
|
|
308
310
|
]),
|
|
309
311
|
_: 2
|
|
310
|
-
}, 1032, ["class-name", "label"
|
|
312
|
+
}, 1032, ["class-name", "label"]))), 128))
|
|
311
313
|
]),
|
|
312
314
|
_: 1
|
|
313
315
|
}, 8, ["label"]),
|
|
@@ -345,13 +347,13 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
345
347
|
}, 8, ["label"])
|
|
346
348
|
]),
|
|
347
349
|
_: 1
|
|
348
|
-
}, 8, ["data", "max-height", "empty-text"])
|
|
350
|
+
}, 8, ["data", "max-height", "empty-text", "cell-class-name"])
|
|
349
351
|
]),
|
|
350
352
|
_: 1
|
|
351
353
|
}, 8, ["loading"]),
|
|
352
354
|
z.checkEdit ? (f(), A("div", Qe, [
|
|
353
355
|
$(h(a(d)("workSchedule.chartsFilled")) + ": ", 1),
|
|
354
|
-
Z.value ? X("", !0) : (f(), T(a(
|
|
356
|
+
Z.value ? X("", !0) : (f(), T(a(M), {
|
|
355
357
|
key: 0,
|
|
356
358
|
type: "primary",
|
|
357
359
|
onClick: Ve
|
|
@@ -364,7 +366,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
364
366
|
e[20] || (e[20] = $()),
|
|
365
367
|
w("span", null, h(z.fullName), 1)
|
|
366
368
|
])) : X("", !0),
|
|
367
|
-
|
|
369
|
+
Ne((f(), T(a(M), {
|
|
368
370
|
disabled: O.value,
|
|
369
371
|
plain: "",
|
|
370
372
|
onClick: be,
|
|
@@ -384,7 +386,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
384
386
|
width: "400px"
|
|
385
387
|
}, {
|
|
386
388
|
footer: s(() => [
|
|
387
|
-
i(a(
|
|
389
|
+
i(a(M), {
|
|
388
390
|
onClick: e[5] || (e[5] = (l) => U.value = !1),
|
|
389
391
|
size: "default"
|
|
390
392
|
}, {
|
|
@@ -393,10 +395,10 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
393
395
|
]),
|
|
394
396
|
_: 1
|
|
395
397
|
}),
|
|
396
|
-
i(a(
|
|
398
|
+
i(a(M), {
|
|
397
399
|
size: "default",
|
|
398
400
|
type: "primary",
|
|
399
|
-
onClick:
|
|
401
|
+
onClick: ae
|
|
400
402
|
}, {
|
|
401
403
|
default: s(() => [
|
|
402
404
|
$(h(t.$t("workSchedule.select")), 1)
|
|
@@ -411,9 +413,9 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
411
413
|
autocomplete: "on"
|
|
412
414
|
}, {
|
|
413
415
|
default: s(() => [
|
|
414
|
-
(f(!0), A(
|
|
416
|
+
(f(!0), A(oe, null, ue(E.value, (l) => (f(), T(a(Pe), null, {
|
|
415
417
|
default: s(() => [
|
|
416
|
-
i(a(
|
|
418
|
+
i(a(re), {
|
|
417
419
|
modelValue: l.val,
|
|
418
420
|
"onUpdate:modelValue": (g) => l.val = g,
|
|
419
421
|
"active-text": l.activeText
|
|
@@ -430,7 +432,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
430
432
|
i(a(Le), {
|
|
431
433
|
show: J.value,
|
|
432
434
|
"onUpdate:show": e[18] || (e[18] = (l) => J.value = l),
|
|
433
|
-
options:
|
|
435
|
+
options: te.value
|
|
434
436
|
}, {
|
|
435
437
|
default: s(() => [
|
|
436
438
|
i(a(Oe), {
|
|
@@ -440,20 +442,20 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
440
442
|
i(a(Ge)),
|
|
441
443
|
m.value.level === 2 ? (f(), A("div", Xe, [
|
|
442
444
|
i(a(je), {
|
|
443
|
-
modelValue:
|
|
444
|
-
"onUpdate:modelValue": e[7] || (e[7] = (l) =>
|
|
445
|
+
modelValue: ee.value,
|
|
446
|
+
"onUpdate:modelValue": e[7] || (e[7] = (l) => ee.value = l),
|
|
445
447
|
size: "small"
|
|
446
448
|
}, {
|
|
447
449
|
default: s(() => [
|
|
448
|
-
i(a(
|
|
450
|
+
i(a(se), {
|
|
449
451
|
label: a(d)("workSchedule.Days5"),
|
|
450
452
|
value: "5"
|
|
451
453
|
}, null, 8, ["label"]),
|
|
452
|
-
i(a(
|
|
454
|
+
i(a(se), {
|
|
453
455
|
label: "2 Х 2",
|
|
454
456
|
value: "2x2"
|
|
455
457
|
}),
|
|
456
|
-
i(a(
|
|
458
|
+
i(a(se), {
|
|
457
459
|
label: "2 Х 5",
|
|
458
460
|
value: "2x5"
|
|
459
461
|
})
|
|
@@ -485,7 +487,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
485
487
|
min: 4,
|
|
486
488
|
max: 12
|
|
487
489
|
}, null, 8, ["modelValue"]),
|
|
488
|
-
i(a(
|
|
490
|
+
i(a(M), {
|
|
489
491
|
style: { "margin-top": ".5rem" },
|
|
490
492
|
size: "small",
|
|
491
493
|
onClick: e[11] || (e[11] = (l) => Se(m.value.ids))
|
|
@@ -495,7 +497,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
495
497
|
]),
|
|
496
498
|
_: 1
|
|
497
499
|
}),
|
|
498
|
-
i(a(
|
|
500
|
+
i(a(M), {
|
|
499
501
|
style: { "margin-top": ".5rem" },
|
|
500
502
|
size: "small",
|
|
501
503
|
onClick: e[12] || (e[12] = (l) => xe(m.value.ids))
|
|
@@ -526,7 +528,7 @@ const Ze = { class: "work" }, qe = { class: "nav" }, Je = { style: { height: "10
|
|
|
526
528
|
max: 12,
|
|
527
529
|
onChange: e[16] || (e[16] = (l) => pe(m.value.day, m.value.ids))
|
|
528
530
|
}, null, 8, ["modelValue"]),
|
|
529
|
-
i(a(
|
|
531
|
+
i(a(M), {
|
|
530
532
|
style: { "margin-top": ".5rem" },
|
|
531
533
|
size: "small",
|
|
532
534
|
onClick: e[17] || (e[17] = (l) => $e(m.value.day, m.value.ids))
|