소스 검색

DatePicker: Fix year picker

rodrigore 8 년 전
부모
커밋
7986126ab4
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      packages/date-picker/src/panel/date.vue

+ 1 - 1
packages/date-picker/src/panel/date.vue

@@ -310,7 +310,7 @@
 
         this.date.setFullYear(year);
         if (this.selectionMode === 'year') {
-          this.$emit('pick', new Date(year));
+          this.$emit('pick', new Date(year, 0, 1));
         } else {
           this.currentView = 'month';
         }