mirror of
https://gitee.com/niucloud-team/niucloud-admin.git
synced 2026-01-04 04:08:13 +00:00
2 lines
4.3 KiB
JavaScript
2 lines
4.3 KiB
JavaScript
import{g as defineComponent,r as ref,a4 as reactive,m as openBlock,n as createElementBlock,F as createVNode,E as withCtx,q as createBaseVNode,L as toDisplayString,u as unref,a1 as withDirectives,D as createBlock,K as createTextVNode,T as createCommentVNode}from"./base-45eb5090.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./el-tooltip-58212670.js";import"./index-341914e3.js";/* empty css */import{t}from"./index-047041cb.js";import{d as getSmsList}from"./notice-c80eb42c.js";import{_ as _sfc_main$1}from"./sms-ali.vue_vue_type_script_setup_true_lang-3f7d2f10.js";import{_ as _sfc_main$2}from"./sms-tencent.vue_vue_type_script_setup_true_lang-4d8afde8.js";import{u as useRoute}from"./vue-router-fcbaaf02.js";import{a as ElTableColumn,E as ElTable}from"./index-cbbcd330.js";import{E as ElTag}from"./index-201145a4.js";import{E as ElButton}from"./index-25c37860.js";import{E as ElCard}from"./index-fc3020f4.js";import{v as vLoading}from"./directive-9f485fe5.js";import"./el-overlay-616d6124.js";import"./event-4977bef7.js";import"./index-cd1661d3.js";import"./focus-trap-318ae2e0.js";/* empty css */import"./el-radio-2719e44c.js";import"./storage-4159d1ed.js";import"./index-9670e877.js";import"./index-4ce9333e.js";import"./index-3be486d3.js";import"./_plugin-vue_export-helper-c27b6911.js";import"./el-avatar-bc58ad46.js";import"./index-aef37b98.js";import"./common-af78c857.js";import"./common-2cf17469.js";/* empty css */import"./index-c4fd4c9d.js";import"./castArray-df7eff2c.js";import"./_Uint8Array-e584e472.js";import"./_initCloneObject-983ff8c8.js";import"./index-c0090d79.js";import"./isEqual-f877b6c1.js";import"./flatten-0fc8b7eb.js";import"./_isIterateeCall-104f1f93.js";const _hoisted_1={class:"main-container"},_hoisted_2={class:"flex justify-between items-center"},_hoisted_3={class:"text-[20px]"},_hoisted_4={class:"mt-[20px]"},_sfc_main=defineComponent({__name:"sms",setup(__props){const route=useRoute(),pageName=route.meta.title,aliyunDialog=ref(null),tencentDialog=ref(null);let smsTableData=reactive({loading:!0,data:[]});const loadSmsList=()=>{smsTableData.loading=!0,getSmsList().then(i=>{smsTableData.data=i.data,smsTableData.loading=!1}).catch(()=>{smsTableData.loading=!1})};loadSmsList();const editEvent=data=>{eval(data.sms_type+"Dialog.value.setFormData(data)"),eval(data.sms_type+"Dialog.value.showDialog = true;")};return(i,a)=>{const o=ElTableColumn,r=ElTag,s=ElButton,l=ElTable,n=ElCard,m=vLoading;return openBlock(),createElementBlock("div",_hoisted_1,[createVNode(n,{class:"box-card !border-none",shadow:"never"},{default:withCtx(()=>[createBaseVNode("div",_hoisted_2,[createBaseVNode("span",_hoisted_3,toDisplayString(unref(pageName)),1)]),createBaseVNode("div",_hoisted_4,[withDirectives((openBlock(),createBlock(l,{data:unref(smsTableData).data,size:"large"},{empty:withCtx(()=>[createBaseVNode("span",null,toDisplayString(unref(smsTableData).loading?"":unref(t)("emptyData")),1)]),default:withCtx(()=>[createVNode(o,{prop:"name",label:unref(t)("name"),"min-width":"100","show-overflow-tooltip":!0},null,8,["label"]),createVNode(o,{label:unref(t)("isUse"),"min-width":"180",align:"center"},{default:withCtx(({row:e})=>[e.is_use==1?(openBlock(),createBlock(r,{key:0,class:"ml-2",type:"success"},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(t)("statusNormal")),1)]),_:1})):createCommentVNode("",!0),e.is_use==0?(openBlock(),createBlock(r,{key:1,class:"ml-2",type:"error"},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(t)("statusDeactivate")),1)]),_:1})):createCommentVNode("",!0)]),_:1},8,["label"]),createVNode(o,{label:unref(t)("operation"),fixed:"right",width:"100"},{default:withCtx(({row:e})=>[createVNode(s,{type:"primary",link:"",onClick:c=>editEvent(e)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(t)("config")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"])),[[m,unref(smsTableData).loading]])]),createVNode(_sfc_main$1,{ref_key:"aliyunDialog",ref:aliyunDialog,onComplete:a[0]||(a[0]=e=>loadSmsList())},null,512),createVNode(_sfc_main$2,{ref_key:"tencentDialog",ref:tencentDialog,onComplete:a[1]||(a[1]=e=>loadSmsList())},null,512)]),_:1})])}}});export{_sfc_main as default};
|