瀏覽代碼

fix: custom tab bar event

wangyuan 2 年之前
父節點
當前提交
20c79bd40d
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      custom-tab-bar/index.js

+ 3 - 0
custom-tab-bar/index.js

@@ -43,6 +43,9 @@ Component({
           app.globalData.selectedInex = data.index
           wx.switchTab({url})
         }
+      } else {
+        app.globalData.selectedInex = data.index
+        wx.switchTab({url})
       }
     }
   }