diff --git a/src/App.vue b/src/App.vue index 6004ba4..26eda7d 100644 --- a/src/App.vue +++ b/src/App.vue @@ -59,3 +59,60 @@ } } + \ No newline at end of file diff --git a/src/api/crmApi.ts b/src/api/crmApi.ts new file mode 100644 index 0000000..6b950f4 --- /dev/null +++ b/src/api/crmApi.ts @@ -0,0 +1,156 @@ +import request from '@/utils/http' + +export class CrmService { + // 客户管理 + //客户列表 + static getcustomerList(params: Api.Common.PaginatingParams) { + return request.get({ + url: '/crm/customer/list', + params + }) + } + // 获取客户列表详情 + static getcustomerdetail(params: any) { + return request.get({ + url: '/crm/customer/detail', + params + }) + } + //添加客户 + static customerAdd(params: any) { + return request.post({ + url: '/crm/customer/add', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //删除客户 + static getcustomerdelete(params: any) { + return request.get({ + url: '/crm/customer/delete', + params + }) + } + //切换等级crm/customer/grade + static customergrade(params: any) { + return request.post({ + url: '/crm/customer/grade', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + + //渠道下拉 + static getChannel() { + return request.get({ + url: '/crm/customer/getChannel' + }) + } + //国家下拉 + static getCountry() { + return request.get({ + url: '/crm/customer/getCountry' + }) + } + //商机 + static getMagnitude() { + return request.get({ + url: '/crm/customer/getMagnitude' + }) + } + //等级 + static getGrade() { + return request.get({ + url: '/crm/customer/getGrade' + }) + } + //标签列表/crm/tagGroup/list + static tagGrouplist() { + return request.get({ + url: '/crm/tagGroup/list' + }) + } + //更新客户标签 /crm/tagGroup/updatePivot + static tagGroupupdatePivot(params: any) { + return request.get({ + url: '/crm/tagGroup/updatePivot', + params + }) + } + //跟进列表crm/follow/list + static getfollowlist(params: any) { + return request.get({ + url: '/crm/follow/list', + params + }) + } + //添加跟进 /crm/follow/add + static followAdd(params: any) { + return request.post({ + url: '/crm/follow/add', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //待跟进 /crm/customer/waitFollow + static waitFollow(params: any) { + return request.get({ + url: '/crm/customer/waitFollow', + params + }) + } +//设置下次跟进时间 followNext crm/customer/followNext +static followNext(params: any) { + return request.post({ + url: '/crm/customer/followNext', + params + // showErrorMessage: false // 不显示错误消息 + }) +} + + //crm 个人信息修改 + static crmuseredit(params: any) { + return request.post({ + url: '/crm/user/edit', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //领取公海crm/customer/claim + static customerclaim(params: any) { + return request.post({ + url: '/crm/customer/claim', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //客户回收 恢复 /crm/customer/restore + static customerrestore(params: any) { + return request.post({ + url: '/crm/customer/restore', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //crm 获取用户信息 common/user/get + static userget() { + return request.get({ + url: '/common/user/get' + }) + } + //修改密码 crm/user/savePassword + static savePassword(params: any) { + return request.post({ + url: '/crm/user/savePassword', + params + // showErrorMessage: false // 不显示错误消息 + }) + } + //首页统计 + static homestatistics(params: any) { + return request.get({ + url: '/crm/customer/statistics', + params + }) + } +} diff --git a/src/api/menuApi.ts b/src/api/menuApi.ts index 811d1b6..925346b 100644 --- a/src/api/menuApi.ts +++ b/src/api/menuApi.ts @@ -5,7 +5,28 @@ import { useUserStore } from '@/store/modules/user' interface MenuResponse { menuList: AppRouteRecord[] } - +// 合并方法 +function mergeRoutes(dynamicRoutes: AppRouteRecord[] = [], staticRoutes: AppRouteRecord[] = []): AppRouteRecord[] { + // 深度合并逻辑 + const merged = [...staticRoutes] + + dynamicRoutes.forEach(dynamicRoute => { + const existingIndex = merged.findIndex(r => r.path === dynamicRoute.path) + if (existingIndex >= 0) { + // 合并children(如果存在) + if (dynamicRoute.children) { + merged[existingIndex].children = [ + ...(merged[existingIndex].children || []), + ...dynamicRoute.children + ] + } + } else { + merged.push(dynamicRoute) + } + }) + + return merged +} // 菜单接口 export const menuService = { async getMenuList(delay = 300): Promise { @@ -17,6 +38,8 @@ export const menuService = { } // 模拟接口返回的菜单数据 const menuData = userStore.info.menu + // 2. 合并静态菜单 + const finalRoutes = mergeRoutes(menuData, asyncRoutes) // 验证菜单数据 if (!menuData || !Array.isArray(menuData) || menuData.length === 0) { ElMessage.error('暂无系统菜单权限') @@ -24,7 +47,7 @@ export const menuService = { } // 处理菜单数据 - const menuList = menuData.map((route: any) => menuDataToRouter(route)) + const menuList = finalRoutes.map((route: any) => menuDataToRouter(route)) // 验证处理后的菜单列表 if (!menuList || menuList.length === 0) { diff --git a/src/components/core/layouts/art-header-bar/index.vue b/src/components/core/layouts/art-header-bar/index.vue index 3c76873..9809942 100644 --- a/src/components/core/layouts/art-header-bar/index.vue +++ b/src/components/core/layouts/art-header-bar/index.vue @@ -156,6 +156,14 @@ -->
    +
  • + + {{ $t('topBar.user.userCenter') }} +
  • +
  • + + 回收站 +
  • + + + + + + + + + + + + + + + + + + + + 提交 + + + + + +
    + +
    +
    + +
    + + + + + \ No newline at end of file diff --git a/src/views/crmpc/customer/Edit.vue b/src/views/crmpc/customer/Edit.vue new file mode 100644 index 0000000..312ffa8 --- /dev/null +++ b/src/views/crmpc/customer/Edit.vue @@ -0,0 +1,221 @@ + + + + + \ No newline at end of file diff --git a/src/views/crmpc/customer/Followadd.vue b/src/views/crmpc/customer/Followadd.vue new file mode 100644 index 0000000..cc1cb8d --- /dev/null +++ b/src/views/crmpc/customer/Followadd.vue @@ -0,0 +1,515 @@ + + + + + \ No newline at end of file diff --git a/src/views/crmpc/customer/Show.vue b/src/views/crmpc/customer/Show.vue new file mode 100644 index 0000000..aff808e --- /dev/null +++ b/src/views/crmpc/customer/Show.vue @@ -0,0 +1,500 @@ + + + + + \ No newline at end of file diff --git a/src/views/crmpc/customer/index.vue b/src/views/crmpc/customer/index.vue new file mode 100644 index 0000000..d485d22 --- /dev/null +++ b/src/views/crmpc/customer/index.vue @@ -0,0 +1,343 @@ + + + + + \ No newline at end of file diff --git a/src/views/crmpc/highseas/index.vue b/src/views/crmpc/highseas/index.vue new file mode 100644 index 0000000..4f39a25 --- /dev/null +++ b/src/views/crmpc/highseas/index.vue @@ -0,0 +1,294 @@ + + + + + diff --git a/src/views/crmpc/home/index.vue b/src/views/crmpc/home/index.vue new file mode 100644 index 0000000..168e4ef --- /dev/null +++ b/src/views/crmpc/home/index.vue @@ -0,0 +1,21 @@ + + + + + + \ No newline at end of file diff --git a/src/views/crmpc/home/style.scss b/src/views/crmpc/home/style.scss new file mode 100644 index 0000000..351c8b4 --- /dev/null +++ b/src/views/crmpc/home/style.scss @@ -0,0 +1,43 @@ +@use '@styles/variables.scss' as *; + +.console { + --card-spacing: 20px; + + // 卡片头部 + :deep(.card-header) { + display: flex; + justify-content: space-between; + padding: 20px 25px 5px 0; + + .title { + h4 { + font-size: 18px; + font-weight: 500; + color: var(--art-gray-900) !important; + } + + p { + margin-top: 3px; + font-size: 13px; + color: var(--art-gray-600) !important; + + span { + margin-left: 10px; + color: #52c41a; + } + } + } + } + + // 设置卡片背景色、圆角、间隙 + :deep(.card-list .card), + .card { + margin-bottom: var(--card-spacing); + background: var(--art-main-bg-color); + border-radius: calc(var(--custom-radius) + 4px) !important; + } + + @media screen and (max-width: $device-phone) { + --card-spacing: 15px; + } +} diff --git a/src/views/crmpc/home/widget/CardList.vue b/src/views/crmpc/home/widget/CardList.vue new file mode 100644 index 0000000..dd3875f --- /dev/null +++ b/src/views/crmpc/home/widget/CardList.vue @@ -0,0 +1,456 @@ + + + + + diff --git a/src/views/crmpc/recycle/index.vue b/src/views/crmpc/recycle/index.vue new file mode 100644 index 0000000..bc2d1ca --- /dev/null +++ b/src/views/crmpc/recycle/index.vue @@ -0,0 +1,134 @@ + + + + + \ No newline at end of file diff --git a/src/views/system/user-center/index.vue b/src/views/system/user-center/index.vue index 19932cb..b2cd7a2 100644 --- a/src/views/system/user-center/index.vue +++ b/src/views/system/user-center/index.vue @@ -3,64 +3,57 @@
    - - -

    {{ userInfo.userName }}

    -

    Art Design Pro 是一款漂亮的后台管理系统模版.

    - + + +

    {{userInfo.name}}

    +

    ID:{{userInfo.id}}

    -
    - - jdkjjfnndf@mall.com +
    + 电 话: + {{userInfo.phone}}
    -
    - - 交互专家 +
    + 职 位: + {{userInfo.position}}
    -
    - - 广东省深圳市 +
    + 公 司: + {{userInfo.corp_name}}
    -
    - - 字节跳动-某某平台部-UED -
    -
    - -
    -

    标签

    -
    -
    - {{ item }} -
    +
    + 国 家: + {{userInfo.country_txt}}
    - -
    -

    基本设置

    +

    基本信息

    + + +
    + +
    +
    +
    - - + + @@ -75,29 +68,56 @@ - - + + - - + + - - + + - - + + + + - - - - - + + + + 微信 + WhatsApp + + + + + +
    + + + + +
    +
    +
    +
    +
    + {{ isEdit ? '保存' : '编辑' }}
    @@ -107,7 +127,7 @@

    更改密码

    - + - + + {{ isEditPwd ? '保存' : '编辑' }}
    @@ -150,94 +171,116 @@