diff --git a/hzhub-portal-employee/src/api/crm/index.ts b/hzhub-portal-employee/src/api/crm/index.ts index ea3b6b7..552d7dd 100644 --- a/hzhub-portal-employee/src/api/crm/index.ts +++ b/hzhub-portal-employee/src/api/crm/index.ts @@ -5,6 +5,7 @@ */ import type { + CrmDealerVo, CrmLeadBo, CrmLeadFollowBo, CrmLeadFollowVo, @@ -21,6 +22,7 @@ import type { // 导出类型供外部使用 export type { + CrmDealerVo, CrmLeadBo, CrmLeadFollowBo, CrmLeadFollowVo, @@ -139,3 +141,17 @@ export function updateOpportunity(data: CrmOpportunityBo): Promise> { export function deleteOpportunity(opportunityIds: string): Promise> { return request.delete(`/crm/opportunity/${opportunityIds}`).json(); } + +/** + * ======================================== + * CRM 经销商管理模块 API 调用 + * ======================================== + */ + +/** + * 获取经销商选择器列表 + * 用于商机创建、商机分配等场景 + */ +export function getDealerSelectList(keyword?: string): Promise> { + return request.get('/crm/dealer/portal/select', { keyword }).json(); +} diff --git a/hzhub-portal-employee/src/api/crm/types.ts b/hzhub-portal-employee/src/api/crm/types.ts index 28e89d8..b520fd7 100644 --- a/hzhub-portal-employee/src/api/crm/types.ts +++ b/hzhub-portal-employee/src/api/crm/types.ts @@ -217,4 +217,47 @@ export interface TableDataInfo { msg: string; rows: T[]; total: number; +} + +/** + * ======================================== + * CRM 经销商管理模块类型定义 + * ======================================== + */ + +/** + * 经销商视图对象(响应) + */ +export interface CrmDealerVo { + dealerId: number; + tenantId: string; + customerCode?: string; // ERP客户编码 + dealerName: string; // 经销商名称 + dealerCode: string; // 经销商编码 + contactName?: string; // 联系人 + mobile?: string; // 手机 + province?: string; // 省 + city?: string; // 市 + level?: string; // 等级(A/B/C) + levelName?: string; // 等级名称(翻译) + lifecycle?: string; // 生命周期 + lifecycleName?: string; // 生命周期名称(翻译) + signedAt?: string; // 签约时间 + storeCount?: number; // 门店数 + teamSize?: number; // 团队规模 + totalOrderAmount?: number; // 累计订单金额 + totalPaymentAmount?: number; // 累计回款金额 + activityScore?: number; // 活跃评分 + riskScore?: number; // 风险评分 + ownerUserId?: number; // 负责人 + ownerUserName?: string; // 负责人姓名(翻译) + sourceLeadId?: number; // 来源线索ID + status?: string; // 状态 + statusName?: string; // 状态名称(翻译) + createBy: number; + createByName?: string; + createTime: string; + updateBy?: number; + updateByName?: string; + updateTime?: string; } \ No newline at end of file diff --git a/hzhub-portal-employee/src/pages/opportunity/index.vue b/hzhub-portal-employee/src/pages/opportunity/index.vue index c4703ba..d0b1254 100644 --- a/hzhub-portal-employee/src/pages/opportunity/index.vue +++ b/hzhub-portal-employee/src/pages/opportunity/index.vue @@ -1,18 +1,125 @@