diff --git a/src/pages/Work/List/index.tsx b/src/pages/Work/List/index.tsx
index 0ad4609..9b0df54 100644
--- a/src/pages/Work/List/index.tsx
+++ b/src/pages/Work/List/index.tsx
@@ -7,6 +7,7 @@ import RoutePath from '@/routes/routePath';
import { queryWorkList, deleteWork } from '@/services/work';
import { fetchTableData } from '@/utils/table';
import TimeText from '@/components/Typography/TimeText';
+import WorkSelectModal from '@/widget/Work/WorkSelectModal';
const WorkList = () => {
const tableRef = useRef
();
@@ -74,23 +75,28 @@ const WorkList = () => {
},
];
return (
- {
- history.push(RoutePath.WORK.EDIT);
+
+
{
+ history.push(RoutePath.WORK.EDIT);
+ },
},
- },
- ]}
- request={async (params) => {
- return fetchTableData(queryWorkList, params);
- }}
- />
+ ]}
+ request={async (params) => {
+ return fetchTableData(queryWorkList, params);
+ }}
+ />
+
+
);
};
diff --git a/src/routes/index.ts b/src/routes/index.ts
index 81dd357..986575d 100644
--- a/src/routes/index.ts
+++ b/src/routes/index.ts
@@ -16,39 +16,33 @@ export default [
routes: [
{
path: RoutePath.ETH,
- redirect: RoutePath.ADDRESS.LIST,
+ redirect: RoutePath.ETH_ADDRESS.LIST,
hideInMenu: true,
},
{
name: 'ETH地址管理',
- path: RoutePath.ADDRESS.LIST,
- component: './Work/List',
+ path: RoutePath.ETH_ADDRESS.LIST,
+ component: './Eth/Address/List',
},
{
name: 'ETH地址详情',
- path: RoutePath.ADDRESS.EDIT,
+ path: RoutePath.ETH_ADDRESS.EDIT,
hideInMenu: true,
- component: './Work/Edit',
+ component: './Eth/Address/Edit',
},
{
name: 'ETH充值记录',
- path: RoutePath.RECORD.LIST,
- component: './Work/List',
- },
- {
- name: 'ETH充值详情',
- path: RoutePath.RECORD.EDIT,
- hideInMenu: true,
- component: './Work/Edit',
+ path: RoutePath.ETH_RECORD.LIST,
+ component: './Eth/Record/List',
},
{
name: 'ETH币种管理',
- path: RoutePath.CURRENCY.LIST,
+ path: RoutePath.ETH_CURRENCY.LIST,
component: './Work/List',
},
{
name: 'ETH币种详情',
- path: RoutePath.CURRENCY.EDIT,
+ path: RoutePath.ETH_CURRENCY.EDIT,
hideInMenu: true,
component: './Work/Edit',
},
@@ -79,7 +73,7 @@ export default [
},
{
path: '/',
- redirect: RoutePath.WORK.LIST,
+ redirect: RoutePath.ETH_ADDRESS.LIST,
},
{
diff --git a/src/routes/routePath.ts b/src/routes/routePath.ts
index 6a53c47..1594520 100644
--- a/src/routes/routePath.ts
+++ b/src/routes/routePath.ts
@@ -3,15 +3,14 @@ const ETH = '/eth';
const RoutePath = {
LOGIN: '/login',
ETH: ETH,
- ADDRESS: {
+ ETH_ADDRESS: {
LIST: `${ETH}/address`,
EDIT: `${ETH}/address/edit`,
},
- RECORD: {
+ ETH_RECORD: {
LIST: `${ETH}/record`,
- EDIT: `${ETH}/record/edit`,
},
- CURRENCY: {
+ ETH_CURRENCY: {
LIST: `${ETH}/currency`,
EDIT: `${ETH}/currency/edit`,
},
diff --git a/src/services/eth.ts b/src/services/eth.ts
new file mode 100644
index 0000000..d794879
--- /dev/null
+++ b/src/services/eth.ts
@@ -0,0 +1,25 @@
+import request from '@/utils/request';
+
+export const queryAddressList = (data) => {
+ return request.request({
+ url: '/admin/api/v1/address/get',
+ method: 'post',
+ data,
+ });
+};
+
+export const AddAddress = (data) => {
+ return request.request({
+ url: '/admin/api/v1/address/mask',
+ method: 'post',
+ data,
+ });
+};
+
+export const queryRecordList = (data) => {
+ return request.request({
+ url: '/admin/api/v1/records/get',
+ method: 'post',
+ data,
+ });
+};
diff --git a/src/utils/table.ts b/src/utils/table.ts
index d02e49a..47bb6fc 100644
--- a/src/utils/table.ts
+++ b/src/utils/table.ts
@@ -9,8 +9,7 @@ export const fetchTableData = async (
delete params.current;
delete params.pageSize;
const res = (await fetch(params)) || {};
- const data = res.data;
-
+ const data = res;
data?.forEach((n: any) => {
for (const key in formatObj) {
n[key] = n[formatObj[key]];