diff --git a/config/proxy.ts b/config/proxy.ts index 279a12f..e1a47c0 100644 --- a/config/proxy.ts +++ b/config/proxy.ts @@ -13,9 +13,9 @@ export default { // 如果需要自定义本地开发服务器 请取消注释按需调整 dev: { // localhost:8000/api/** -> https://preview.pro.ant.design/api/** - "/admin-api/": { + '/admin-api/': { // 要代理的地址 - target: "http://192.168.1.114:48080", + target: 'http://114.132.60.20:48080', // 配置了这个可以从 http 代理到 https // 依赖 origin 的功能可能需要这个,比如 cookie changeOrigin: true, @@ -27,17 +27,17 @@ export default { */ test: { // localhost:8000/api/** -> https://preview.pro.ant.design/api/** - "/api/": { - target: "https://proapi.azurewebsites.net", + '/api/': { + target: 'https://proapi.azurewebsites.net', changeOrigin: true, - pathRewrite: { "^": "" }, + pathRewrite: { '^': '' }, }, }, pre: { - "/api/": { - target: "your pre url", + '/api/': { + target: 'your pre url', changeOrigin: true, - pathRewrite: { "^": "" }, + pathRewrite: { '^': '' }, }, }, }; diff --git a/src/pages/system/messages/sms/log/config.tsx b/src/pages/system/messages/sms/log/config.tsx index 59f2d12..32a99f8 100644 --- a/src/pages/system/messages/sms/log/config.tsx +++ b/src/pages/system/messages/sms/log/config.tsx @@ -2,6 +2,7 @@ import type { ProColumns, ProDescriptionsItemProps, } from '@ant-design/pro-components'; +import { Space, Tag } from 'antd'; import dayjs from 'dayjs'; import type { SmsLogVO } from '@/services/system/message/sms/log'; export const baseTenantColumns: ProColumns[] = [ @@ -11,6 +12,26 @@ export const baseTenantColumns: ProColumns[] = [ width: 100, hideInSearch: true, // 在搜索表单中隐藏 }, + { + title: '创建时间', + dataIndex: 'createTime', + valueType: 'dateRange', + hideInSearch: true, + search: { + transform: (value) => { + return { + [`createTime[0]`]: dayjs(value[0]) + .startOf('day') + .format('YYYY-MM-DD HH:mm:ss'), + [`createTime[1]`]: dayjs(value[1]) + .endOf('day') + .format('YYYY-MM-DD HH:mm:ss'), + }; + }, + }, + render: (_, record: SmsLogVO) => + dayjs(record.createTime).format('YYYY-MM-DD HH:mm:ss'), + }, { title: '手机号', dataIndex: 'mobile', @@ -24,11 +45,6 @@ export const baseTenantColumns: ProColumns[] = [ title: '发送状态', dataIndex: 'sendStatus', }, - { - title: '发送人名称', - dataIndex: 'templateNickname', - hideInSearch: true, // 在搜索表单中隐藏 - }, { title: '接收状态', @@ -48,10 +64,10 @@ export const baseTenantColumns: ProColumns[] = [ hideInSearch: true, }, { - title: '创建时间', - dataIndex: 'createTime', + title: '发送时间', + dataIndex: 'sendTime', valueType: 'dateRange', - hideInSearch: true, + hideInTable: true, search: { transform: (value) => { return { @@ -117,6 +133,16 @@ export const descriptionsColumns = (): ProDescriptionsItemProps< title: '用户信息', key: 'mobile', dataIndex: 'mobile', + render(dom, record) { + return ( + <> + + {record.mobile} + {record.userId && {record.userId}} + + + ); + }, }, { title: '短信内容',