jiangping
2025-03-03 3a11109642961896bd5ae64ead123cf1a31e5216
admin/src/views/business/trainTime.vue
@@ -86,17 +86,18 @@
  },
  methods: {
    changeRadio(e) {
      this.searchForm.radio = e
      if (e === '0') {
        this.searchForm.startTimeStart = timeForMat(0)[0]
        this.searchForm.startTimeEnd = timeForMat(0)[1]
        this.searchForm.sendStartDate = timeForMat(0)[0]
        this.searchForm.sendEndDate = timeForMat(0)[1]
        this.time = timeForMat(0)
      } else if (e === '1') {
        this.searchForm.startTimeStart = timeForMat(6)[0]
        this.searchForm.startTimeEnd = timeForMat(6)[1]
        this.searchForm.sendStartDate = timeForMat(6)[0]
        this.searchForm.sendEndDate = timeForMat(6)[1]
        this.time = timeForMat(6)
      } else if (e === '2') {
        this.searchForm.startTimeStart = timeForMat(29)[0]
        this.searchForm.startTimeEnd = timeForMat(29)[1]
        this.searchForm.sendStartDate = timeForMat(29)[0]
        this.searchForm.sendEndDate = timeForMat(29)[1]
        this.time = timeForMat(29)
      }
      this.search()
@@ -106,40 +107,14 @@
        this.searchForm.startTimeStart = e[0]
        this.searchForm.startTimeEnd = e[1]
        this.searchForm.radio = null
        this.search()
      }
    },
    changeRadio1(e) {
      if (e === '0') {
        this.searchForm.endTimeStart = timeForMat(0)[0]
        this.searchForm.endTimeEnd = timeForMat(0)[1]
        this.time1 = timeForMat(0)
      } else if (e === '1') {
        this.searchForm.endTimeStart = timeForMat(6)[0]
        this.searchForm.endTimeEnd = timeForMat(6)[1]
        this.time1 = timeForMat(6)
      } else if (e === '2') {
        this.searchForm.endTimeStart = timeForMat(29)[0]
        this.searchForm.endTimeEnd = timeForMat(29)[1]
        this.time1 = timeForMat(29)
      }
      this.search()
    },
    seleTime1(e) {
      if (e && e.length > 1) {
        this.searchForm.endTimeStart = e[0]
        this.searchForm.endTimeEnd = e[1]
        this.searchForm.radio1 = null
        this.time = [e[0], e[1]]
        this.search()
      }
    },
    reset() {
      this.$refs.searchForm.resetFields()
      this.searchForm = {}
      this.time = []
      this.time1 = []
      this.searchForm.radio = ''
      this.searchForm.radio1 = '0'
      // this.changeRadio('0')
      this.search()
    }
  }