Quellcode durchsuchen

Merge branch 'master' of http://112.74.164.79:3000/chenying/X-web

damon227 vor 3 Jahren
Ursprung
Commit
afdd524908

+ 3 - 0
src/api/util.js

@@ -56,6 +56,9 @@ export function checkStr (currentStr, strList) {
   if (!currentStr || !strList) return false
   let list = strList.split(',')
   let index = list.findIndex(item => item === currentStr)
+  // console.log('strList: ' + strList)
+  // console.log('currentUser: ' + currentStr)
+  // console.log('index: ' + index)
   return index > -1
 }
 

+ 3 - 3
src/store/modules/common.js

@@ -28,9 +28,9 @@ export default {
       {
         code: '1', value: '待审批'
       },
-      // {
-      //   code: '2', value: '审批中'
-      // },
+      {
+        code: '2', value: '审批中'
+      },
       {
         code: '3', value: '审批完成'
       },

+ 4 - 3
src/views/common/msg.vue

@@ -87,9 +87,10 @@
       // 跳转到消息页面
       detail (row) {
         routeMsg(this, row)
-        if (row.type === 3) {
-          readNotice(this, row.noticeId)
-        }
+        readNotice(this, row.noticeId)
+        // if (row.type === 3) {
+        //   readNotice(this, row.noticeId)
+        // }
         if (this.notify) {
           this.notify.close()
         }

+ 3 - 3
src/views/modules/common/e-desc.vue

@@ -90,9 +90,9 @@
       }
     },
     beforeDestroy () {
-      // if (!this.observe || this.observe.toString() === '') return
-      // console.log('obs = ' + JSON.stringify(this.observe))
-      this.observer.disconnect()
+      if (this.observe) {
+        this.observer.disconnect()
+      }
     }
   }
 </script>

+ 2 - 2
src/views/modules/msg-center/approve.vue

@@ -270,8 +270,8 @@
         })
       },
       checkUser (row) {
-        let currentUser = this.$store.state.user.name
-        return checkStr(currentUser, row.approver)
+        let currentUser = this.$store.state.user.id
+        return checkStr(currentUser, row.currentApprover)
       },
       // 新增 / 修改
       addOrUpdateHandle (businessType, businessId) {

+ 1 - 0
src/views/modules/msg-center/notice.vue

@@ -150,6 +150,7 @@
       },
       // 查看消息
       detailHandle (row) {
+        this.checkHandle(row.noticeId)
         routeMsg(this, row)
       },
       timestampToTime (l) {