2023-11-15 15:57:04 +08:00

2 lines
5.4 KiB
JavaScript

/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./index-7eafba5f.js";/* empty css *//* empty css *//* empty css */import"./el-tooltip-4ed993c7.js";/* empty css */import{a as T,E as $}from"./el-form-item-1b16c9fc.js";/* empty css */import{t as o}from"./index-0ca94763.js";import{_ as S}from"./delivery-personnel-edit.vue_vue_type_style_index_0_lang-25ed403c.js";import{n as M,o as R}from"./delivery-853cfc36.js";import{u as j,a as U}from"./vue-router-48fdc1e3.js";import{E as I}from"./index-ee5275c6.js";import{E as A}from"./index-c5914bde.js";import{E as L}from"./index-e27c3bb0.js";import{E as O}from"./index-9ecd3f93.js";import{a as q,E as G}from"./index-fe3867fe.js";import{E as H}from"./index-21f38393.js";import{v as J}from"./directive-64fb15dc.js";import{d as K,O as Q,r as b,e as y,f as W,y as a,x as i,g as n,u as l,B as m,A as u,M as X,v as Y}from"./plugin-vue_export-helper-85a4d40b.js";import"./common-c3be41fd.js";import"./index-cf9a2dd7.js";import"./index-bcd7a424.js";import"./index-e513479b.js";import"./el-main-86eb724f.js";import"./_plugin-vue_export-helper-c27b6911.js";import"./index-b9e5f5cb.js";import"./el-overlay-08181e74.js";import"./event-f85d77b0.js";import"./index-313cd2ce.js";import"./focus-trap-64c402c5.js";import"./index-1ad115d7.js";import"./index-de1d3b53.js";import"./index-d469ae66.js";import"./index-4d8f36c6.js";import"./index-ebc73046.js";import"./_baseClone-3dbf39d6.js";import"./aria-adfa05c5.js";import"./validator-bcf701e4.js";import"./index-95b00894.js";import"./isEqual-0b9509fd.js";import"./flatten-749195f8.js";import"./_isIterateeCall-47526406.js";import"./debounce-6c3123a6.js";import"./index-bd04154b.js";import"./index-4601cf3b.js";import"./index-99b65a15.js";import"./strings-53351eda.js";const Z={class:"main-container"},ee={class:"flex justify-between items-center"},te={class:"detail-head !m-0"},oe=n("span",{class:"iconfont iconxiangzuojiantou !text-xs"},null,-1),ae={class:"ml-[1px]"},le=n("span",{class:"adorn"},"|",-1),re={class:"right"},ie={class:"mt-[10px]"},ne={class:"mt-[16px] flex justify-end"},pt=K({__name:"staff",setup(se){const x=j(),E=U(),C=x.meta.title,e=Q({page:1,limit:10,total:0,loading:!1,data:[],searchParam:{deliver_name:"",deliver_mobile:""}}),v=b(),p=(s=1)=>{e.loading=!0,e.page=s,M({page:e.page,limit:e.limit,...e.searchParam}).then(t=>{e.loading=!1,e.data=t.data.data,e.total=t.data.total}).catch(()=>{e.loading=!1})};p();const d=b(null),k=()=>{d.value.setFormData(),d.value.showDialog=!0},D=s=>{d.value.setFormData(s),d.value.showDialog=!0},P=s=>{I.confirm(o("deliverDeleteTips"),o("warning"),{confirmButtonText:o("confirm"),cancelButtonText:o("cancel"),type:"warning"}).then(()=>{R(s).then(()=>{p()}).catch(()=>{})})},w=s=>{s&&(s.resetFields(),p())};return(s,t)=>{const c=A,g=L,_=T,B=$,h=O,f=q,F=G,V=H,z=J;return y(),W("div",Z,[a(h,{class:"box-card !border-none",shadow:"never"},{default:i(()=>[n("div",ee,[n("div",te,[n("div",{class:"left",onClick:t[0]||(t[0]=r=>l(E).push("/shop/order/delivery"))},[oe,n("span",ae,m(l(o)("returnToPreviousPage")),1)]),le,n("span",re,m(l(C)),1)]),a(c,{type:"primary",onClick:k},{default:i(()=>[u(m(l(o)("addDeliveryPersonnel")),1)]),_:1})]),a(h,{class:"box-card !border-none my-[10px] table-search-wrap",shadow:"never"},{default:i(()=>[a(B,{inline:!0,model:e.searchParam,ref_key:"searchFormRef",ref:v},{default:i(()=>[a(_,{label:l(o)("deliverName"),prop:"deliver_name"},{default:i(()=>[a(g,{modelValue:e.searchParam.deliver_name,"onUpdate:modelValue":t[1]||(t[1]=r=>e.searchParam.deliver_name=r),placeholder:l(o)("deliverNamePlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(_,{label:l(o)("deliverMobile"),prop:"deliver_mobile"},{default:i(()=>[a(g,{modelValue:e.searchParam.deliver_mobile,"onUpdate:modelValue":t[2]||(t[2]=r=>e.searchParam.deliver_mobile=r),placeholder:l(o)("deliverMobilePlaceholder"),onkeyup:"this.value = this.value.replace(/[^\\d]/g,'');"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(_,null,{default:i(()=>[a(c,{type:"primary",onClick:t[3]||(t[3]=r=>p())},{default:i(()=>[u(m(l(o)("search")),1)]),_:1}),a(c,{onClick:t[4]||(t[4]=r=>w(v.value))},{default:i(()=>[u(m(l(o)("reset")),1)]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),n("div",ie,[X((y(),Y(F,{data:e.data,ref:"tableRef",size:"large"},{empty:i(()=>[n("span",null,m(e.loading?"":l(o)("emptyData")),1)]),default:i(()=>[a(f,{prop:"deliver_name",label:l(o)("deliverName")},null,8,["label"]),a(f,{prop:"deliver_mobile",label:l(o)("deliverMobile")},null,8,["label"]),a(f,{label:l(o)("operation"),fixed:"right",align:"right",width:"120"},{default:i(({row:r})=>[a(c,{type:"primary",link:"",onClick:N=>D(r)},{default:i(()=>[u(m(l(o)("edit")),1)]),_:2},1032,["onClick"]),a(c,{type:"primary",link:"",onClick:N=>P(r.deliver_id)},{default:i(()=>[u(m(l(o)("delete")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"])),[[z,e.loading]]),n("div",ne,[a(V,{"current-page":e.page,"onUpdate:currentPage":t[5]||(t[5]=r=>e.page=r),"page-size":e.limit,"onUpdate:pageSize":t[6]||(t[6]=r=>e.limit=r),layout:"total, sizes, prev, pager, next, jumper",total:e.total,onSizeChange:t[7]||(t[7]=r=>p()),onCurrentChange:p},null,8,["current-page","page-size","total"])])])]),_:1}),a(S,{ref_key:"editCategoryDialog",ref:d,onComplete:p},null,512)])}}});export{pt as default};