ERP-admin/build/admin/assets/index.9c79e746.js

2 lines
9.9 KiB
JavaScript

import{Y as de,Z as _e,U as ce,V as fe,k as ve,K as ye,L as Be,D as Ee,C as Fe,w as be,F as Ce,T as De,O as ke,Q as we,G as he,R as ge}from"./element-plus.bccb9376.js";import{_ as Ve}from"./index.vue_vue_type_script_setup_true_name_userLists_lang.948bdc77.js";import{_ as Se}from"./index.vue_vue_type_script_setup_true_lang.120de7ce.js";import{_ as $e}from"./index.vue_vue_type_script_setup_true_lang.2914ee54.js";import{f as Ue,b as Re}from"./index.383cb31f.js";import{u as xe}from"./usePaging.6a6670f9.js";import{u as Ae}from"./useDictOptions.a4ceb670.js";import{i as Le,b as Ie,j as Pe,k as Te,l as Ne}from"./supplier.ab7d33cd.js";import{d as Z,s as K,r as v,Z as je,af as Ge,ap as Oe,o as s,c as U,U as e,L as t,u as a,T as M,a9 as Q,K as m,R as n,M as D,a as R,S as qe,Q as x,j as A,n as L}from"./@vue.18505fe0.js";import"./lodash.466e9fe4.js";import{_ as Ke}from"./edit.vue_vue_type_script_setup_true_name_supplierEdit_lang.10ff669d.js";import{_ as Me}from"./detail.vue_vue_type_script_setup_true_name_brandEdit_lang.a542a10c.js";import"./lodash-es.bdeecbdb.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.fbc6a400.js";import"./@element-plus.edbd5a83.js";import"./dayjs.a6528143.js";import"./@babel.16688d44.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./axios.4905d81f.js";import"./jspdf.54afd842.js";import"./fflate.fca59393.js";import"./vue-router.101084e3.js";import"./pinia.a969beab.js";import"./css-color-function.29b71fa4.js";import"./color.87d313dc.js";import"./clone.a63396d9.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"./vue-plugin-hiprint.a2d84e76.js";import"./jquery.c3f97e49.js";import"./jsbarcode.39151b53.js";import"./socket.io-client.0b5a7289.js";import"./engine.io-client.81030771.js";import"./engine.io-parser.c748e159.js";import"./@socket.io.77accf6a.js";import"./debug.b392f131.js";import"./socket.io-parser.b7256298.js";import"./html2canvas.0f5947bc.js";import"./canvg.a673c4b2.js";import"./core-js.97b94d69.js";import"./raf.407ad6ad.js";import"./performance-now.a710f6e4.js";import"./rgbcolor.20c71161.js";import"./svg-pathdata.eba17832.js";import"./stackblur-canvas.0fb5df18.js";import"./nprogress.3461658b.js";import"./vue-clipboard3.c63182fd.js";import"./clipboard.dd2c63d0.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b0c09b66.js";import"./picker.b20eef45.js";import"./index.5b44360d.js";import"./index.e6088f1a.js";import"./index.c600a185.js";import"./vuedraggable.9f282753.js";import"./vue.e5198d72.js";import"./sortablejs.6fa237f8.js";import"./address.8d3e9e4f.js";const Qe={class:"mt-4"},Ze={class:"flex mt-4 justify-end"},Ye={class:"dialog-footer"},ze=Z({name:"supplierLists"}),pl=Z({...ze,setup(He){const k=K(),V=K(),w=v(!1),S=v(!1),d=je({category_id:"",type_id:"",mer_name:""}),$=v([]),Y=u=>{$.value=u.map(({id:o})=>o)},{dictData:y}=Ae("show_status,mer_category_type,merchat_type,financial_type"),{pager:F,getLists:f,resetParams:z,resetPage:H}=xe({fetchFun:Ne,params:d}),J=async()=>{var u;w.value=!0,await L(),(u=k.value)==null||u.open("add")},W=async u=>{var o,_;w.value=!0,await L(),(o=k.value)==null||o.open("edit"),(_=k.value)==null||_.setFormData(u)},I=async u=>{await Ue.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await Le({id:u}),f()},X=async u=>{var _,C;let o=await Ie({id:u});S.value=!0,await L(),(_=V.value)==null||_.open("edit"),(C=V.value)==null||C.setFormData(o)},b=v(!1),P=v({id:""}),ee=u=>{b.value=!0,P.value=u},te=u=>{Pe({id:P.value.id,uid:u.id}).then(o=>{b.value=!1,f()})},i=v({set_money:"",id:"",type:1}),B=v(!1),le=u=>{i.value.id=u,i.value.set_money="",i.value.type=1,B.value=!0},oe=()=>{if(+i.value.set_money<=0||i.value.set_money=="")return ve.error("\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u91D1\u989D");Te({set_money:+i.value.set_money,id:i.value.id,type:i.value.type}).then(u=>{B.value=!1,f()})};return f(),(u,o)=>{const _=ye,C=Be,E=Ee,h=de,T=Fe,r=be,ae=_e,N=Ce,j=De,ue=Re,p=ke,G=$e,ne=Ge("router-link"),ie=we,se=Se,re=Ve,O=he,q=ce,pe=fe,g=Oe("perms"),me=ge;return s(),U("div",null,[e(j,{class:"!border-none mb-4",shadow:"never"},{default:t(()=>[e(N,{class:"mb-[-16px]",model:a(d),"label-width":"120px"},{default:t(()=>[e(ae,null,{default:t(()=>[e(h,{span:6},{default:t(()=>[e(E,{label:"\u4F9B\u5E94\u5546\u5206\u7C7B",prop:"category_id"},{default:t(()=>[e(C,{modelValue:a(d).category_id,"onUpdate:modelValue":o[0]||(o[0]=l=>a(d).category_id=l),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u4F9B\u5E94\u5546\u7C7B\u578B"},{default:t(()=>[(s(!0),U(M,null,Q(a(y).mer_category_type,(l,c)=>(s(),m(_,{key:c,label:l.name,value:parseInt(l.value)},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(h,{span:6},{default:t(()=>[e(E,{label:"\u4F9B\u5E94\u5546\u7C7B\u578B",prop:"type_id"},{default:t(()=>[e(C,{modelValue:a(d).type_id,"onUpdate:modelValue":o[1]||(o[1]=l=>a(d).type_id=l),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u4F9B\u5E94\u5546\u7C7B\u578B"},{default:t(()=>[(s(!0),U(M,null,Q(a(y).merchat_type,(l,c)=>(s(),m(_,{key:c,label:l.name,value:parseInt(l.value)},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(h,{span:6},{default:t(()=>[e(E,{label:"\u4F9B\u5E94\u5546\u540D\u79F0",prop:"mer_name"},{default:t(()=>[e(T,{modelValue:a(d).mer_name,"onUpdate:modelValue":o[2]||(o[2]=l=>a(d).mer_name=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u4F9B\u5E94\u5546\u540D\u79F0"},null,8,["modelValue"])]),_:1})]),_:1}),e(h,{span:6},{default:t(()=>[e(E,null,{default:t(()=>[e(r,{type:"primary",onClick:a(H)},{default:t(()=>[n("\u67E5\u8BE2")]),_:1},8,["onClick"]),e(r,{onClick:a(z)},{default:t(()=>[n("\u91CD\u7F6E")]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),D((s(),m(j,{class:"!border-none",shadow:"never"},{default:t(()=>[D((s(),m(r,{type:"primary",onClick:J},{icon:t(()=>[e(ue,{name:"el-icon-Plus"})]),default:t(()=>[n(" \u65B0\u589E ")]),_:1})),[[g,["supplier.supplier/add"]]]),D((s(),m(r,{disabled:!a($).length,onClick:o[3]||(o[3]=l=>I(a($)))},{default:t(()=>[n(" \u5220\u9664 ")]),_:1},8,["disabled"])),[[g,["supplier.supplier/delete"]]]),R("div",Qe,[e(ie,{data:a(F).lists,onSelectionChange:Y},{default:t(()=>[e(p,{type:"selection",width:"55"}),e(p,{label:"ID",prop:"id",width:"55"}),e(p,{label:"\u4F9B\u5E94\u5546\u7C7B\u578B",prop:"type_id","show-overflow-tooltip":""},{default:t(({row:l})=>[e(G,{options:a(y).merchat_type,value:l.type_id},null,8,["options","value"])]),_:1}),e(p,{label:"\u4F9B\u5E94\u5546\u540D\u79F0",prop:"mer_name","show-overflow-tooltip":""}),e(p,{label:"\u7ED3\u7B97\u5468\u671F(\u5929)",prop:"settle_cycle","show-overflow-tooltip":""}),e(p,{label:"\u5229\u7387",prop:"interest_rate","show-overflow-tooltip":""}),e(p,{label:"\u4F9B\u5E94\u5546\u5730\u5740",prop:"mer_address","show-overflow-tooltip":""}),e(p,{label:"\u4F9B\u5E94\u5546\u662F\u5426\u7981\u7528",prop:"status"},{default:t(({row:l})=>[e(G,{options:a(y).show_status,value:l.status},null,8,["options","value"])]),_:1}),e(p,{label:"\u63D0\u6210\u6BD4\u4F8B",prop:"commission_rate","show-overflow-tooltip":""}),e(p,{label:"\u4F9B\u5E94\u5546\u624B\u7EED\u8D39\u5355\u72EC\u8BBE\u7F6E",width:"200",prop:"commission_switch"},{default:t(({row:l})=>[n(qe(l.commission_switch?"\u5F00\u542F":"\u5173\u95ED"),1)]),_:1}),e(p,{label:"\u4F9B\u5E94\u5546\u4F59\u989D",prop:"mer_money","show-overflow-tooltip":""}),e(p,{label:"\u64CD\u4F5C",width:"200",fixed:"right"},{default:t(({row:l})=>[D((s(),m(r,{type:"primary",link:"",onClick:c=>W(l)},{default:t(()=>[n(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[g,["supplier.supplier/edit"]]]),D((s(),m(r,{type:"danger",link:"",onClick:c=>I(l.id)},{default:t(()=>[n(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[g,["supplier.supplier/delete"]]]),e(r,{link:"",onClick:c=>X(l.id)},{default:t(()=>[n(" \u8BE6\u60C5 ")]),_:2},1032,["onClick"]),e(r,{link:"",type:"primary"},{default:t(()=>[e(ne,{to:{path:"bindGoods",query:{id:l.id}}},{default:t(()=>[n(" \u5546\u54C1\u7ED1\u5B9A ")]),_:2},1032,["to"])]),_:2},1024),l.uid?x("",!0):(s(),m(r,{key:0,link:"",onClick:c=>ee(l),type:"primary"},{default:t(()=>[n(" \u7ED1\u5B9A\u7528\u6237 ")]),_:2},1032,["onClick"])),e(r,{link:"",onClick:c=>le(l.id)},{default:t(()=>[n(" \u8BBE\u7F6E\u4F59\u989D ")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"])]),R("div",Ze,[e(se,{modelValue:a(F),"onUpdate:modelValue":o[4]||(o[4]=l=>A(F)?F.value=l:null),onChange:a(f)},null,8,["modelValue","onChange"])])]),_:1})),[[me,a(F).loading]]),a(w)?(s(),m(Ke,{key:0,ref_key:"editRef",ref:k,"dict-data":a(y),onSuccess:a(f),onClose:o[5]||(o[5]=l=>w.value=!1)},null,8,["dict-data","onSuccess"])):x("",!0),a(S)?(s(),m(Me,{key:1,ref_key:"detailRef",ref:V,"dict-data":a(y),onSuccess:a(f),onClose:o[6]||(o[6]=l=>S.value=!1)},null,8,["dict-data","onSuccess"])):x("",!0),e(O,{modelValue:a(b),"onUpdate:modelValue":o[7]||(o[7]=l=>A(b)?b.value=l:null),title:"\u7ED1\u5B9A\u7528\u6237",width:"70%"},{default:t(()=>[e(re,{onOnBindUser:te})]),_:1},8,["modelValue"]),e(O,{modelValue:a(B),"onUpdate:modelValue":o[11]||(o[11]=l=>A(B)?B.value=l:null),title:"\u8BBE\u7F6E\u4F59\u989D",width:"500"},{footer:t(()=>[R("div",Ye,[e(r,{onClick:o[10]||(o[10]=l=>B.value=!1)},{default:t(()=>[n("\u53D6\u6D88")]),_:1}),e(r,{type:"primary",onClick:oe},{default:t(()=>[n(" \u786E\u8BA4 ")]),_:1})])]),default:t(()=>[e(N,{model:a(i)},{default:t(()=>[e(E,{label:"\u7C7B\u578B","label-width":100},{default:t(()=>[e(pe,{modelValue:a(i).type,"onUpdate:modelValue":o[8]||(o[8]=l=>a(i).type=l)},{default:t(()=>[e(q,{value:1,label:1},{default:t(()=>[n("\u589E\u52A0")]),_:1}),e(q,{value:2,label:2},{default:t(()=>[n("\u51CF\u5C11")]),_:1})]),_:1},8,["modelValue"])]),_:1}),e(E,{label:"\u91D1\u989D","label-width":100},{default:t(()=>[e(T,{modelValue:a(i).set_money,"onUpdate:modelValue":o[9]||(o[9]=l=>a(i).set_money=l),type:"number",placeholder:"\u8BF7\u8F93\u5165\u91D1\u989D"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue"])])}}});export{pl as default};