From ed26142bb0d928af1727de1bf1bf6a5fd4a7c140 Mon Sep 17 00:00:00 2001 From: zyna Date: Sat, 11 Nov 2023 23:35:18 +0800 Subject: [PATCH] =?UTF-8?q?crm=E8=81=94=E7=B3=BB=E4=BA=BAinit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/crm/contact/index.ts | 65 ++++ src/router/modules/remaining.ts | 10 + src/views/crm/contact/ContactForm.vue | 348 ++++++++++++++++++ src/views/crm/contact/OwerSelect.vue | 71 ++++ .../crm/contact/detail/ContactBasicInfo.vue | 23 ++ .../crm/contact/detail/ContactDetails.vue | 93 +++++ src/views/crm/contact/detail/index.vue | 147 ++++++++ src/views/crm/contact/index.vue | 333 +++++++++++++++++ 8 files changed, 1090 insertions(+) create mode 100644 src/api/crm/contact/index.ts create mode 100644 src/views/crm/contact/ContactForm.vue create mode 100644 src/views/crm/contact/OwerSelect.vue create mode 100644 src/views/crm/contact/detail/ContactBasicInfo.vue create mode 100644 src/views/crm/contact/detail/ContactDetails.vue create mode 100644 src/views/crm/contact/detail/index.vue create mode 100644 src/views/crm/contact/index.vue diff --git a/src/api/crm/contact/index.ts b/src/api/crm/contact/index.ts new file mode 100644 index 00000000..6ac5a01d --- /dev/null +++ b/src/api/crm/contact/index.ts @@ -0,0 +1,65 @@ +/* + * @Author: zyna + * @Date: 2023-11-05 13:34:41 + * @LastEditTime: 2023-11-11 16:20:19 + * @FilePath: \yudao-ui-admin-vue3\src\api\crm\contact\index.ts + * @Description: + */ +import request from '@/config/axios' + +export interface ContactVO { + name: string + nextTime: Date + mobile: string + telephone: string + email: string + post: string + customerId: number + address: string + remark: string + ownerUserId: string + lastTime: Date + id: number + parentId: number + qq: number + webchat: string + sex: number + policyMakers: boolean + creatorName: string + updateTime?: Date + createTime?: Date + customerName: string +} + +// 查询crm联系人列表 +export const getContactPage = async (params) => { + return await request.get({ url: `/crm/contact/page`, params }) +} + +// 查询crm联系人详情 +export const getContact = async (id: number) => { + return await request.get({ url: `/crm/contact/get?id=` + id }) +} + +// 新增crm联系人 +export const createContact = async (data: ContactVO) => { + return await request.post({ url: `/crm/contact/create`, data }) +} + +// 修改crm联系人 +export const updateContact = async (data: ContactVO) => { + return await request.put({ url: `/crm/contact/update`, data }) +} + +// 删除crm联系人 +export const deleteContact = async (id: number) => { + return await request.delete({ url: `/crm/contact/delete?id=` + id }) +} + +// 导出crm联系人 Excel +export const exportContact = async (params) => { + return await request.download({ url: `/crm/contact/export-excel`, params }) +} +export const simpleAlllist = async () => { + return await request.get({ url: `/crm/contact/simpleAlllist` }) +} diff --git a/src/router/modules/remaining.ts b/src/router/modules/remaining.ts index 58eb1733..ae564fe6 100644 --- a/src/router/modules/remaining.ts +++ b/src/router/modules/remaining.ts @@ -503,6 +503,16 @@ const remainingRouter: AppRouteRecordRaw[] = [ hidden: true }, component: () => import('@/views/crm/customer/detail/index.vue') + }, + { + path: 'contact/detail/:id', + name: 'CrmContactDetail', + meta: { + title: '联系人详情', + noCache: true, + hidden: true + }, + component: () => import('@/views/crm/contact/detail/index.vue') } ] } diff --git a/src/views/crm/contact/ContactForm.vue b/src/views/crm/contact/ContactForm.vue new file mode 100644 index 00000000..94d50299 --- /dev/null +++ b/src/views/crm/contact/ContactForm.vue @@ -0,0 +1,348 @@ + + diff --git a/src/views/crm/contact/OwerSelect.vue b/src/views/crm/contact/OwerSelect.vue new file mode 100644 index 00000000..83dd143b --- /dev/null +++ b/src/views/crm/contact/OwerSelect.vue @@ -0,0 +1,71 @@ + + + diff --git a/src/views/crm/contact/detail/ContactBasicInfo.vue b/src/views/crm/contact/detail/ContactBasicInfo.vue new file mode 100644 index 00000000..68e37d28 --- /dev/null +++ b/src/views/crm/contact/detail/ContactBasicInfo.vue @@ -0,0 +1,23 @@ + + + diff --git a/src/views/crm/contact/detail/ContactDetails.vue b/src/views/crm/contact/detail/ContactDetails.vue new file mode 100644 index 00000000..5091b691 --- /dev/null +++ b/src/views/crm/contact/detail/ContactDetails.vue @@ -0,0 +1,93 @@ + + + diff --git a/src/views/crm/contact/detail/index.vue b/src/views/crm/contact/detail/index.vue new file mode 100644 index 00000000..3ab5778b --- /dev/null +++ b/src/views/crm/contact/detail/index.vue @@ -0,0 +1,147 @@ + + + diff --git a/src/views/crm/contact/index.vue b/src/views/crm/contact/index.vue new file mode 100644 index 00000000..3e0b3526 --- /dev/null +++ b/src/views/crm/contact/index.vue @@ -0,0 +1,333 @@ + + +