niucloud-admin/niucloud/public/admin/assets/sms_records-c9e97bff.js
全栈小学生 d44fd63229 update admin
2023-06-05 09:26:58 +08:00

2 lines
6.1 KiB
JavaScript

import"./base-962c0c23.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./index-5cfb4637.js";import"./el-tooltip-58212670.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import{t}from"./index-2af60c2e.js";import{c as I,f as M}from"./notice-e0d624c0.js";import{_ as O}from"./notice-records-info.vue_vue_type_script_setup_true_lang-b5eec733.js";import{u as H}from"./vue-router-79053937.js";import{E as K}from"./index-93f2c618.js";import{a as q,E as G}from"./index-61c777fa.js";import{a as A,b as J,E as Q}from"./index-b933df38.js";import{E as W}from"./index-2f8bd49f.js";import{E as X}from"./index-bba9e58c.js";import{E as Z}from"./index-69523418.js";import{a as ee,E as te}from"./index-92e1b5d5.js";import{E as ae}from"./index-100b1469.js";import{v as oe}from"./directive-c0c3e9a3.js";import{d as le,M as D,r as V,b as n,e as d,q as o,p as i,f,x as s,u as l,F as L,t as N,m as y,v as k,L as re,C as E}from"./runtime-core.esm-bundler-dc7a07d7.js";import"./el-overlay-60700377.js";import"./event-ff03ec12.js";import"./index-5d86eb33.js";import"./focus-trap-b8b5a003.js";import"./el-radio-bfd4b1ad.js";import"./storage-abe718b1.js";import"./index-8bcaafa6.js";import"./index-7a123a20.js";import"./_plugin-vue_export-helper-c27b6911.js";import"./el-avatar-3bb47ce2.js";import"./index-d57cc47d.js";import"./common-6291c908.js";import"./common-2cf17469.js";import"./_Uint8Array-6ff3cafa.js";import"./_initCloneObject-28e6bdaa.js";import"./index-4f5c40a5.js";import"./strings-4868a118.js";import"./isEqual-c7d5e6d9.js";import"./flatten-d5d1dc97.js";import"./index-179d7e6f.js";import"./index-df51d91a.js";import"./_isIterateeCall-c579b126.js";const ie={class:"main-container"},ne={class:"flex justify-between items-center"},se={class:"text-[24px]"},me={class:"mt-[10px]"},pe={key:0},ce={key:1},de={key:2},ue={class:"mt-[16px] flex justify-end"},ft=le({__name:"sms_records",setup(_e){const T=H().meta.title,e=D({page:1,limit:10,total:0,loading:!0,data:[],searchParam:{key:"",receiver:"",create_time:[]}}),h=D({buyer:{label:t("buyerNotice"),list:[]},seller:{label:t("sellerNotice"),list:[]}});(async()=>{await I().then(m=>{Object.keys(m.data).forEach(a=>{const b=m.data[a],p={value:a,name:b.name};b.receiver_type==1?h.buyer.list.push(p):h.seller.list.push(p)})}).catch(()=>{})})();const w=V(),u=(m=1)=>{e.loading=!0,e.page=m,M({page:e.page,limit:e.limit,...e.searchParam}).then(a=>{e.loading=!1,e.data=a.data.data,e.total=a.data.total}).catch(()=>{e.loading=!1})};u();const v=V(null),F=m=>{v.value.setFormData(m),v.value.showDialog=!0};return(m,a)=>{const b=K,p=q,x=A,z=J,B=Q,S=W,g=X,U=G,P=Z,c=ee,$=te,j=ae,R=oe;return n(),d("div",ie,[o(P,{class:"box-card !border-none",shadow:"never"},{default:i(()=>[f("div",ne,[f("span",se,s(l(T)),1)]),o(P,{class:"box-card !border-none my-[10px] table-search-wrap",shadow:"never"},{default:i(()=>[o(U,{inline:!0,model:e.searchParam,ref_key:"searchFormRef",ref:w},{default:i(()=>[o(p,{label:l(t)("searchReceiver"),prop:"receiver"},{default:i(()=>[o(b,{modelValue:e.searchParam.receiver,"onUpdate:modelValue":a[0]||(a[0]=r=>e.searchParam.receiver=r),placeholder:l(t)("receiverPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),o(p,{label:l(t)("noticeKey"),prop:"key"},{default:i(()=>[o(B,{modelValue:e.searchParam.key,"onUpdate:modelValue":a[1]||(a[1]=r=>e.searchParam.key=r),clearable:"",placeholder:l(t)("groupIdPlaceholder"),class:"input-width"},{default:i(()=>[o(x,{label:l(t)("selectPlaceholder"),value:""},null,8,["label"]),(n(!0),d(L,null,N(h,(r,_)=>(n(),y(z,{key:_,label:r.label},{default:i(()=>[(n(!0),d(L,null,N(r.list,(C,Y)=>(n(),y(x,{label:C.name,value:C.value,key:Y},null,8,["label","value"]))),128))]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),o(p,{label:l(t)("createTime"),prop:"create_time"},{default:i(()=>[o(S,{modelValue:e.searchParam.create_time,"onUpdate:modelValue":a[2]||(a[2]=r=>e.searchParam.create_time=r),type:"datetimerange","value-format":"YYYY-MM-DD HH:mm:ss","start-placeholder":l(t)("startDate"),"end-placeholder":l(t)("endDate")},null,8,["modelValue","start-placeholder","end-placeholder"])]),_:1},8,["label"]),o(p,null,{default:i(()=>[o(g,{type:"primary",onClick:a[3]||(a[3]=r=>u())},{default:i(()=>[k(s(l(t)("search")),1)]),_:1}),o(g,{onClick:a[4]||(a[4]=r=>{var _;return(_=w.value)==null?void 0:_.resetFields()})},{default:i(()=>[k(s(l(t)("reset")),1)]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),f("div",me,[re((n(),y($,{data:e.data,size:"large"},{empty:i(()=>[f("span",null,s(e.loading?"":l(t)("emptyData")),1)]),default:i(()=>[o(c,{prop:"name",label:l(t)("noticeKey"),"min-width":"120"},null,8,["label"]),o(c,{prop:"notice_type",label:l(t)("noticeType"),"min-width":"120"},{default:i(({row:r})=>[r.notice_type=="sms"?(n(),d("div",pe,s(l(t)("sms")),1)):E("",!0),r.notice_type=="wechat"?(n(),d("div",ce,s(l(t)("wechat")),1)):E("",!0),r.notice_type=="weapp"?(n(),d("div",de,s(l(t)("weapp")),1)):E("",!0)]),_:1},8,["label"]),o(c,{prop:"nickname",label:l(t)("nickname"),"min-width":"120"},null,8,["label"]),o(c,{prop:"receiver",label:l(t)("receiver"),"min-width":"120"},null,8,["label"]),o(c,{prop:"create_time",label:l(t)("createTime"),"min-width":"140"},null,8,["label"]),o(c,{label:l(t)("operation"),fixed:"right",width:"100"},{default:i(({row:r})=>[o(g,{type:"primary",link:"",onClick:_=>F(r)},{default:i(()=>[k(s(l(t)("info")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"])),[[R,e.loading]]),f("div",ue,[o(j,{"current-page":e.page,"onUpdate:currentPage":a[5]||(a[5]=r=>e.page=r),"page-size":e.limit,"onUpdate:pageSize":a[6]||(a[6]=r=>e.limit=r),layout:"total, sizes, prev, pager, next, jumper",total:e.total,onSizeChange:a[7]||(a[7]=r=>u()),onCurrentChange:u},null,8,["current-page","page-size","total"])])]),o(O,{ref_key:"recordsDialog",ref:v,onComplete:u},null,512)]),_:1})])}}});export{ft as default};