liyongli 2 năm trước cách đây
mục cha
commit
da02795228

+ 1 - 0
src/view/SilkRoadSpringFestivalGala/pages/eight.vue

@@ -238,6 +238,7 @@ function mygift() {
     phone: phone.value,
   }).then(r => {
     const giftList = r || [];
+    if (!giftList.length) return showToast("暂无中奖信息");
     const cardList = [];
     for (let i = 0; i < giftList.length; i++) {
       const v = giftList[i];

+ 1 - 3
src/view/SilkRoadSpringFestivalGala/pages/six.vue

@@ -201,9 +201,7 @@ const showTitle = ref(false);
 let width = window.$originData.orginParames.availWidth * 0.7;
 // const type = 12;
 const type = Math.floor(Math.random() * 12 + 1);
-let ori = data[type - 1] || {
-  texts: [],
-};
+let ori = data[type - 1] || { texts: [] };
 let max = 0;
 for (let i = 0; i < ori.texts.length; i++) {
   max < ori.texts[i].length && (max = ori.texts[i].length);