index-b9e4cdb8.js 4.2 KB

1
  1. import{d as A,I as E,r as s,e as J,k as L,P as M,o as p,c as S,f as a,w as t,a as l,F as U,n as O,q as c,Q as W,m as d,v as m,h as X,x as Y,y as Z,z as $,U as aa,_ as ea,B as ta,C as la,D as ra,G as oa,H as pa,__tla as sa}from"./index-2eab2d23.js";import{_ as na,__tla as _a}from"./index.vue_vue_type_script_setup_true_lang-5730b053.js";import{_ as ia,__tla as ua}from"./ContentWrap.vue_vue_type_script_setup_true_lang-5a63038a.js";import{d as ca,__tla as da}from"./formatTime-41155543.js";import{g as ma,a as fa,d as ya,__tla as ha}from"./property-64c4a36d.js";import{_ as ga,__tla as wa}from"./ValueForm.vue_vue_type_script_setup_true_lang-527afd9a.js";import{u as ba,__tla as ka}from"./useMessage-171aa63e.js";import{__tla as va}from"./index-cc63c3c4.js";import{__tla as xa}from"./el-card-c558f0ec.js";import{__tla as Ca}from"./Dialog-c2716df6.js";import"./_plugin-vue_export-helper-1b428a4d.js";let N,Ia=Promise.all([(()=>{try{return sa}catch{}})(),(()=>{try{return _a}catch{}})(),(()=>{try{return ua}catch{}})(),(()=>{try{return da}catch{}})(),(()=>{try{return ha}catch{}})(),(()=>{try{return wa}catch{}})(),(()=>{try{return ka}catch{}})(),(()=>{try{return va}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return Ca}catch{}})()]).then(async()=>{N=A({name:"ProductPropertyValue",__name:"index",setup(Va){const b=ba(),{t:z}=X(),{params:F}=E(),f=s(!0),k=s(0),v=s([]),r=J({pageNo:1,pageSize:10,propertyId:Number(F.propertyId),name:void 0}),x=s(),C=s([]),n=async()=>{f.value=!0;try{const _=await fa(r);v.value=_.list,k.value=_.total}finally{f.value=!1}},y=()=>{r.pageNo=1,n()},R=()=>{x.value.resetFields(),y()},I=s(),V=(_,o)=>{I.value.open(_,r.propertyId,o)};return L(async()=>{await n(),C.value.push(await ma(r.propertyId))}),(_,o)=>{const q=Y,B=Z,h=$,D=aa,g=ea,i=ta,G=la,P=ia,u=ra,H=oa,K=na,w=M("hasPermi"),Q=pa;return p(),S(U,null,[a(P,null,{default:t(()=>[a(G,{class:"-mb-15px",model:l(r),ref_key:"queryFormRef",ref:x,inline:!0,"label-width":"68px"},{default:t(()=>[a(h,{label:"\u5C5E\u6027\u9879",prop:"propertyId"},{default:t(()=>[a(B,{modelValue:l(r).propertyId,"onUpdate:modelValue":o[0]||(o[0]=e=>l(r).propertyId=e),class:"!w-240px",disabled:""},{default:t(()=>[(p(!0),S(U,null,O(l(C),e=>(p(),c(q,{key:e.id,label:e.name,value:e.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(h,{label:"\u540D\u79F0",prop:"name"},{default:t(()=>[a(D,{modelValue:l(r).name,"onUpdate:modelValue":o[1]||(o[1]=e=>l(r).name=e),placeholder:"\u8BF7\u8F93\u5165\u540D\u79F0",clearable:"",onKeyup:W(y,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),a(h,null,{default:t(()=>[a(i,{onClick:y},{default:t(()=>[a(g,{icon:"ep:search",class:"mr-5px"}),d(" \u641C\u7D22")]),_:1}),a(i,{onClick:R},{default:t(()=>[a(g,{icon:"ep:refresh",class:"mr-5px"}),d(" \u91CD\u7F6E")]),_:1}),m((p(),c(i,{plain:"",type:"primary",onClick:o[2]||(o[2]=e=>V("create"))},{default:t(()=>[a(g,{icon:"ep:plus",class:"mr-5px"}),d(" \u65B0\u589E ")]),_:1})),[[w,["product:property:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),a(P,null,{default:t(()=>[m((p(),c(H,{data:l(v)},{default:t(()=>[a(u,{label:"\u7F16\u53F7",align:"center","min-width":"60",prop:"id"}),a(u,{label:"\u5C5E\u6027\u503C\u540D\u79F0",align:"center","min-width":"150",prop:"name"}),a(u,{label:"\u5907\u6CE8",align:"center",prop:"remark","show-overflow-tooltip":!0}),a(u,{label:"\u521B\u5EFA\u65F6\u95F4",align:"center",prop:"createTime",width:"180",formatter:l(ca)},null,8,["formatter"]),a(u,{label:"\u64CD\u4F5C",align:"center"},{default:t(e=>[m((p(),c(i,{link:"",type:"primary",onClick:T=>V("update",e.row.id)},{default:t(()=>[d(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[w,["product:property:update"]]]),m((p(),c(i,{link:"",type:"danger",onClick:T=>(async j=>{try{await b.delConfirm(),await ya(j),b.success(z("common.delSuccess")),await n()}catch{}})(e.row.id)},{default:t(()=>[d(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[w,["product:property:delete"]]])]),_:1})]),_:1},8,["data"])),[[Q,l(f)]]),a(K,{total:l(k),page:l(r).pageNo,"onUpdate:page":o[3]||(o[3]=e=>l(r).pageNo=e),limit:l(r).pageSize,"onUpdate:limit":o[4]||(o[4]=e=>l(r).pageSize=e),onPagination:n},null,8,["total","page","limit"])]),_:1}),a(ga,{ref_key:"formRef",ref:I,onSuccess:n},null,512)],64)}}})});export{Ia as __tla,N as default};