1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
| <script lang="ts" setup>
| import type { VxeTableGridOptions } from '#/adapter/vxe-table';
| import type { MallBrokerageUserApi } from '#/api/mall/trade/brokerage/user';
|
| import { useVbenModal } from '..\..\..\..\..\..\packages\effects\common-ui\src';
|
| import { useVbenVxeGrid } from '#/adapter/vxe-table';
| import { getBrokerageUserPage } from '#/api/mall/trade/brokerage/user';
|
| import { useUserListColumns, useUserListFormSchema } from '../data';
|
| defineOptions({ name: 'BrokerageUserListModal' });
|
| const [Modal, modalApi] = useVbenModal({});
|
| const [Grid] = useVbenVxeGrid({
| formOptions: {
| schema: useUserListFormSchema(),
| },
| gridOptions: {
| columns: useUserListColumns(),
| height: '600',
| keepSource: true,
| proxyConfig: {
| ajax: {
| query: async ({ page }, formValues) => {
| return await getBrokerageUserPage({
| pageNo: page.currentPage,
| pageSize: page.pageSize,
| bindUserId: modalApi.getData().id,
| ...formValues,
| });
| },
| },
| },
| rowConfig: {
| keyField: 'id',
| isHover: true,
| },
| toolbarConfig: {
| refresh: true,
| search: true,
| },
| } as VxeTableGridOptions<MallBrokerageUserApi.BrokerageUser>,
| });
| </script>
|
| <template>
| <Modal title="推广人列表" class="w-3/5">
| <Grid />
| </Modal>
| </template>
|
|