Browse Source

Merge remote-tracking branch 'origin/web-v2' into web-v2

heyang 2 years ago
parent
commit
eedaaa9a12
1 changed files with 5 additions and 5 deletions
  1. 5 5
      src/views/comprehensive/personnel/patrolRecord/index.vue

+ 5 - 5
src/views/comprehensive/personnel/patrolRecord/index.vue

@@ -292,14 +292,14 @@
           if(this.yearMonthData.month<12){
             this.yearMonthData.month++
           }else{
-            if(this.yearMonthData.year>=this.yearMonthData.presentYear+1){
+            if(this.yearMonthData.year>=this.yearMonthData.presentYear){
               return
             }
             this.yearMonthData.year++
             this.$set(this.yearMonthData,'month',1);
           }
         }else if(this.yearMonthType == 2){
-          if(this.yearMonthData.year>=this.yearMonthData.presentYear+1){
+          if(this.yearMonthData.year>=this.yearMonthData.presentYear){
             return
           }
           this.yearMonthData.year++
@@ -312,14 +312,14 @@
           if(this.yearMonthData.month>1){
             this.yearMonthData.month--
           }else{
-            if(this.yearMonthData.year==this.yearMonthData.presentYear){
+            if(this.yearMonthData.year<=this.yearMonthData.presentYear-1){
               return
             }
             this.yearMonthData.year--
             this.$set(this.yearMonthData,'month',12);
           }
         }else if(this.yearMonthType == 2){
-          if(this.yearMonthData.year==this.yearMonthData.presentYear){
+          if(this.yearMonthData.year<=this.yearMonthData.presentYear-1){
             return
           }
           this.yearMonthData.year--
@@ -337,7 +337,7 @@
       generateDate() {
         let self = this;
         let myDate = new Date();
-        let year = myDate.getFullYear();
+        let year = myDate.getFullYear()-1;
         let newTimeList = [];
         self.newKey = 0;
         for(let o=0;o<2;o++){