From f50939f970fb8b8c1bb18c77df5a7ad2d093f91c Mon Sep 17 00:00:00 2001 From: al Date: Wed, 11 Sep 2024 14:22:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BF=AE=E6=94=B9=E5=AF=86?= =?UTF-8?q?=E7=A0=81=E9=97=AE=E9=A2=98=E4=BB=A5=E5=8F=8A=E5=85=B6=E4=BB=96?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/public.js | 20 ++++++++++++++++---- app/messageDetail/page.js | 2 +- app/my/addToHome/page.js | 2 +- app/my/setting/editPassword/page.js | 2 ++ app/my/unlockedWechat/page.jsx | 2 +- app/search/page.js | 21 ++++++++++++++++----- components/MySlider/index.jsx | 3 ++- 7 files changed, 39 insertions(+), 13 deletions(-) diff --git a/api/public.js b/api/public.js index 8f6233a..2057ac0 100644 --- a/api/public.js +++ b/api/public.js @@ -247,8 +247,11 @@ export const createOrder = async (type = "alipay_h5") => { }; //点击获取验证码 -export const handleVerification = async (mobilePhone = "", regionCode) => { - // console.log("mobilePhone",mobilePhone.toString()) +export const handleVerification = async ( + mobilePhone = "", + regionCode, + callback +) => { //手机号校验 if (!mobilePhone.toString().match(/^1[3456789]\d{9}$/)) { Toast.show({ @@ -260,16 +263,25 @@ export const handleVerification = async (mobilePhone = "", regionCode) => { } //对手机号进行RSA加密 const encrypt = new JSEncrypt(); - encrypt.setPublicKey(process.env.EXPO_PUBLIC_RSA_KEY); + encrypt.setPublicKey(process.env.NEXT_PUBLIC_RSA_KEY); const mobile_phone = encrypt.encrypt(mobilePhone); //发送短信验证码 try { - await requireAPI("POST", `/api/veri_code/send`, { + const data = await requireAPI("POST", `/api/veri_code/send`, { body: { mobile_phone: mobile_phone, region_code: regionCode, }, }); + if (data.ret === -1) { + Toast.show({ + icon: "fail", + content: data.msg, + position: "top", + }); + return; + } + callback && callback(); } catch (error) { // console.error(error); } diff --git a/app/messageDetail/page.js b/app/messageDetail/page.js index 31219b9..7804da4 100644 --- a/app/messageDetail/page.js +++ b/app/messageDetail/page.js @@ -377,7 +377,7 @@ export default function MessageDetail({}) { }; return (
-
+
-
+
-
+
-
+
setIsFilterVisible({ zone_admission_price: false, @@ -786,7 +791,10 @@ export default function Search() { setIsFilterVisible({ zone_admission_price: false, @@ -878,6 +886,9 @@ export default function Search() { />
))} +

+ *{priceFilters[1]?.desc} +

- - + ~