import{G as x,b as D,w as F,H as P,g as L}from"./element-plus.8e273e86.js";import{_ as N}from"./index.vue_vue_type_script_setup_true_lang.d6032bc4.js";import{u as T}from"./usePaging.f8c888e4.js";import{e as U,f as j}from"./warehouse_product.2008621d.js";import{d as h,r as I,Z as R,o as p,c as _,U as e,L as u,a as c,u as a,K as f,R as S,Q as d,j as w}from"./@vue.76ce7aa3.js";const W={class:"edit-popup"},$={key:0,class:"flex mt-4 justify-end"},q=h({name:"storeProductDETAILS"}),X=h({...q,emits:["success","close"],setup(z,{expose:g,emit:A}){const n=I(!1),r=R({supplier_id:"",is_pay:1}),v=async(i,o)=>{r.supplier_id=i.id,r.is_pay=o,m()},E=()=>{n.value=!0},b=i=>{U({id:i.id}).then(o=>{m()})},{pager:s,getLists:m,resetParams:G,resetPage:H}=T({fetchFun:j,params:r});return g({open:E,getDetail:v}),(i,o)=>{const t=x,C=D,y=F,B=P,V=N,k=L;return p(),_("div",W,[e(k,{title:"\u7ED3\u7B97\u8BE6\u60C5",size:1e3,modelValue:a(n),"onUpdate:modelValue":o[1]||(o[1]=l=>w(n)?n.value=l:null)},{default:u(()=>[c("div",null,[c("div",null,[e(B,{data:a(s).lists},{default:u(()=>[e(t,{label:"id",prop:"id","show-overflow-tooltip":""}),e(t,{label:"\u5546\u54C1\u56FE\u7247",prop:"image","min-width":"80"},{default:u(({row:l})=>[e(C,{style:{width:"50px",height:"50px"},src:l.image,"preview-teleported":!0},null,8,["src"])]),_:1}),e(t,{label:"\u5546\u54C1\u540D\u79F0",prop:"store_name","show-overflow-tooltip":""}),e(t,{label:"\u4ED3\u5E93",prop:"warehouse_name","show-overflow-tooltip":""}),e(t,{label:"\u4F9B\u5E94\u5546",prop:"supplier_name","show-overflow-tooltip":""}),e(t,{label:"\u4F9B\u8D27\u4EF7",prop:"purchase","show-overflow-tooltip":""}),e(t,{label:"\u6570\u91CF",prop:"nums","show-overflow-tooltip":""}),e(t,{label:"\u4EF7\u503C",prop:"total_price","show-overflow-tooltip":""}),a(r).is_pay==0?(p(),f(t,{key:0,label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:u(({row:l})=>[l.is_pay==0?(p(),f(y,{key:0,type:"primary",link:"",onClick:K=>b(l)},{default:u(()=>o[2]||(o[2]=[S(" \u7ED3\u7B97 ")])),_:2},1032,["onClick"])):d("",!0)]),_:1})):d("",!0)]),_:1},8,["data"])]),a(s).lists.length<a(s).count?(p(),_("div",$,[e(V,{modelValue:a(s),"onUpdate:modelValue":o[0]||(o[0]=l=>w(s)?s.value=l:null),onChange:a(m)},null,8,["modelValue","onChange"])])):d("",!0)])]),_:1},8,["modelValue"])])}}});export{X as _};
