2 lines
6.2 KiB
JavaScript
2 lines
6.2 KiB
JavaScript
import{k as B,J as z,K as J,D as Q,C as Z,w as G,F as H,L as W,M as X,N as Y,O as ee}from"./element-plus.5e1c7f35.js";import{_ as oe}from"./index.vue_vue_type_script_setup_true_lang.bbcdb30d.js";import{b as te}from"./index.a5553a36.js";import{u as ae}from"./usePaging.6a6670f9.js";import{u as le}from"./useDictOptions.0eff167b.js";import{e as ue,f as re,c as se}from"./purchase_order.acfc2116.js";import"./lodash.ded88a20.js";import{_ as ne}from"./edit.vue_vue_type_script_setup_true_name_purchaseOrderEdit_lang.fb13d46a.js";import{a as ie}from"./system_store.3d3d4720.js";import{a as pe}from"./vue-router.101084e3.js";import{d as x,s as me,r as E,Z as de,ap as ce,o as n,c as V,U as e,L as t,u as o,T as _e,a9 as fe,K as c,R as _,M as b,a as k,j as Ee,Q as he}from"./@vue.18505fe0.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.fbc6a400.js";import"./@element-plus.edbd5a83.js";import"./dayjs.bd46d7f4.js";import"./axios.345d042e.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./pinia.a969beab.js";import"./css-color-function.bb8c34b2.js";import"./color.fbd63fe8.js";import"./clone.31a3aa2c.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.e66da42e.js";import"./vue-clipboard3.70972c27.js";import"./clipboard.1a1f8bfc.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b0c09b66.js";import"./index.6bd94c31.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.d9a16ced.js";const Ce={class:"mt-4"},ve={class:"flex mt-4 justify-end"},be=x({name:"purchaseOrderLists"}),no=x({...be,setup(we){const P=me(),w=E(!1),f=E(!1),g=E([]),A=pe(),r=de({store_id:"",order_id:"",is_mer:"",storage:""}),L=(s="")=>{f.value=!0,ie({name:s,page_size:50}).then(a=>{g.value=a.lists,setTimeout(()=>{f.value=!1},300)}).catch(a=>{setTimeout(()=>{f.value=!1},300)})},O=E([]),S=s=>{O.value=s.map(({id:a})=>a)},{dictData:R}=le(""),{pager:p,getLists:h,resetParams:T,resetPage:C}=ae({fetchFun:se,params:r}),U=async()=>{ue().then(s=>{B.success("\u63D0\u4EA4\u6210\u529F")})},N=async()=>{re().then(s=>{B.success("\u63D0\u4EA4\u6210\u529F")})},$=async s=>{A.push({path:"/order/purchase_order/details",query:{id:s.id}})};return h(),(s,a)=>{const i=z,v=J,m=Q,M=Z,d=G,j=H,D=W,F=te,u=X,q=Y,I=oe,y=ce("perms"),K=ee;return n(),V("div",null,[e(D,{class:"!border-none mb-4",shadow:"never"},{default:t(()=>[e(j,{class:"mb-[-16px]",model:o(r),inline:""},{default:t(()=>[e(m,{label:"\u6240\u5C5E\u95E8\u5E97",prop:"store_id"},{default:t(()=>[e(v,{modelValue:o(r).store_id,"onUpdate:modelValue":a[0]||(a[0]=l=>o(r).store_id=l),filterable:"",remote:"","reserve-keyword":"",placeholder:"\u8F93\u5165\u95E8\u5E97\u540D\u79F0\u641C\u7D22","remote-show-suffix":"","remote-method":L,loading:o(f),style:{width:"240px"}},{default:t(()=>[(n(!0),V(_e,null,fe(o(g),l=>(n(),c(i,{key:l.id,label:l.name,value:l.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","loading"])]),_:1}),e(m,{label:"\u5355\u636E\u7F16\u53F7",prop:"order_id"},{default:t(()=>[e(M,{class:"w-[280px]",modelValue:o(r).order_id,"onUpdate:modelValue":a[1]||(a[1]=l=>o(r).order_id=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5355\u636E\u7F16\u53F7"},null,8,["modelValue"])]),_:1}),e(m,{label:"\u7C7B\u578B",prop:"is_mer"},{default:t(()=>[e(v,{class:"w-[280px]",modelValue:o(r).is_mer,"onUpdate:modelValue":a[2]||(a[2]=l=>o(r).is_mer=l),placeholder:"\u8BF7\u9009\u62E9\u7C7B\u578B",onChange:o(C)},{default:t(()=>[e(i,{label:"\u5546\u6237",value:"1"}),e(i,{label:"\u5E73\u53F0",value:"2"})]),_:1},8,["modelValue","onChange"])]),_:1}),e(m,{label:"\u5165\u5E93\u72B6\u6001",prop:"storage"},{default:t(()=>[e(v,{class:"w-[280px]",modelValue:o(r).storage,"onUpdate:modelValue":a[3]||(a[3]=l=>o(r).storage=l),placeholder:"\u8BF7\u9009\u62E9\u5165\u5E93\u72B6\u6001",onChange:o(C)},{default:t(()=>[e(i,{label:"\u672A\u5165\u5E93",value:"0"}),e(i,{label:"\u90E8\u5206\u5165\u5E93",value:"1"}),e(i,{label:"\u5DF2\u5165\u5E93",value:"2"})]),_:1},8,["modelValue","onChange"])]),_:1}),e(m,null,{default:t(()=>[e(d,{type:"primary",onClick:o(C)},{default:t(()=>[_("\u67E5\u8BE2")]),_:1},8,["onClick"]),e(d,{onClick:o(T)},{default:t(()=>[_("\u91CD\u7F6E")]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),b((n(),c(D,{class:"!border-none",shadow:"never"},{default:t(()=>[b((n(),c(d,{type:"primary",onClick:U},{icon:t(()=>[e(F,{name:"el-icon-Plus"})]),default:t(()=>[_(" \u63D0\u4EA4\u4ECA\u65E5\u5546\u6237\u91C7\u8D2D\u8BA2\u5355 ")]),_:1})),[[y,["purchase_order.purchase_order/add"]]]),b((n(),c(d,{type:"primary",onClick:N},{icon:t(()=>[e(F,{name:"el-icon-Plus"})]),default:t(()=>[_(" \u751F\u6210\u4ECA\u65E5\u5E73\u53F0\u91C7\u8D2D\u8BA2\u5355 ")]),_:1})),[[y,["purchase_order.purchase_order/add"]]]),k("div",Ce,[e(q,{data:o(p).lists,onSelectionChange:S},{default:t(()=>[e(u,{type:"selection",width:"55"}),e(u,{label:"\u6240\u5C5E\u5546\u6237",prop:"system_store","show-overflow-tooltip":""}),e(u,{label:"\u5355\u636E\u7F16\u53F7",prop:"order_id","show-overflow-tooltip":""}),e(u,{label:"\u5355\u636E\u91D1\u989D",prop:"total","show-overflow-tooltip":""}),e(u,{label:"\u5B9E\u9645\u91D1\u989D",prop:"actual","show-overflow-tooltip":""}),e(u,{label:"\u5B9E\u6536\u91D1\u989D",prop:"money","show-overflow-tooltip":""}),e(u,{label:"\u662F\u5426\u91C7\u8D2D",prop:"opurchase_name","show-overflow-tooltip":""}),e(u,{label:"\u7C7B\u578B",prop:"mer_name","show-overflow-tooltip":""}),e(u,{label:"\u5165\u5E93\u72B6\u6001",prop:"storage_name","show-overflow-tooltip":""}),e(u,{label:"\u5907\u6CE8\u4FE1\u606F",prop:"data","show-overflow-tooltip":""}),e(u,{label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:t(({row:l})=>[e(d,{type:"primary",link:"",onClick:ge=>$(l)},{default:t(()=>[_(" \u8BE6\u60C5 ")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"])]),k("div",ve,[e(I,{modelValue:o(p),"onUpdate:modelValue":a[4]||(a[4]=l=>Ee(p)?p.value=l:null),onChange:o(h)},null,8,["modelValue","onChange"])])]),_:1})),[[K,o(p).loading]]),o(w)?(n(),c(ne,{key:0,ref_key:"editRef",ref:P,"dict-data":o(R),onSuccess:o(h),onClose:a[5]||(a[5]=l=>w.value=!1)},null,8,["dict-data","onSuccess"])):he("",!0)])}}});export{no as default};
|