소스 검색

coin

master
HolyKnightIX 1 년 전
부모
커밋
f983fb12fe
2개의 변경된 파일10개의 추가작업 그리고 2개의 파일을 삭제
  1. +6
    -1
      src/App.vue
  2. +4
    -1
      src/pages/index/buyCoin.vue

+ 6
- 1
src/App.vue 파일 보기

@@ -63,7 +63,8 @@ onLaunch(() => {
console.log(userInfoModulesPinia.openId, "获取openid");
// 获取头像和金币
const res3 = await findImageApi();
userInfoModulesPinia.myAvatar = res3.data.image;
userInfoModulesPinia.myAvatar =
res3.data && res3.data.image ? res3.data.image : "";
const res4 = await findGlodApi();
if (!res4.data) {
userInfoModulesPinia.myGlod = 0;
@@ -79,6 +80,7 @@ onLaunch(() => {
uni.redirectTo({
url: "/pages/login/index",
});
console.log("error1");
uni.showToast({
title: "登录失败,请重试",
icon: "none",
@@ -88,6 +90,7 @@ onLaunch(() => {
// uni.redirectTo({
// url: "pages/index/index",
// });
console.log(error, "error2");
uni.showToast({
title: "登录失败,请重试",
icon: "none",
@@ -97,6 +100,7 @@ onLaunch(() => {
// uni.redirectTo({
// url: "pages/index/index",
// });
console.log("error3");
uni.showToast({
title: "登录失败,请重试",
icon: "none",
@@ -107,6 +111,7 @@ onLaunch(() => {
// uni.redirectTo({
// url: "pages/index/index",
// });
console.log("error4");
uni.showToast({
title: "登录失败,请重试",
icon: "none",


+ 4
- 1
src/pages/index/buyCoin.vue 파일 보기

@@ -104,7 +104,9 @@ const startPay = (data) => {
...orderInfo,
success: function (res) {
console.log(res, "res");
getStatusOfOrder(orderNumber.value);
getStatusOfOrder(orderNumber.value).then((res) => {
console.log(res, "status");
});
},
fail: function (err) {
uni.showToast({
@@ -120,6 +122,7 @@ const getStatusOfOrder = async (orderNumber) => {
try {
const res = await getOrderStatus(orderNumber);
console.log(res, "getStatusOfOrder");
return res.data.orderStatus;
} catch (error) {
console.log(error, "error");
}


불러오는 중...
취소
저장