diff --git a/src/pages/table-list/city-operation/index.tsx b/src/pages/table-list/city-operation/index.tsx
index f410897..29ddb00 100644
--- a/src/pages/table-list/city-operation/index.tsx
+++ b/src/pages/table-list/city-operation/index.tsx
@@ -1,5 +1,13 @@
import { PlusOutlined } from '@ant-design/icons';
-import { ActionType, ProColumns, ProFormInstance, ProFormSelect, ProFormText } from '@ant-design/pro-components';
+import {
+ ActionType,
+ ProColumns,
+ ProFormInstance,
+ ProFormSelect,
+ ProFormText,
+ ProFormDigit,
+ ProFormMoney,
+} from '@ant-design/pro-components';
import { ModalForm, PageContainer, ProTable } from '@ant-design/pro-components';
import '@umijs/max';
import { Button, message } from 'antd';
@@ -95,6 +103,25 @@ const TableList: React.FC = () => {
},
search: false,
},
+ {
+ title: '进群链接',
+ dataIndex: 'groupLink',
+ valueType: 'textarea',
+ search: false,
+ },
+ {
+ title: '可群发数量',
+ dataIndex: 'sendCount',
+ valueType: 'textarea',
+ search: false,
+ },
+ {
+ title: '群代发价格',
+ dataIndex: 'price',
+ valueType: 'textarea',
+ search: false,
+ renderText: cents => (cents ? (cents / 100).toFixed(0) : '-'),
+ },
{
title: '操作',
valueType: 'option',
@@ -162,6 +189,8 @@ const TableList: React.FC = () => {
cityCode: formData.city.value,
cityName: formData.city.label,
groupLink: formData.groupLink,
+ sendCount: formData.sendCount,
+ price: formData.price,
};
console.log('update confirm', formData, params);
try {
@@ -188,6 +217,29 @@ const TableList: React.FC = () => {
rules={[{ required: true, message: '必填项' }]}
/>
+
+ {
+ if (!value) return '0';
+ return `${Math.floor(value / 100)}`;
+ },
+ parser: value => {
+ if (!value) return 0;
+ const numValue = parseInt(value.toString().replace(/[^\d]/g, ''));
+ return numValue * 100;
+ },
+ }}
+ transform={(value, namePath) => {
+ return {
+ [namePath]: value ? Math.round(Number(value)) : 0,
+ };
+ }}
+ />
);
diff --git a/src/services/typings.d.ts b/src/services/typings.d.ts
index 3d8e789..245d832 100644
--- a/src/services/typings.d.ts
+++ b/src/services/typings.d.ts
@@ -355,6 +355,8 @@ declare namespace API {
staffId: number;
cityCode: string;
groupLink: string;
+ sendCount: number;
+ price: number;
id: number;
}
@@ -365,6 +367,8 @@ declare namespace API {
cityName?: string;
cityCode: string;
groupLink: string;
+ sendCount?: number;
+ price?: number;
created?: string;
updated?: string;
}