import{P as S}from"./page.3b4d44cb.js";import{c as A,b as E}from"./tableArea.5d4d6780.js";import{a4 as L,b7 as h,b as _,ar as B,E as I,_ as $,c as d,e as b,k as w,i as l,g as p,h as t,f as D,j as N,m as f,t as P,F as R,R as U,S as C}from"./index.0308b213.js";const F={components:{Page:S},setup(){const e=L(),a=h(),i=Number(e.query.id),m=()=>{setTimeout(()=>{a.go(-1)},1e3)},n=_({loading:!1,btnLoading:!1,checkList:[],parentTitle:""}),u=_({title:"",parentid:i||0,displayorder:"",status:1});i&&(n.loading=!0,A({id:i}).then(s=>{n.parentTitle=s.data.title}).finally(()=>{n.loading=!1}));const r=()=>{console.log("\u63D0\u4EA4",u),n.btnLoading=!0,E(u).then(s=>{console.log("\u6570\u636E",s),I({message:"\u63D0\u4EA4\u6210\u529F",type:"success"}),m()}).finally(()=>{n.btnLoading=!1})};return{...B(n),params:u,submit:r}}};const g=e=>(U("data-v-6c8b33ad"),e=e(),C(),e),j={class:"container"},q=g(()=>p("div",{class:"title-box"},[p("h2",{class:"title"},"\u7F16\u8F91\u5B50\u533A\u57DF")],-1)),M=g(()=>p("p",{class:"tips-text"},"\u63D0\u793A\uFF1A\u533A\u57DF\u4E0D\u663E\u793A\uFF0C\u5176\u5B50\u533A\u57DF\u4E5F\u4E0D\u663E\u793A",-1)),z=f("\u63D0\u4EA4");function G(e,a,i,m,n,u){const r=d("el-input"),s=d("el-form-item"),V=d("el-radio"),y=d("el-radio-group"),T=d("el-button"),v=d("el-form"),k=d("Page");return b(),w(k,{showBorder:!1,loading:e.loading},{main:l(()=>[p("div",j,[q,t(v,{"label-width":"150px",class:"form-container"},{default:l(()=>[t(s,{label:"\u7236\u7EA7\u533A\u57DF"},{default:l(()=>[t(r,{disabled:!0,modelValue:e.parentTitle,"onUpdate:modelValue":a[0]||(a[0]=o=>e.parentTitle=o)},null,8,["modelValue"])]),_:1}),t(s,{label:"\u5B50\u533A\u57DF\u540D\u79F0"},{default:l(()=>[t(r,{modelValue:e.params.title,"onUpdate:modelValue":a[1]||(a[1]=o=>e.params.title=o)},null,8,["modelValue"])]),_:1}),t(s,{label:"\u5B50\u533A\u57DF\u6392\u5E8F"},{default:l(()=>[t(r,{modelValue:e.params.displayorder,"onUpdate:modelValue":a[2]||(a[2]=o=>e.params.displayorder=o),type:"number"},null,8,["modelValue"])]),_:1}),t(s,{label:"\u5B50\u533A\u57DF\u72B6\u6001"},{default:l(()=>[t(y,{modelValue:e.params.status,"onUpdate:modelValue":a[3]||(a[3]=o=>e.params.status=o)},{default:l(()=>[(b(),D(R,null,N(["\u662F","\u5426"],(o,c)=>t(V,{label:c==0?1:0,key:c},{default:l(()=>[f(P(o),1)]),_:2},1032,["label"])),64))]),_:1},8,["modelValue"])]),_:1}),t(s,{class:"tips-box"},{default:l(()=>[M]),_:1}),t(T,{type:"primary",loading:e.btnLoading,onClick:a[4]||(a[4]=o=>e.submit())},{default:l(()=>[z]),_:1},8,["loading"])]),_:1})])]),_:1},8,["loading"])}const O=$(F,[["render",G],["__scopeId","data-v-6c8b33ad"]]);export{O as default};
