```
feat(shopDealerApply): 调整经销商申请页面字段与状态展示 - 新增 `dealerName` 字段用于搜索和展示客户名称 - 将“申请人姓名”搜索项改为“客户名称” - 更新审核状态标签文案:待审核 → 跟进中,已通过 → 已签约,已驳回 → 已取消 - 移除“申请方式”筛选项- 修改“申请时间”为“添加时间”- 表格列结构调整,合并客户信息展示,增加报备人信息- 移除部分操作按钮及导出功能 - 双击行不再触发编辑操作- 启用本地开发环境 API 地址配置```
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
VITE_APP_NAME=后台管理(开发环境)
|
VITE_APP_NAME=后台管理(开发环境)
|
||||||
#VITE_API_URL=http://127.0.0.1:9200/api
|
VITE_API_URL=http://127.0.0.1:9200/api
|
||||||
#VITE_SERVER_API_URL=http://127.0.0.1:8000/api
|
#VITE_SERVER_API_URL=http://127.0.0.1:8000/api
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -43,6 +43,7 @@ export interface ShopDealerApplyParam extends PageParam {
|
|||||||
applyId?: number;
|
applyId?: number;
|
||||||
userId?: number;
|
userId?: number;
|
||||||
realName?: string;
|
realName?: string;
|
||||||
|
dealerName?: string;
|
||||||
mobile?: string;
|
mobile?: string;
|
||||||
refereeId?: number;
|
refereeId?: number;
|
||||||
applyType?: number;
|
applyType?: number;
|
||||||
|
|||||||
@@ -8,10 +8,10 @@
|
|||||||
class="search-form"
|
class="search-form"
|
||||||
@finish="handleSearch"
|
@finish="handleSearch"
|
||||||
>
|
>
|
||||||
<a-form-item label="申请人姓名">
|
<a-form-item label="客户名称">
|
||||||
<a-input
|
<a-input
|
||||||
v-model:value="searchForm.realName"
|
v-model:value="searchForm.dealerName"
|
||||||
placeholder="请输入申请人姓名"
|
placeholder="请输入客户名称"
|
||||||
allow-clear
|
allow-clear
|
||||||
style="width: 160px"
|
style="width: 160px"
|
||||||
/>
|
/>
|
||||||
@@ -26,18 +26,6 @@
|
|||||||
/>
|
/>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|
||||||
<a-form-item label="申请方式">
|
|
||||||
<a-select
|
|
||||||
v-model:value="searchForm.applyType"
|
|
||||||
placeholder="全部方式"
|
|
||||||
allow-clear
|
|
||||||
style="width: 120px"
|
|
||||||
>
|
|
||||||
<a-select-option :value="10">需要审核</a-select-option>
|
|
||||||
<a-select-option :value="20">免审核</a-select-option>
|
|
||||||
</a-select>
|
|
||||||
</a-form-item>
|
|
||||||
|
|
||||||
<a-form-item label="审核状态">
|
<a-form-item label="审核状态">
|
||||||
<a-select
|
<a-select
|
||||||
v-model:value="searchForm.applyStatus"
|
v-model:value="searchForm.applyStatus"
|
||||||
@@ -45,13 +33,13 @@
|
|||||||
allow-clear
|
allow-clear
|
||||||
style="width: 120px"
|
style="width: 120px"
|
||||||
>
|
>
|
||||||
<a-select-option :value="10">待审核</a-select-option>
|
<a-select-option :value="10">跟进中</a-select-option>
|
||||||
<a-select-option :value="20">审核通过</a-select-option>
|
<a-select-option :value="20">已签约</a-select-option>
|
||||||
<a-select-option :value="30">审核驳回</a-select-option>
|
<a-select-option :value="30">已取消</a-select-option>
|
||||||
</a-select>
|
</a-select>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|
||||||
<a-form-item label="申请时间">
|
<a-form-item label="添加时间">
|
||||||
<a-range-picker
|
<a-range-picker
|
||||||
v-model:value="searchForm.dateRange"
|
v-model:value="searchForm.dateRange"
|
||||||
style="width: 240px"
|
style="width: 240px"
|
||||||
@@ -72,50 +60,13 @@
|
|||||||
</a-space>
|
</a-space>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-form>
|
</a-form>
|
||||||
|
|
||||||
<!-- 操作按钮 -->
|
|
||||||
<div class="action-buttons">
|
|
||||||
<a-space>
|
|
||||||
<!-- <a-button type="primary" @click="add" class="ele-btn-icon">-->
|
|
||||||
<!-- <template #icon>-->
|
|
||||||
<!-- <PlusOutlined />-->
|
|
||||||
<!-- </template>-->
|
|
||||||
<!-- 新增申请-->
|
|
||||||
<!-- </a-button>-->
|
|
||||||
<a-button
|
|
||||||
type="primary"
|
|
||||||
ghost
|
|
||||||
:disabled="!selection?.length"
|
|
||||||
@click="batchApprove"
|
|
||||||
class="ele-btn-icon"
|
|
||||||
>
|
|
||||||
<template #icon>
|
|
||||||
<CheckOutlined />
|
|
||||||
</template>
|
|
||||||
批量通过
|
|
||||||
</a-button>
|
|
||||||
<a-button
|
|
||||||
:disabled="!selection?.length"
|
|
||||||
@click="exportData"
|
|
||||||
class="ele-btn-icon"
|
|
||||||
>
|
|
||||||
<template #icon>
|
|
||||||
<ExportOutlined />
|
|
||||||
</template>
|
|
||||||
导出数据
|
|
||||||
</a-button>
|
|
||||||
</a-space>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { reactive } from 'vue';
|
import { reactive } from 'vue';
|
||||||
import {
|
import {
|
||||||
PlusOutlined,
|
SearchOutlined
|
||||||
SearchOutlined,
|
|
||||||
CheckOutlined,
|
|
||||||
ExportOutlined
|
|
||||||
} from '@ant-design/icons-vue';
|
} from '@ant-design/icons-vue';
|
||||||
import type { ShopDealerApplyParam } from '@/api/shop/shopDealerApply/model';
|
import type { ShopDealerApplyParam } from '@/api/shop/shopDealerApply/model';
|
||||||
import dayjs from 'dayjs';
|
import dayjs from 'dayjs';
|
||||||
@@ -166,6 +117,9 @@
|
|||||||
searchParams.startTime = dayjs(searchForm.dateRange[0]).format('YYYY-MM-DD');
|
searchParams.startTime = dayjs(searchForm.dateRange[0]).format('YYYY-MM-DD');
|
||||||
searchParams.endTime = dayjs(searchForm.dateRange[1]).format('YYYY-MM-DD');
|
searchParams.endTime = dayjs(searchForm.dateRange[1]).format('YYYY-MM-DD');
|
||||||
}
|
}
|
||||||
|
if(searchForm.dealerName){
|
||||||
|
searchParams.dealerName = searchForm.dealerName;
|
||||||
|
}
|
||||||
|
|
||||||
emit('search', searchParams);
|
emit('search', searchParams);
|
||||||
};
|
};
|
||||||
@@ -180,20 +134,6 @@
|
|||||||
emit('search', {});
|
emit('search', {});
|
||||||
};
|
};
|
||||||
|
|
||||||
// 新增
|
|
||||||
const add = () => {
|
|
||||||
emit('add');
|
|
||||||
};
|
|
||||||
|
|
||||||
// 批量通过
|
|
||||||
const batchApprove = () => {
|
|
||||||
emit('batchApprove');
|
|
||||||
};
|
|
||||||
|
|
||||||
// 导出数据
|
|
||||||
const exportData = () => {
|
|
||||||
emit('export');
|
|
||||||
};
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
|||||||
@@ -9,7 +9,6 @@
|
|||||||
:customRow="customRow"
|
:customRow="customRow"
|
||||||
tool-class="ele-toolbar-form"
|
tool-class="ele-toolbar-form"
|
||||||
class="sys-org-table"
|
class="sys-org-table"
|
||||||
v-model:selection="selection"
|
|
||||||
>
|
>
|
||||||
<template #toolbar>
|
<template #toolbar>
|
||||||
<search
|
<search
|
||||||
@@ -22,9 +21,22 @@
|
|||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.key === 'applyStatus'">
|
<template v-if="column.key === 'applyStatus'">
|
||||||
<a-tag v-if="record.applyStatus === 10" color="orange">待审核</a-tag>
|
<a-tag v-if="record.applyStatus === 10" color="orange">跟进中</a-tag>
|
||||||
<a-tag v-if="record.applyStatus === 20" color="green">已通过</a-tag>
|
<a-tag v-if="record.applyStatus === 20" color="green">已签约</a-tag>
|
||||||
<a-tag v-if="record.applyStatus === 30" color="red">已驳回</a-tag>
|
<a-tag v-if="record.applyStatus === 30" color="red">已取消</a-tag>
|
||||||
|
</template>
|
||||||
|
<template v-if="column.key === 'customer'">
|
||||||
|
<div class="flex flex-col">
|
||||||
|
<span class="font-medium">{{ record.dealerName }}</span>
|
||||||
|
<span>联系人:{{ record.realName }}</span>
|
||||||
|
<span>联系电话:{{ record.mobile }}</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<template v-if="column.key === 'createTime'">
|
||||||
|
<div class="flex flex-col">
|
||||||
|
<span>{{ record.createTime }}</span>
|
||||||
|
<span>保护期:7天</span>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.key === 'action'">
|
<template v-if="column.key === 'action'">
|
||||||
<a @click="openEdit(record)" class="ele-text-primary">
|
<a @click="openEdit(record)" class="ele-text-primary">
|
||||||
@@ -35,7 +47,7 @@
|
|||||||
<a-divider type="vertical"/>
|
<a-divider type="vertical"/>
|
||||||
<a @click="approveApply(record)" class="ele-text-success">
|
<a @click="approveApply(record)" class="ele-text-success">
|
||||||
<CheckOutlined/>
|
<CheckOutlined/>
|
||||||
通过
|
已签约
|
||||||
</a>
|
</a>
|
||||||
<a-divider type="vertical"/>
|
<a-divider type="vertical"/>
|
||||||
<a @click="rejectApply(record)" class="ele-text-warning">
|
<a @click="rejectApply(record)" class="ele-text-warning">
|
||||||
@@ -135,20 +147,9 @@ const columns = ref<ColumnItem[]>([
|
|||||||
fixed: 'left'
|
fixed: 'left'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '申请人信息',
|
title: '客户名称',
|
||||||
key: 'applicantInfo',
|
dataIndex: 'customer',
|
||||||
align: 'left',
|
key: 'customer',
|
||||||
fixed: 'left',
|
|
||||||
customRender: ({record}) => {
|
|
||||||
return `${record.realName || '-'} (${record.mobile || '-'})`;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '申请方式',
|
|
||||||
dataIndex: 'applyType',
|
|
||||||
key: 'applyType',
|
|
||||||
align: 'center',
|
|
||||||
width: 120,
|
|
||||||
customRender: ({text}) => {
|
customRender: ({text}) => {
|
||||||
const typeMap = {
|
const typeMap = {
|
||||||
10: {text: '需审核', color: 'orange'},
|
10: {text: '需审核', color: 'orange'},
|
||||||
@@ -159,20 +160,27 @@ const columns = ref<ColumnItem[]>([
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '审核状态',
|
title: '跟进情况',
|
||||||
|
dataIndex: 'comments',
|
||||||
|
key: 'comments',
|
||||||
|
align: 'left'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '报备人信息',
|
||||||
|
key: 'applicantInfo',
|
||||||
|
align: 'left',
|
||||||
|
fixed: 'left',
|
||||||
|
customRender: ({record}) => {
|
||||||
|
return `${record.nickName || '-'} (${record.phone || '-'})`;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '状态',
|
||||||
dataIndex: 'applyStatus',
|
dataIndex: 'applyStatus',
|
||||||
key: 'applyStatus',
|
key: 'applyStatus',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
width: 120
|
width: 120
|
||||||
},
|
},
|
||||||
{
|
|
||||||
title: '推荐人',
|
|
||||||
dataIndex: 'refereeId',
|
|
||||||
key: 'refereeId',
|
|
||||||
align: 'center',
|
|
||||||
width: 100,
|
|
||||||
customRender: ({text}) => text ? `ID: ${text}` : '无'
|
|
||||||
},
|
|
||||||
// {
|
// {
|
||||||
// title: '申请时间',
|
// title: '申请时间',
|
||||||
// dataIndex: 'applyTime',
|
// dataIndex: 'applyTime',
|
||||||
@@ -189,29 +197,21 @@ const columns = ref<ColumnItem[]>([
|
|||||||
// customRender: ({ text }) => text ? toDateString(new Date(text), 'yyyy-MM-dd HH:mm') : '-'
|
// customRender: ({ text }) => text ? toDateString(new Date(text), 'yyyy-MM-dd HH:mm') : '-'
|
||||||
// },
|
// },
|
||||||
{
|
{
|
||||||
title: '驳回原因',
|
title: '添加时间',
|
||||||
dataIndex: 'rejectReason',
|
|
||||||
key: 'rejectReason',
|
|
||||||
align: 'left',
|
|
||||||
ellipsis: true,
|
|
||||||
customRender: ({text}) => text || '-'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '创建时间',
|
|
||||||
dataIndex: 'createTime',
|
dataIndex: 'createTime',
|
||||||
key: 'createTime',
|
key: 'createTime',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
sorter: true,
|
sorter: true,
|
||||||
ellipsis: true
|
ellipsis: true
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '操作',
|
|
||||||
key: 'action',
|
|
||||||
fixed: 'right',
|
|
||||||
align: 'center',
|
|
||||||
width: 380,
|
|
||||||
hideInSetting: true
|
|
||||||
}
|
}
|
||||||
|
// {
|
||||||
|
// title: '操作',
|
||||||
|
// key: 'action',
|
||||||
|
// fixed: 'right',
|
||||||
|
// align: 'center',
|
||||||
|
// width: 380,
|
||||||
|
// hideInSetting: true
|
||||||
|
// }
|
||||||
]);
|
]);
|
||||||
|
|
||||||
/* 搜索 */
|
/* 搜索 */
|
||||||
@@ -416,7 +416,7 @@ const customRow = (record: ShopDealerApply) => {
|
|||||||
},
|
},
|
||||||
// 行双击事件
|
// 行双击事件
|
||||||
onDblclick: () => {
|
onDblclick: () => {
|
||||||
openEdit(record);
|
// openEdit(record);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user