数通互联化工云平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

1 lines
7.3 KiB

import{d as re,r as x,ax as I,G as ie,z as E,a as i,c as _,b as l,e,h as V,H as p,f as B,F as N,g as U,$ as m,dJ as ce,dK as de,ae as z,dL as M,a7 as O,dM as ue,bI as pe,an as fe,aq as _e,ap as me,ak as ye,ab as be,ai as ge,b3 as we,cz as he,M as ke,b4 as ve,ac as xe,_ as Ve}from"./index-e450010e.js";import{l as Be}from"./api-e282220e.js";import{_ as Pe}from"./xy.vue_vue_type_script_setup_true_lang-9ead4401.js";import{_ as Ce}from"./lc.vue_vue_type_script_setup_true_lang-47030e90.js";import{_ as Ee}from"./ta.vue_vue_type_script_setup_true_lang-e0e0c81e.js";const Se={key:0},je=re({__name:"daialog",props:{title:{type:String,default:""},addPost:{type:Boolean,default:!1},rowInfo:{type:Object,default(){return{}}},arrayNum:{type:Number,default:0}},emits:["update:addPost","editRow","addRow"],setup(P,{emit:q}){x(!1);const k=P;let y=x({});const u=I({xyPostBox:!1,lcPostBox:!1,taPostBox:!1}),F={label:"name"},c=I({postlist:[],inspect:[],cycle:""}),L=a=>{u.xyPostBox=!0,y.value=a},R=q,A=x([]);function G(){const a=k.rowInfo.id.toString();ce({id:a,all:0,levelL:0}).then(t=>{A.value=t.data})}G();const C=x([]);function v(){const a=k.rowInfo.id.toString();k.rowInfo.key;const t=c.postlist,f=c.inspect,d=new Number(c.cycle);Be({targetid:a,inspect:f,postlist:t,cycle:d}).then(n=>{C.value=n.data})}v();const j=x([]);function H(){const a=k.rowInfo.id.toString();de({id:a}).then(t=>{j.value=t.data.organdpostlist})}H();const J=a=>{u.lcPostBox=!0,y.value=a},K=a=>{u.taPostBox=!0,y.value=a},Q=()=>{R("update:addPost",!1)},W=a=>{z.confirm("你确定删除这条信息吗?","提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const t=a.id.toString();M({id:t,istrue:2,state:3}).then(()=>O.success("删除成功")),v()}).catch(()=>{alert("用户取消了删除操作")})},X=a=>{z.confirm("你确定删除这条信息吗?","提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const t=a.parentidsun.toString();ue({id:t,istrue:2,state:3}).then(()=>O.success("删除成功")),v()}).catch(()=>{alert("用户取消了删除操作")})};function Y(a,t){const f=a.toString();let d=1;t==2&&(d=2),M({id:f,state:d,istrue:2}),v()}const Z=()=>{const a=c.postlist.toString().split(",");c.postlist=a;const t=c.inspect.toString().split(",");c.inspect=t,v()},T=a=>{let t=[],f=0;return a.value.forEach((d,n)=>{n===0?t.push(1):d.columnName===a.value[n-1].columnName?(t[f]+=1,t.push(0)):(t.push(1),f=n)}),{one:t}};function ee({row:a,column:t,rowIndex:f,columnIndex:d}){if(d===0){const n=T(C).one[f],b=n>0?1:0;return{rowspan:n,colspan:b}}if(d===14){const n=T(C).one[f],b=n>0?1:0;return{rowspan:n,colspan:b}}}return ie(()=>{Object.assign(c,k.rowInfo)}),(a,t)=>{const f=pe,d=fe,n=_e,b=me,te=E("Search"),g=ye,w=be,le=ge,s=we,h=he,oe=ke,$=E("EditPen"),D=E("Delete"),ae=E("Plus"),ne=ve,se=xe;return i(),_(se,{"model-value":!0,title:"考核方法明细",style:{width:"90%"},onClose:Q},{default:l(()=>[e(le,{class:"yui"},{default:l(()=>[e(d,{label:"岗位"},{default:l(()=>[e(f,{ref:"orgTreeRef",modelValue:c.postlist,"onUpdate:modelValue":t[0]||(t[0]=o=>c.postlist=o),clearable:"","check-strictly":"true","node-key":"id",data:V(j),props:F,"render-after-expand":!1},null,8,["modelValue","data"])]),_:1}),e(d,{label:"检查方式","label-width":"90"},{default:l(()=>[e(b,{modelValue:c.inspect,"onUpdate:modelValue":t[1]||(t[1]=o=>c.inspect=o),label:"检查方式"},{default:l(()=>[e(n,{label:"现场检查",value:1}),e(n,{label:"资料审查",value:2}),e(n,{label:"事件触发",value:3})]),_:1},8,["modelValue"])]),_:1}),e(d,{label:"检查周期","label-width":"90"},{default:l(()=>[e(b,{modelValue:c.cycle,"onUpdate:modelValue":t[2]||(t[2]=o=>c.cycle=o),label:"检查方式"},{default:l(()=>[e(n,{label:"月",value:4}),e(n,{label:"季度",value:5}),e(n,{label:"年",value:6})]),_:1},8,["modelValue"])]),_:1}),e(d,{"label-width":"20"},{default:l(()=>[e(w,{type:"primary",onClick:Z},{default:l(()=>[e(g,null,{default:l(()=>[e(te)]),_:1}),p("查询")]),_:1})]),_:1})]),_:1}),e(ne,{"span-method":ee,data:V(C),class:"uio",height:"600",border:""},{default:l(()=>[e(s,{prop:"columnName",label:"考核项目"}),e(s,{prop:"jibuqi",label:"序号",width:"40"}),e(s,{prop:"title",label:"考核内容",width:"300"}),e(s,{prop:"censortype",label:"操作属性",align:"center",width:"170"},{default:l(o=>[(i(!0),B(N,null,U(o.row.censortype,(r,S)=>(i(),B("span",{key:S},[r==1?(i(),_(h,{key:0},{default:l(()=>[p("减少")]),_:1})):m("",!0),r==2?(i(),_(h,{key:1,type:"warning"},{default:l(()=>[p("增多")]),_:1})):m("",!0),r==3?(i(),_(h,{key:2,type:"danger"},{default:l(()=>[p("无属性,现场确认加或减")]),_:1})):m("",!0)]))),128))]),_:1}),e(s,{prop:"standard",label:"考核标准"}),e(s,{prop:"company",label:"单位"}),e(s,{prop:"censortype",label:"检查方式",width:"100",align:"center"},{default:l(o=>[(i(!0),B(N,null,U(o.row.censortype,(r,S)=>(i(),B("span",{key:S},[r==1?(i(),_(h,{key:0},{default:l(()=>[p("现场检查")]),_:1})):m("",!0),r==2?(i(),_(h,{key:1,type:"warning"},{default:l(()=>[p("资料审查")]),_:1})):m("",!0),r==3?(i(),_(h,{key:2,type:"danger"},{default:l(()=>[p("事件触发")]),_:1})):m("",!0)]))),128))]),_:1}),e(s,{prop:"forfeit",label:"现金标准",align:"center"}),e(s,{prop:"punishmode",label:"检查周期",align:"center"},{default:l(o=>[o.row.punishmode==1?(i(),B("span",Se,"1次/月")):m("",!0)]),_:1}),e(s,{prop:"censorcont",label:"客观证据",align:"center"}),e(s,{prop:"content",label:"备注说明",align:"center"}),e(s,{prop:"state",label:"状态",width:"70",align:"center"},{default:l(o=>[e(oe,{modelValue:o.row.state,"onUpdate:modelValue":r=>o.row.state=r,class:"ml-2","inactive-value":1,"active-value":2,"inline-prompt":"",style:{"--el-switch-on-color":"#ff4949","--el-switch-off-color":"#13ce66"},onChange:r=>Y(o.row.id,o.row.state)},null,8,["modelValue","onUpdate:modelValue","onChange"])]),_:1}),e(s,{prop:"",label:"相关岗位及执行人"}),e(s,{fixed:"right",label:"操作",width:"135"},{default:l(({row:o})=>[e(w,{type:"primary",link:"",onClick:r=>L(o)},{default:l(()=>[e(g,null,{default:l(()=>[e($)]),_:1}),p("修改")]),_:2},1032,["onClick"]),e(w,{type:"primary",link:"",onClick:r=>W(o)},{default:l(()=>[e(g,null,{default:l(()=>[e(D)]),_:1}),p("删除")]),_:2},1032,["onClick"])]),_:1}),e(s,{fixed:"right",label:"项目操作",width:"85",align:"center"},{default:l(({row:o})=>[e(w,{type:"primary",link:"",class:"iop",onClick:r=>J(o)},{default:l(()=>[e(g,null,{default:l(()=>[e(ae)]),_:1}),p("新增")]),_:2},1032,["onClick"]),e(w,{type:"primary",link:"",onClick:r=>K(o)},{default:l(()=>[e(g,null,{default:l(()=>[e($)]),_:1}),p("修改")]),_:2},1032,["onClick"]),e(w,{type:"primary",link:"",onClick:r=>X(o)},{default:l(()=>[e(g,null,{default:l(()=>[e(D)]),_:1}),p("删除")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"]),u.xyPostBox?(i(),_(Pe,{key:0,modelValue:u.xyPostBox,"onUpdate:modelValue":t[3]||(t[3]=o=>u.xyPostBox=o),title:P.title,"row-info":V(y)},null,8,["modelValue","title","row-info"])):m("",!0),u.lcPostBox?(i(),_(Ce,{key:1,modelValue:u.lcPostBox,"onUpdate:modelValue":t[4]||(t[4]=o=>u.lcPostBox=o),title:P.title,"row-info":V(y)},null,8,["modelValue","title","row-info"])):m("",!0),u.taPostBox?(i(),_(Ee,{key:2,modelValue:u.taPostBox,"onUpdate:modelValue":t[5]||(t[5]=o=>u.taPostBox=o),title:P.title,"row-info":V(y)},null,8,["modelValue","title","row-info"])):m("",!0)]),_:1})}}});const Ue=Ve(je,[["__scopeId","data-v-5b448edc"]]);export{Ue as default};