From 912da7bfd25eb26578d3beb6258003c05f9b984f Mon Sep 17 00:00:00 2001 From: WindowBird <13870814+windows-bird@user.noreply.gitee.com> Date: Mon, 3 Nov 2025 16:39:40 +0800 Subject: [PATCH] =?UTF-8?q?=E5=95=86=E5=AE=B6=E5=8A=A0=E7=9B=9F=E6=8C=89?= =?UTF-8?q?=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/components/ContactFloatingButton.vue | 203 ++++++++++++++++++++++- app/config/api.ts | 36 ++++ 2 files changed, 231 insertions(+), 8 deletions(-) diff --git a/app/components/ContactFloatingButton.vue b/app/components/ContactFloatingButton.vue index 40be96a..d81f48e 100644 --- a/app/components/ContactFloatingButton.vue +++ b/app/components/ContactFloatingButton.vue @@ -1,21 +1,208 @@ + + diff --git a/app/config/api.ts b/app/config/api.ts index e9b9f1c..a8f5153 100644 --- a/app/config/api.ts +++ b/app/config/api.ts @@ -189,3 +189,39 @@ export async function getArticleDetail(id: string): Promise
{ } } +/** + * 商家加盟申请数据类型定义 + */ +export interface MchApplyParams { + name: string + mobile: string + content: string + hasDevice: number + city: string +} + +/** + * 提交商家加盟申请 + * @param params 申请参数 + * @returns Promise> 返回申请结果 + */ +export async function submitMchApply(params: MchApplyParams): Promise> { + try { + const response = await $fetch>( + `${API_BASE_URL}/app/mchApply`, + { + method: 'POST', + headers: { + 'Content-Type': 'application/json', + }, + body: params, + } + ) + + return response + } catch (error) { + console.error('提交商家加盟申请时发生错误:', error) + throw error + } +} +