From 71ef5c256e6d5cd045e3572d51fb2874bcdb5695 Mon Sep 17 00:00:00 2001 From: WindowBird <13870814+windows-bird@user.noreply.gitee.com> Date: Fri, 7 Nov 2025 11:09:30 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=A2=E6=88=B7=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/api.js | 42 ++ pages.json | 7 + pages/add-customer/index.vue | 1110 +++++++++++++++++++++++++++++++ pages/customer-detail/index.vue | 1 + 4 files changed, 1160 insertions(+) create mode 100644 pages/add-customer/index.vue diff --git a/common/api.js b/common/api.js index 1c733cc..73e5f72 100644 --- a/common/api.js +++ b/common/api.js @@ -249,3 +249,45 @@ export const getCustomerProjects = (customerId) => { }); }; +/** + * 获取地区树 + * @returns {Promise} 返回地区树数据 + */ +export const getRegionTree = () => { + return uni.$uv.http.get(`/bst/region/treaDity`, { + custom: { + auth: true + } + }); +}; + +/** + * 创建客户 + * @param {Object} data 客户数据 + * @param {string} data.type 类型(固定为2) + * @param {string} data.name 客户名 + * @param {string} data.mobile 手机号 + * @param {string} data.wechat 微信号 + * @param {string} data.source 来源 + * @param {string} data.intents 意向的设备,逗号分离 + * @param {string} data.status 状态(1潜在2意向3成交4失效) + * @param {string} data.intentLevel 意向强度 + * @param {string} data.customerStatus 客户状态 + * @param {string} data.customerIntentLevel 客户意向强度 + * @param {string} data.nextFollowTime 下次跟进时间 + * @param {string} data.followId 跟进人id + * @param {string} data.remark 备注 + * @param {string} data.concern 顾虑点 + * @param {string} data.pain 痛点 + * @param {string} data.attention 关注点 + * @param {string} data.demand 需求点 + * @returns {Promise} 返回创建结果 + */ +export const createCustomer = (data) => { + return uni.$uv.http.post(`bst/customer`, data, { + custom: { + auth: true + } + }); +}; + diff --git a/pages.json b/pages.json index 7391334..f7598f0 100644 --- a/pages.json +++ b/pages.json @@ -75,6 +75,13 @@ "navigationBarTitleText": "客户详情", "navigationStyle": "custom" } + }, + { + "path": "pages/add-customer/index", + "style": { + "navigationBarTitleText": "客户信息", + "navigationStyle": "custom" + } } ], diff --git a/pages/add-customer/index.vue b/pages/add-customer/index.vue new file mode 100644 index 0000000..6c6c457 --- /dev/null +++ b/pages/add-customer/index.vue @@ -0,0 +1,1110 @@ +