From 732a3cce9442ae533cb58222c8aa09442ec91530 Mon Sep 17 00:00:00 2001 From: 1019933623 <1019933623@qq.com> Date: Tue, 26 Oct 2021 14:22:03 +0800 Subject: [PATCH] fix all --- .../course/pages/arrange_class/arrange_class.vue | 27 +--------------------- .../pages/class_time_change/class_time_change.vue | 24 +------------------ 2 files changed, 2 insertions(+), 49 deletions(-) diff --git a/src/subpackage/course/pages/arrange_class/arrange_class.vue b/src/subpackage/course/pages/arrange_class/arrange_class.vue index 2e5ffbc..20d1ef4 100644 --- a/src/subpackage/course/pages/arrange_class/arrange_class.vue +++ b/src/subpackage/course/pages/arrange_class/arrange_class.vue @@ -26,7 +26,6 @@ *上课日期 - {{submitInfo.date}} @@ -79,18 +78,9 @@ import { mapState } from 'vuex'; export default { computed: { ...mapState([ 'brandInfo',]), - startDate() { - return this.getDate('start'); - }, - endDate() { - return this.getDate('end'); - }, - userInfo(){ - return uni.getStorageSync('loginInfo') || {}; - }, timeList(){ let _list = [] - for(let i = 0; i<=24; i++){ + for(let i = 0; i<24; i++){ _list.push(`${i<10?'0'+i:i}:00`) } return _list; @@ -137,21 +127,6 @@ export default { this.getStuInfo(options.order_no) }, methods: { - getDate(type) { - const date = new Date(); - let year = date.getFullYear(); - let month = date.getMonth() + 1; - let day = date.getDate(); - - if (type === 'start') { - year = year - 60; - } else if (type === 'end') { - year = year + 2; - } - month = month > 9 ? month : '0' + month; - day = day > 9 ? day : '0' + day; - return `${year}-${month}-${day}`; - }, //日期 bindDateChange: function(e) { let _selectDate = e.target.value diff --git a/src/subpackage/course/pages/class_time_change/class_time_change.vue b/src/subpackage/course/pages/class_time_change/class_time_change.vue index bb9d883..a91a4f1 100644 --- a/src/subpackage/course/pages/class_time_change/class_time_change.vue +++ b/src/subpackage/course/pages/class_time_change/class_time_change.vue @@ -9,7 +9,6 @@ 第{{pageInfo.lesson_no|| 0}}节 *上课日期 - {{pageInfo.period_date}} @@ -50,15 +49,9 @@ import { mapState } from 'vuex'; export default { computed: { ...mapState([ 'brandInfo',]), - startDate() { - return this.getDate('start'); - }, - endDate() { - return this.getDate('end'); - }, timeList(){ let _list = [] - for(let i = 0; i<=24; i++){ + for(let i = 0; i<24; i++){ _list.push(`${i<10?'0'+i:i}:00`) } return _list; @@ -78,21 +71,6 @@ export default { this.pageInfo = _query }, methods: { - getDate(type) { - const date = new Date(); - let year = date.getFullYear(); - let month = date.getMonth() + 1; - let day = date.getDate(); - - if (type === 'start') { - year = year - 60; - } else if (type === 'end') { - year = year + 2; - } - month = month > 9 ? month : '0' + month; - day = day > 9 ? day : '0' + day; - return `${year}-${month}-${day}`; - }, //日期 bindDateChange: function(e) { let _selectDate = e.target.value