Merge branch 'test'
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2024-03-15 17:12:37 +08:00
4 changed files with 10 additions and 9 deletions

View File

@@ -84,8 +84,7 @@ const formSubmit = async ({ detail }: any) => {
icon: "none", icon: "none",
}); });
try { try {
const res = await checkPhone({ phone: detail.value.phone }); await checkPhone({ phone: detail.value.phone });
console.log(res);
const user_info = await Taro.getStorageSync("userInfo"); const user_info = await Taro.getStorageSync("userInfo");
Taro.navigateTo({ Taro.navigateTo({
url: `/pages/admin/add_order/add_menu/index?type=1&bid=${user_info.data.bid}&seat=${formVal.value.seat}&phone=${formVal.value.phone}&notes=${formVal.value.notes}`, url: `/pages/admin/add_order/add_menu/index?type=1&bid=${user_info.data.bid}&seat=${formVal.value.seat}&phone=${formVal.value.phone}&notes=${formVal.value.notes}`,

View File

@@ -45,7 +45,6 @@
</view> </view>
</view> </view>
</view> </view>
<view class="btn" @click="ok">立即收款</view> <view class="btn" @click="ok">立即收款</view>
</view> </view>
</template> </template>
@@ -69,7 +68,6 @@ const get_data = async ({ bid, oid }) => {
}); });
const res = await getAfterOrder({ bid, oid }); const res = await getAfterOrder({ bid, oid });
data.value = res.data.data; data.value = res.data.data;
console.log(res);
Taro.hideLoading(); Taro.hideLoading();
}; };

View File

@@ -23,7 +23,6 @@ const info = ref<any>({});
Taro.useLoad((e) => { Taro.useLoad((e) => {
info.value = e; info.value = e;
console.log(e);
code.value = Taro.getStorageSync("pay_code"); code.value = Taro.getStorageSync("pay_code");
time_id.value = setInterval(async () => { time_id.value = setInterval(async () => {
const { data } = await getAfterOrder({ const { data } = await getAfterOrder({

View File

@@ -10,6 +10,9 @@ interface Res<T> {
type Method = "GET" | "POST" | "PUT" | "DELETE"; type Method = "GET" | "POST" | "PUT" | "DELETE";
// 忽略系统提示白名单
const IGNORED_TIPS = ["/user/find/phone"];
const request = ( const request = (
url: string, url: string,
data: object = {}, data: object = {},
@@ -26,10 +29,12 @@ const request = (
}, },
success: ({ data }) => { success: ({ data }) => {
if (data.code !== 200) { if (data.code !== 200) {
Taro.showToast({ if (!IGNORED_TIPS.includes(url)) {
title: data.msg, Taro.showToast({
icon: "none", title: data.msg,
}); icon: "none",
});
}
reject(data); reject(data);
} else { } else {
resolve(data); resolve(data);