ZaiZai 2 years ago
parent
commit
17e8ae38b4
1 changed files with 8 additions and 1 deletions
  1. 8 1
      pages/index/index.vue

+ 8 - 1
pages/index/index.vue

@@ -10,7 +10,7 @@
             </view>
         </template>
         <view class="relative px-5" v-if="msgCountData.taskCount > 0">
-            <uni-notice-bar show-icon :text="`您有${msgCountData.taskCount}条待办任务,请注意及时处理`" />
+            <uni-notice-bar show-icon :text="`您有${msgCountData.taskCount}条待办任务,请注意及时处理`" @click="toTaskPage"/>
         </view>
         <template v-if="!isListType">
             <view class="hc-flex-conten mt-4">
@@ -252,6 +252,13 @@ const homeToPage = (url) => {
         url: url
     })
 }
+
+//跳转到任务页面
+const toTaskPage = () => {
+    uni.switchTab({
+        url: '/pages/task/index'
+    })
+}
 </script>
 
 <style lang="scss" scoped>