import{f as i,w as N,o as f,U as h,a2 as b,a3 as g,a4 as s,az as S,aA as _,k as c}from"./vue-vendor-CxLCUzY4.js";import{c9 as k,N as w}from"./index-B_2CoVdl.js";import"./antd-vue-vendor-CDWW6V_M.js";import"./vxe-table-vendor-B5h3MVdD.js";const m=u=>(S("data-v-b718aa7e"),u=u(),_(),u),y={class:"setSwitchOptions"},C=m(()=>s("span",null,"是",-1)),I=m(()=>s("span",null,"否",-1)),A="Y",B="N",O={__name:"SetSwitchOptions",props:{value:{type:[Array,String],default:["Y","N"]}},emits:"change",setup(u,{emit:n}){const d=u,l=i(A),t=i(B);N(()=>d.value,e=>{if(typeof e=="string"){const a=e.split(",");l.value=a[0],t.value=a[1]}else w(e)&&(l.value=e[0],t.value=e[1])},{immediate:!0});const p=()=>{l.value!=""&&t.value!=""&&r()},r=()=>{let e=Number(l.value),a=Number(t.value);(Number.isNaN(e)||Number.isNaN(a))&&(e=l.value,a=t.value),n("change",[e,a]),n("update:value",[e,a])};return f(()=>{r()}),(e,a)=>{const v=h("a-input");return b(),g("div",y,[s("p",null,[C,c(v,{value:l.value,"onUpdate:value":a[0]||(a[0]=o=>l.value=o),onChange:p},null,8,["value"])]),s("p",null,[I,c(v,{value:t.value,"onUpdate:value":a[1]||(a[1]=o=>t.value=o),onChange:p},null,8,["value"])])])}}},j=k(O,[["__scopeId","data-v-b718aa7e"]]);export{j as default};
