import P from"./baseform-5003d7e5-1779868775780v=1.0.0.js";import{u as R}from"./useFormEdit-42a9503c-1779868775780v=1.0.0.js";import{n as N,l as _,o as b}from"./systemManage-d67b09c0-1779868775780v=1.0.0.js";import{b as k}from"./index-0f3e2c06-1779868775780v=1.0.0.js";import{E as d}from"./eleVendor-dbf96bf3-1779868775780v=1.0.0.js";import{l as c,a as n,d as q,ah as w,m as L,M as x,O as B,U as S,u as l,B as p}from"./vendor-98154105-1779868775780v=1.0.0.js";import"./diagTable-53aca04b-1779868775780v=1.0.0.js";import"./useTable-7f617eef-1779868775780v=1.0.0.js";import"./useCheck-55f2b7da-1779868775780v=1.0.0.js";import"./organize-df1743e7-1779868775780v=1.0.0.js";import"./_plugin-vue_export-helper-8c5478df-1779868775780v=1.0.0.js";import"./tabs-e9b8af2b-1779868775780v=1.0.0.js";const h=c({name:"systemCheckStepEdit"}),G=c({...h,setup(E){const t=n({mpId:"",auditNodeConfId:"",auditWay:"",auditType:"",auditPerson:"",auditRolePersIds:"",auditRolePersIdsRespVOList:[]}),o=n(!1),f=n(null),I=n(null);n(null);const i=n([]),s=k(),{closeCurrent:m}=R(),y=async r=>{const e=await N(r);if(e.code!==0){d.error(e.msg);return}e.data.auditType==="role"?e.data.auditRolePersIds=e.data.auditRolePersIds.split(",").map(Number):e.data.auditRolePersIds=e.data.auditRolePersIds.split(",");for(const a in t.value)t.value[a]=e.data[a]},C=async r=>{const a=await _({page:1,size:200,mpId:r});if(a.code!==0){d.error(a.msg);return}i.value=a.data.listData},g=()=>{m()},v=async r=>{o.value=!0;try{let e=b,a="\u7F16\u8F91\u6210\u529F",u=await e({sortColumn:"sort",sortType:"asc",...r});u.code===0?(d({type:"success",message:`${a}!`}),m()):d.error(u.msg),o.value=!1}catch{o.value=!1}};return q(async()=>{s.query.auditNodeConfId&&(I.value=s.query.auditNodeConfId,t.value.auditNodeConfId=s.query.auditNodeConfId,f.value=s.query.mpId,await y(s.query.auditNodeConfId),await C(s.query.mpId))}),(r,e)=>{const a=w("PaIndexPage");return L(),x(a,null,{default:B(()=>[S(P,{value:l(t),"onUpdate:value":e[0]||(e[0]=u=>p(t)?t.value=u:null),loading:l(o),"onUpdate:loading":e[1]||(e[1]=u=>p(o)?o.value=u:null),roleList:l(i),onCancel:g,onSubmit:v},null,8,["value","loading","roleList"])]),_:1})}}});export{G as default};
