import b from"./BaseForm-5dae83e3-1782729249161v=1.0.0.js";import{i as _,j as L,k as w}from"./eventApplyMgmtApi-6b4840c2-1782729249161v=1.0.0.js";import{u as S}from"./useFormEdit-fb8b8504-1782729249161v=1.0.0.js";import{a as E}from"./index-b309bf9f-1782729249161v=1.0.0.js";import{E as i}from"./eleVendor-5008d1ec-1782729249161v=1.0.0.js";import{y as c,r as u,m as C,al as k,z as B,I as F,J as M,R as P,u as l,k as d}from"./vendor-1e24e3ad-1782729249161v=1.0.0.js";import"./eleValidate-2ce2196e-1782729249161v=1.0.0.js";import"./usePrint-d863a9cc-1782729249161v=1.0.0.js";import"./keepAlive-20a782c5-1782729249161v=1.0.0.js";const I=c({name:"agreementManageEdit"}),z=c({...I,setup(T){const{closeCurrent:m}=S(),f=u(null),n=u({applicableType:"",name:"",content:"",mobileSignatureStatus:"",status:"",agreementId:""}),a=u(!1),r=E(),p=()=>{m()},g=async s=>{a.value=!0;try{let e=_,t="\u66F4\u65B0\u6210\u529F",o=await e(s);o.code==0?i({type:"success",message:`${t}!`}):i.warning(o.msg),a.value=!1,m()}catch{a.value=!1}},v=async s=>{let e=await L(s);if(e.code!=0){i.warning(e.msg);return}e.data.eventTime=[e.data.eventStartTime,e.data.eventEndTime],e.data.auditLastSubmitList=await y(e.data.eventProposerId),n.value=e.data},y=async s=>{const e=await w(s);let t=[];return e.code==0&&e.data.length>0&&(t=e.data.slice(1)),t};return C(()=>{r.query.id&&(f.value=r.query.id,v(r.query.id))}),(s,e)=>{const t=k("HZPageLayout");return B(),F(t,{title:l(r).meta.title,isBack:!0},{default:M(()=>[P(b,{value:l(n),"onUpdate:value":e[0]||(e[0]=o=>d(n)?n.value=o:null),mode:"view",loading:l(a),"onUpdate:loading":e[1]||(e[1]=o=>d(a)?a.value=o:null),onCancel:p,onSubmit:g},null,8,["value","loading"])]),_:1},8,["title"])}}});export{z as default};
