zhangwei 2 anni fa
parent
commit
6cc530d8d9
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      src/view/iframe/red-packet/red-packet.vue

+ 2 - 2
src/view/iframe/red-packet/red-packet.vue

@@ -716,6 +716,7 @@ function init() {
         return
         return
       }
       }
       state.detail = JSON.parse(res.data.postBizData)
       state.detail = JSON.parse(res.data.postBizData)
+      state.detail.taskCondition = state.detail.taskCondition || []
       console.log(state.detail)
       console.log(state.detail)
 
 
       handleStatusPage()
       handleStatusPage()
@@ -732,7 +733,6 @@ function initTaskDetail() {
     }
     }
   }).then((res) => {
   }).then((res) => {
     if (res.code.toString()) {
     if (res.code.toString()) {
-      state.detail.taskCondition = res.data
       for (let i in res.data) {
       for (let i in res.data) {
         switch (res.data[i].type) {
         switch (res.data[i].type) {
           case 1:
           case 1:
@@ -1147,9 +1147,9 @@ async function joinDiscord() {
   if(joinDiscordIng.value) {
   if(joinDiscordIng.value) {
     return;
     return;
   } 
   } 
-  joinDiscordIng.value = true;
   let url = getInviteUrl(); 
   let url = getInviteUrl(); 
   if(url) {
   if(url) {
+    joinDiscordIng.value = true;
     checkGuildJoinedStatus({url}, (res) => {
     checkGuildJoinedStatus({url}, (res) => {
       setTimeout(() => {
       setTimeout(() => {
         joinDiscordIng.value = false;
         joinDiscordIng.value = false;