1 |
- import{d as q,H as A,r as c,x as B,b as G,a1 as L,o as m,c as W,f as e,B as r,a,a2 as f,G as g,l as b,A as y,F as X,a6 as j,S as E,K as J,_ as O,L as Z,U as $,V as ee,W as le,X as ae}from"./index-24b5bd0d.js";import{_ as te}from"./index.vue_vue_type_script_setup_true_lang-d8bf5c47.js";import{_ as oe}from"./ContentWrap.vue_vue_type_script_setup_true_lang-1e5dab5a.js";import{d as re}from"./formatTime-f52baefd.js";import{d as ie}from"./download-20922b56.js";import{_ as pe,P as H}from"./PartitionSonForm.vue_vue_type_script_setup_true_lang-cc299e64.js";import{u as ne}from"./useMessage-6f610bbd.js";import"./index-15201e14.js";import"./el-card-0b237923.js";import"./Dialog-23d56afa.js";import"./_plugin-vue_export-helper-1b428a4d.js";const se=q({name:"PartitionSon",__name:"index",setup(de){const V=ne(),{t:P}=A(),h=c(!0),k=c([]),S=c(0),t=B({pageNo:1,pageSize:10,userId:void 0,partNo:void 0,price:void 0,hasHit:void 0,afterHitQuota:void 0,size:void 0,createTime:[]}),C=c(),v=c(!1),_=async()=>{h.value=!0;try{const s=await H.getPartitionSonPage(t);k.value=s.list,S.value=s.total}finally{h.value=!1}},p=()=>{t.pageNo=1,_()},I=()=>{C.value.resetFields(),p()},U=c(),z=(s,l)=>{U.value.open(s,l)},D=async()=>{try{await V.exportConfirm(),v.value=!0;const s=await H.exportPartitionSon(t);ie.excel(s,"\u540E\u4EE3\u5206\u533A.xls")}catch{}finally{v.value=!1}};return G(()=>{_()}),(s,l)=>{const d=j,n=E,K=J,w=O,u=Z,Q=$,N=oe,i=ee,T=le,Y=te,x=L("hasPermi"),F=ae;return m(),W(X,null,[e(N,null,{default:r(()=>[e(Q,{class:"-mb-15px",model:a(t),ref_key:"queryFormRef",ref:C,inline:!0,"label-width":"68px"},{default:r(()=>[e(n,{label:"\u7528\u6237ID",prop:"userId"},{default:r(()=>[e(d,{modelValue:a(t).userId,"onUpdate:modelValue":l[0]||(l[0]=o=>a(t).userId=o),placeholder:"\u8BF7\u8F93\u5165\u7528\u6237ID",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u5206\u533A\u7F16\u53F7",prop:"partNo"},{default:r(()=>[e(d,{modelValue:a(t).partNo,"onUpdate:modelValue":l[1]||(l[1]=o=>a(t).partNo=o),placeholder:"\u8BF7\u8F93\u5165\u5206\u533A\u7F16\u53F7",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u4E1A\u7EE9",prop:"price"},{default:r(()=>[e(d,{modelValue:a(t).price,"onUpdate:modelValue":l[2]||(l[2]=o=>a(t).price=o),placeholder:"\u8BF7\u8F93\u5165\u4E1A\u7EE9",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u662F\u5426\u78B0\u649E 0\u4E3A\u672A\u78B0\u649E 1\u4E3A\u5DF2\u78B0\u649E",prop:"hasHit"},{default:r(()=>[e(d,{modelValue:a(t).hasHit,"onUpdate:modelValue":l[3]||(l[3]=o=>a(t).hasHit=o),placeholder:"\u8BF7\u8F93\u5165\u662F\u5426\u78B0\u649E 0\u4E3A\u672A\u78B0\u649E 1\u4E3A\u5DF2\u78B0\u649E",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u78B0\u649E\u540E\u989D\u5EA6",prop:"afterHitQuota"},{default:r(()=>[e(d,{modelValue:a(t).afterHitQuota,"onUpdate:modelValue":l[4]||(l[4]=o=>a(t).afterHitQuota=o),placeholder:"\u8BF7\u8F93\u5165\u78B0\u649E\u540E\u989D\u5EA6",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u662F\u5426\u662F\u5927\u533A 0\u4E3A\u5C0F\u533A 1\u4E3A\u5927\u533A",prop:"size"},{default:r(()=>[e(d,{modelValue:a(t).size,"onUpdate:modelValue":l[5]||(l[5]=o=>a(t).size=o),placeholder:"\u8BF7\u8F93\u5165\u662F\u5426\u662F\u5927\u533A 0\u4E3A\u5C0F\u533A 1\u4E3A\u5927\u533A",clearable:"",onKeyup:f(p,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(n,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:r(()=>[e(K,{modelValue:a(t).createTime,"onUpdate:modelValue":l[6]||(l[6]=o=>a(t).createTime=o),"value-format":"YYYY-MM-DD HH:mm:ss",type:"daterange","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")],class:"!w-240px"},null,8,["modelValue","default-time"])]),_:1}),e(n,null,{default:r(()=>[e(u,{onClick:p},{default:r(()=>[e(w,{icon:"ep:search",class:"mr-5px"}),l[10]||(l[10]=g(" \u641C\u7D22"))]),_:1}),e(u,{onClick:I},{default:r(()=>[e(w,{icon:"ep:refresh",class:"mr-5px"}),l[11]||(l[11]=g(" \u91CD\u7F6E"))]),_:1}),b((m(),y(u,{type:"primary",plain:"",onClick:l[7]||(l[7]=o=>z("create"))},{default:r(()=>[e(w,{icon:"ep:plus",class:"mr-5px"}),l[12]||(l[12]=g(" \u65B0\u589E "))]),_:1})),[[x,["distri:partition-son:create"]]]),b((m(),y(u,{type:"success",plain:"",onClick:D,loading:a(v)},{default:r(()=>[e(w,{icon:"ep:download",class:"mr-5px"}),l[13]||(l[13]=g(" \u5BFC\u51FA "))]),_:1},8,["loading"])),[[x,["distri:partition-son:export"]]])]),_:1})]),_:1},8,["model"])]),_:1}),e(N,null,{default:r(()=>[b((m(),y(T,{data:a(k),stripe:!0,"show-overflow-tooltip":!0},{default:r(()=>[e(i,{label:"\u7528\u6237\u7F16\u53F7",align:"center",prop:"id"}),e(i,{label:"\u7528\u6237ID",align:"center",prop:"userId"}),e(i,{label:"\u5206\u533A\u7F16\u53F7",align:"center",prop:"partNo"}),e(i,{label:"\u4E1A\u7EE9",align:"center",prop:"price"}),e(i,{label:"\u662F\u5426\u78B0\u649E 0\u4E3A\u672A\u78B0\u649E 1\u4E3A\u5DF2\u78B0\u649E",align:"center",prop:"hasHit"}),e(i,{label:"\u5BF9\u78B0\u91D1\u989D",align:"center",prop:"afterHitQuota"}),e(i,{label:"\u5B58\u4F59\u91D1\u989D",align:"center",prop:"afterHitQuota"}),e(i,{label:"\u662F\u5426\u662F\u5927\u533A 0\u4E3A\u5C0F\u533A 1\u4E3A\u5927\u533A",align:"center",prop:"size"}),e(i,{label:"\u521B\u5EFA\u65F6\u95F4",align:"center",prop:"createTime",formatter:a(re),width:"180px"},null,8,["formatter"]),e(i,{label:"\u64CD\u4F5C",align:"center"},{default:r(o=>[b((m(),y(u,{link:"",type:"primary",onClick:M=>z("update",o.row.id)},{default:r(()=>l[14]||(l[14]=[g(" \u7F16\u8F91 ")])),_:2},1032,["onClick"])),[[x,["distri:partition-son:update"]]]),b((m(),y(u,{link:"",type:"danger",onClick:M=>(async R=>{try{await V.delConfirm(),await H.deletePartitionSon(R),V.success(P("common.delSuccess")),await _()}catch{}})(o.row.id)},{default:r(()=>l[15]||(l[15]=[g(" \u5220\u9664 ")])),_:2},1032,["onClick"])),[[x,["distri:partition-son:delete"]]])]),_:1})]),_:1},8,["data"])),[[F,a(h)]]),e(Y,{total:a(S),page:a(t).pageNo,"onUpdate:page":l[8]||(l[8]=o=>a(t).pageNo=o),limit:a(t).pageSize,"onUpdate:limit":l[9]||(l[9]=o=>a(t).pageSize=o),onPagination:_},null,8,["total","page","limit"])]),_:1}),e(pe,{ref_key:"formRef",ref:U,onSuccess:_},null,512)],64)}}});export{se as default};
|