import{_ as A,d as N,bn as U,w as p,aU as O,z as D,r as d,o as u,G as C,C as c,h as o,M as f,c as m,a as _,F as k,D as V,B as F,L as R,j as r,l as g,aq as T}from"./index.js";import{s as j,O as M}from"./organize-tree.7c8fbb.js";import{M as I}from"./modal.4cd7fc.js";const L={class:"flex cursor-pointer"},$={key:0,class:"mx-[5px]"},q=["onClick"],G={key:0,class:"mx-[5px]"},W={class:"flex justify-between pt-[20px]"},H={class:"flex gap-1"},J={class:"flex"},K={class:"flex-1"},Q=N({__name:"index",setup(X){const E="exclusive",{hasPermissionWithCode:z}=U(E),l=p([]),v=O(!1),i=p({}),n=p({status:"",cat_name:"",company_name:""}),t=p(null);function S(s){l.value.push(s)}function x(s){if(s===l.value.length-1)return;const e=l.value[s],b=e?e.id:"";t.value.changePid(b),t.value.onSearch(),l.value.splice(s+1)}return D(()=>l.value,()=>{const s=l.value[l.value.length-1];i.value.companyNo=s?s.companyNo:"",i.value.pid=s?s.id:"0"},{immediate:!0,deep:!0}),(s,e)=>{const b=d("ElOption"),w=d("ElSelect"),B=d("ElInput"),y=d("ElButton"),P=d("PageAuth");return u(),C(P,{class:"px-[10px] h-[calc(100vh-60px)] bg-white",pageName:E,margin:!1},{default:c(()=>[o("ul",L,[o("li",{onClick:e[0]||(e[0]=()=>x())},[f(" \u5168\u90E8\u4E13\u5C5E\u4E00\u7EA7\u5206\u7C7B "),l.value.length>0?(u(),m("span",$,"/")):_("v-if",!0)]),(u(!0),m(k,null,V(l.value,(a,h)=>(u(),m("li",{class:F({"cursor-pointer":!0,"text-[#ccc]":h===l.value.length-1}),key:a.id,onClick:()=>x(h)},[f(R(a.name)+" ",1),h!==l.value.length-1?(u(),m("span",G,"/")):_("v-if",!0)],10,q))),128))]),o("div",W,[o("div",H,[r(w,{modelValue:n.value.status,"onUpdate:modelValue":e[1]||(e[1]=a=>n.value.status=a),style:{width:"100%"},placeholder:"\u4E13\u5C5E\u7C7B\u578B\u72B6\u6001",onChange:e[2]||(e[2]=()=>t.value.onSearch())},{default:c(()=>[(u(!0),m(k,null,V(g(j),a=>(u(),C(b,{key:a.value,value:a.value,label:a.label},null,8,["value","label"]))),128))]),_:1},8,["modelValue"]),r(B,{modelValue:n.value.cat_name,"onUpdate:modelValue":e[3]||(e[3]=a=>n.value.cat_name=a),placeholder:"\u4E13\u5C5E\u7C7B\u578B\u540D\u79F0",clearable:"",size:"small",onChange:e[4]||(e[4]=()=>t.value.onSearch())},null,8,["modelValue"]),r(B,{modelValue:n.value.company_name,"onUpdate:modelValue":e[5]||(e[5]=a=>n.value.company_name=a),placeholder:"\u521B\u5EFA\u4EBA\u90E8\u95E8",clearable:"",size:"small",onChange:e[6]||(e[6]=()=>t.value.onSearch())},null,8,["modelValue"])]),o("div",J,[g(z)("003")?(u(),C(y,{key:0,size:"small",type:"primary",onClick:e[7]||(e[7]=a=>v.value=!0)},{default:c(()=>[f("\u6DFB\u52A0")]),_:1})):_("v-if",!0),r(y,{size:"small",onClick:e[8]||(e[8]=()=>t.value.onSearch())},{default:c(()=>[f("\u5237\u65B0")]),_:1})])]),_(" \u6811\u8282\u70B9 "),o("div",K,[r(M,{ref_key:"organizeTreeRef",ref:t,otherParms:n.value,breadcrumb:l.value,onBreadcrumbChange:S},null,8,["otherParms","breadcrumb"])]),r(I,{data:i.value,"onUpdate:data":e[9]||(e[9]=a=>i.value=a),visible:g(v),"onUpdate:visible":e[10]||(e[10]=a=>T(v)?v.value=a:null),onRefresh:e[11]||(e[11]=a=>t.value.onSearch()),breadcrumb:l.value,pid:i.value.pid},null,8,["data","visible","breadcrumb","pid"])]),_:1})}}});var ae=A(Q,[["__file","C:/Users/Administrator/Desktop/projects/purchase-vue3/src/views/serviceParam/exclusive/index.vue"]]);export{ae as default};
