import{_ as D,__tla as E}from"./ContentWrap.vue_vue_type_script_setup_true_lang-c7ede7df.js";import{d as T,r as y,b as U,a3 as j,o as h,c as A,C as l,f as a,B as t,G as o,k as B,A as F,E as n,a as d,dx as G,F as H,L as K,I as L,K as M,__tla as N}from"./index-92ad187a.js";import{E as O,a as S,__tla as W}from"./el-descriptions-item-809b8296.js";import{_ as q,__tla as z}from"./DictTag.vue_vue_type_script_lang-96bcb962.js";import{_ as J,__tla as Q}from"./ProductForm.vue_vue_type_script_setup_true_lang-e84bdfec.js";import{D as V,__tla as X}from"./dict-221f3e01.js";import{g as Y,__tla as Z}from"./index-bd247ee5.js";let v,$=Promise.all([(()=>{try{return E}catch{}})(),(()=>{try{return N}catch{}})(),(()=>{try{return W}catch{}})(),(()=>{try{return z}catch{}})(),(()=>{try{return Q}catch{}})(),(()=>{try{return X}catch{}})(),(()=>{try{return Z}catch{}})()]).then(async()=>{let i,f;i={class:"flex items-start justify-between"},f={class:"text-xl font-bold"},v=T({__name:"ProductDetailsHeader",props:{product:{}},emits:["refresh"],setup(aa,{emit:b}){const p=y(),x=b,m=y([]);return U(async()=>{m.value=await Y({})}),(r,s)=>{const C=K,I=L,P=M,_=O,R=q,k=S,g=D,w=j("hasPermi");return h(),A(H,null,[l("div",null,[l("div",i,[l("div",null,[a(I,null,{default:t(()=>[a(C,null,{default:t(()=>[l("span",f,o(r.product.name),1)]),_:1})]),_:1})]),l("div",null,[B((h(),F(P,{onClick:s[0]||(s[0]=u=>{return e="update",c=r.product.id,void p.value.open(e,c);var e,c})},{default:t(()=>[n(" \u7F16\u8F91 ")]),_:1})),[[w,["crm:product:update"]]])])])]),a(g,{class:"mt-10px"},{default:t(()=>[a(k,{column:5,direction:"vertical"},{default:t(()=>[a(_,{label:"\u4EA7\u54C1\u7C7B\u522B"},{default:t(()=>{var u,e;return[n(o((e=(u=d(m))==null?void 0:u.find(c=>c.id===r.product.categoryId))==null?void 0:e.name),1)]}),_:1}),a(_,{label:"\u4EA7\u54C1\u5355\u4F4D"},{default:t(()=>[a(R,{type:d(V).CRM_PRODUCT_UNIT,value:r.product.unit},null,8,["type","value"])]),_:1}),a(_,{label:"\u4EA7\u54C1\u4EF7\u683C"},{default:t(()=>[n(o(d(G)(r.product.price))+"\u5143",1)]),_:1}),a(_,{label:"\u4EA7\u54C1\u7F16\u7801"},{default:t(()=>[n(o(r.product.no),1)]),_:1})]),_:1})]),_:1}),a(J,{ref_key:"formRef",ref:p,onSuccess:s[1]||(s[1]=u=>x("refresh"))},null,512)],64)}}})});export{v as _,$ as __tla};
