From d3f39dab686ed16bfc7ac3f3536d10c09ce7c750 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=BF=A0=E6=9E=97?= <170083662@qq.com> Date: Tue, 22 Jul 2025 15:40:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/system/file/index.ts | 4 ++-- src/pages/index/Header.tsx | 2 +- src/pages/index/Login.tsx | 2 +- src/pages/user/components/OrderIcon.tsx | 2 +- src/pages/user/components/UserCard.tsx | 2 +- src/user/profile/profile.tsx | 2 +- src/utils/common.ts | 3 +-- src/utils/server.ts | 2 +- 8 files changed, 9 insertions(+), 10 deletions(-) diff --git a/src/api/system/file/index.ts b/src/api/system/file/index.ts index fa78a8a..969fa0a 100644 --- a/src/api/system/file/index.ts +++ b/src/api/system/file/index.ts @@ -21,7 +21,7 @@ export async function uploadOssByPath(filePath: string) { let stsExpired = Taro.getStorageSync('stsExpiredAt'); if (!sts || (stsExpired && dayjs().isBefore(dayjs(stsExpired)))) { // @ts-ignore - const {data: {data: {credentials}}} = await request.get(`https://server.gxwebsoft.com/api/oss/getSTSToken`) + const {data: {data: {credentials}}} = await request.get(`https://server.websoft.top/api/oss/getSTSToken`) Taro.setStorageSync('sts', credentials) Taro.setStorageSync('stsExpiredAt', credentials.expiration) sts = credentials @@ -66,7 +66,7 @@ export async function uploadFile() { const tempFilePath = res.tempFilePaths[0]; // 上传图片到OSS Taro.uploadFile({ - url: 'https://server.gxwebsoft.com/api/oss/upload', + url: 'https://server.websoft.top/api/oss/upload', filePath: tempFilePath, name: 'file', header: { diff --git a/src/pages/index/Header.tsx b/src/pages/index/Header.tsx index 2756790..152f1ce 100644 --- a/src/pages/index/Header.tsx +++ b/src/pages/index/Header.tsx @@ -93,7 +93,7 @@ const Header = () => { success: function () { if (code) { Taro.request({ - url: 'https://server.gxwebsoft.com/api/wx-login/loginByMpWxPhone', + url: 'https://server.websoft.top/api/wx-login/loginByMpWxPhone', method: 'POST', data: { code, diff --git a/src/pages/index/Login.tsx b/src/pages/index/Login.tsx index a2528e6..1cc2dd0 100644 --- a/src/pages/index/Login.tsx +++ b/src/pages/index/Login.tsx @@ -16,7 +16,7 @@ const Login = (props:any) => { success: function () { if (code) { Taro.request({ - url: 'https://server.gxwebsoft.com/api/wx-login/loginByMpWxPhone', + url: 'https://server.websoft.top/api/wx-login/loginByMpWxPhone', method: 'POST', data: { code, diff --git a/src/pages/user/components/OrderIcon.tsx b/src/pages/user/components/OrderIcon.tsx index 7abb516..fc7ffca 100644 --- a/src/pages/user/components/OrderIcon.tsx +++ b/src/pages/user/components/OrderIcon.tsx @@ -25,7 +25,7 @@ const OrderIcon = () => { success: function () { if (code) { Taro.request({ - url: 'https://server.gxwebsoft.com/api/wx-login/loginByMpWxPhone', + url: 'https://server.websoft.top/api/wx-login/loginByMpWxPhone', method: 'POST', data: { code, diff --git a/src/pages/user/components/UserCard.tsx b/src/pages/user/components/UserCard.tsx index 14f4dd5..ee00e10 100644 --- a/src/pages/user/components/UserCard.tsx +++ b/src/pages/user/components/UserCard.tsx @@ -107,7 +107,7 @@ function UserCard() { success: function () { if (code) { Taro.request({ - url: 'https://server.gxwebsoft.com/api/wx-login/loginByMpWxPhone', + url: 'https://server.websoft.top/api/wx-login/loginByMpWxPhone', method: 'POST', data: { code, diff --git a/src/user/profile/profile.tsx b/src/user/profile/profile.tsx index cb141b5..0ea52d5 100644 --- a/src/user/profile/profile.tsx +++ b/src/user/profile/profile.tsx @@ -73,7 +73,7 @@ function Profile() { avatar: `${detail.avatarUrl}`, }) Taro.uploadFile({ - url: 'https://server.gxwebsoft.com/api/oss/upload', + url: 'https://server.websoft.top/api/oss/upload', filePath: detail.avatarUrl, name: 'file', header: { diff --git a/src/utils/common.ts b/src/utils/common.ts index de80cce..f0c89d6 100644 --- a/src/utils/common.ts +++ b/src/utils/common.ts @@ -69,9 +69,8 @@ export function copyText(text: string) { /** * 分享商品链接 * @param goodsId 商品ID - * @param goodsName 商品名称 */ -export function shareGoodsLink(goodsId: string | number, goodsName?: string) { +export function shareGoodsLink(goodsId: string | number) { // 构建分享链接,这里需要根据你的实际域名调整 const baseUrl = 'https://your-domain.com'; // 请替换为你的实际域名 const shareUrl = `${baseUrl}/shop/goodsDetail/index?id=${goodsId}`; diff --git a/src/utils/server.ts b/src/utils/server.ts index 9ebf757..037fbcd 100644 --- a/src/utils/server.ts +++ b/src/utils/server.ts @@ -4,7 +4,7 @@ import {User} from "@/api/system/user/model"; // 模版套餐ID export const TEMPLATE_ID = 10258; // 服务接口 -export const SERVER_API_URL = 'https://server.gxwebsoft.com/api'; +export const SERVER_API_URL = 'https://server.websoft.top/api'; // export const SERVER_API_URL = 'http://127.0.0.1:8000/api'; /** * 保存用户信息到本地存储