From 6827855b78449b3c98cc83bce028f2cf981850a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=BF=A0=E6=9E=97?= <170083662@qq.com> Date: Thu, 12 Mar 2026 22:24:58 +0800 Subject: [PATCH] =?UTF-8?q?feat(credit):=20=E6=B7=BB=E5=8A=A0=E4=BC=81?= =?UTF-8?q?=E4=B8=9A=E5=AE=A2=E6=88=B7=E5=AF=BC=E5=85=A5=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在CreditCompanyParam接口中新增type和isCustomer字段 - 实现importCustomer API方法用于导入客户Excel文件 - 创建credit-company-import组件实现企业批量导入功能 - 开发credit-company-related-import组件用于企业详情子表导入 - 添加creditCompanyEdit组件提供企业信息编辑功能 - 集成导入功能到客户管理页面并更新搜索组件 - 配置表格列展示企业详细信息并设置滚动宽度 - 实现导入模板下载和文件类型验证功能 --- .env.development | 2 +- a.html | 62 + src/api/credit/creditCompany/index.ts | 21 + src/api/credit/creditCompany/model/index.ts | 3 +- .../components/credit-company-import.vue | 93 + .../credit-company-related-import.vue | 107 + .../customer/components/creditCompanyEdit.vue | 612 +++++ .../customer/components/creditCompanyInfo.vue | 2139 +++++++++++++++++ .../credit/customer/components/search.vue | 103 + src/views/credit/customer/index.vue | 631 +++++ 10 files changed, 3771 insertions(+), 2 deletions(-) create mode 100644 a.html create mode 100644 src/views/credit/customer/components/credit-company-import.vue create mode 100644 src/views/credit/customer/components/credit-company-related-import.vue create mode 100644 src/views/credit/customer/components/creditCompanyEdit.vue create mode 100644 src/views/credit/customer/components/creditCompanyInfo.vue create mode 100644 src/views/credit/customer/components/search.vue create mode 100644 src/views/credit/customer/index.vue diff --git a/.env.development b/.env.development index 213846b..ecb9bfb 100644 --- a/.env.development +++ b/.env.development @@ -1,5 +1,5 @@ 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 diff --git a/a.html b/a.html new file mode 100644 index 0000000..99610a0 --- /dev/null +++ b/a.html @@ -0,0 +1,62 @@ +

桂乐淘后台管理手册

+

后台登录信息:

+

地址:https://glt.websoft.top/login
账号:13800010584
验证码:183911

+

一、创建管理员账号

+

(一)创建流程

+

主页-用户管理-设置手机号-角色设置(将该手机号设置为对应的角色权限)-打开管理员开关,即可创建管理员账号-搜索到对应管理员手机号-勾选该账号-重置密码-复制密码给管理员-打开后台登录地址-使用手机号+登录密码+核验码进行登录-登录成功后再自行修改登录密码。

+

 

+

+

+

+

+

 

+

(二)角色管理

+

新建或修改角色-分配权限(按角色需要勾选权限)

+

1.角色设置

+

+

2.角色名称

+

+

+

 

+

二、业务管理(创建商品-创建水票-配送)

+

(一)商品创建流程

+

新增或编辑商品,按字段填写或上传商品信息,保存后即可(可自主管理上下架及商品排序),在商品管理模块添加的是普通的快递商品,不属于水票套票

+

+

+

 

+

(二)水票套票创建及配送

+

基于商品管理里的商品信息,进入水票-模板管理-填写模板规则

+

+

+

+

+

(三)配送

+

用户购买水票后,系统自动释放水票模板的首期水票,并自动生成配送订单到用户指定地址(须在电子围栏内)

+

配送员添加:接单-配送员管理-新增/修改配送员信息

+

+

+

+

 

+

 

+

 

+

三、分销

+

(一)分销用户

+

+

(二)推荐关系

+

+

(三)分销订单

+

+

用户操作手册

+

一、水票购买

+

用户可按指引购买水票,选择地址时,如不在电子围栏范围内,无法付款配送。

+

 

+

二、我的水票

+

用户查看自己购买过的水票明细及使用、释放情况等

+

+

 

+

立即送水

+

用户查看自己购买过的水票明细及使用、释放情况等

+

   

+

三、分享中心

+

用户查看自己的推广佣金情况、推广的用户列表,申请提现等

+

 

diff --git a/src/api/credit/creditCompany/index.ts b/src/api/credit/creditCompany/index.ts index f76d783..1dadcc1 100644 --- a/src/api/credit/creditCompany/index.ts +++ b/src/api/credit/creditCompany/index.ts @@ -123,6 +123,27 @@ export async function importCreditCompany(file: File) { return Promise.reject(new Error(res.data.message)); } +/** + * 导入客户 + */ +export async function importCustomer(file: File) { + const formData = new FormData(); + formData.append('file', file); + const res = await request.post>( + '/credit/credit-company/import', + formData, + { + headers: { + 'Content-Type': 'multipart/form-data' + } + } + ); + if (res.data.code === 0) { + return res.data.message; + } + return Promise.reject(new Error(res.data.message)); +} + /** * 根据企业匹配名称查询关联信息 */ diff --git a/src/api/credit/creditCompany/model/index.ts b/src/api/credit/creditCompany/model/index.ts index 79ddaa5..f009b6b 100644 --- a/src/api/credit/creditCompany/model/index.ts +++ b/src/api/credit/creditCompany/model/index.ts @@ -183,7 +183,8 @@ export interface CreditCompany { */ export interface CreditCompanyParam extends PageParam { userId?: number; - + type?: number; + isCustomer?: number; id?: number; keywords?: string; } diff --git a/src/views/credit/customer/components/credit-company-import.vue b/src/views/credit/customer/components/credit-company-import.vue new file mode 100644 index 0000000..5e03179 --- /dev/null +++ b/src/views/credit/customer/components/credit-company-import.vue @@ -0,0 +1,93 @@ + + + + diff --git a/src/views/credit/customer/components/credit-company-related-import.vue b/src/views/credit/customer/components/credit-company-related-import.vue new file mode 100644 index 0000000..ab10d5a --- /dev/null +++ b/src/views/credit/customer/components/credit-company-related-import.vue @@ -0,0 +1,107 @@ + + + + diff --git a/src/views/credit/customer/components/creditCompanyEdit.vue b/src/views/credit/customer/components/creditCompanyEdit.vue new file mode 100644 index 0000000..397c828 --- /dev/null +++ b/src/views/credit/customer/components/creditCompanyEdit.vue @@ -0,0 +1,612 @@ + + + + diff --git a/src/views/credit/customer/components/creditCompanyInfo.vue b/src/views/credit/customer/components/creditCompanyInfo.vue new file mode 100644 index 0000000..147e1ff --- /dev/null +++ b/src/views/credit/customer/components/creditCompanyInfo.vue @@ -0,0 +1,2139 @@ + + + + + + diff --git a/src/views/credit/customer/components/search.vue b/src/views/credit/customer/components/search.vue new file mode 100644 index 0000000..b325a18 --- /dev/null +++ b/src/views/credit/customer/components/search.vue @@ -0,0 +1,103 @@ + + + + diff --git a/src/views/credit/customer/index.vue b/src/views/credit/customer/index.vue new file mode 100644 index 0000000..5ec0d5f --- /dev/null +++ b/src/views/credit/customer/index.vue @@ -0,0 +1,631 @@ + + + + + + +