src/views/mdc/base/modules/EquipmentAvailCompare/EquipmentAvailCompareMain.vue
@@ -18,14 +18,14 @@
              </a-col>
              <a-col :md="5" :sm="5" :xs="5">
                <a-form-item label="时间">
                  <a-range-picker @change="dateParamChange" v-model="dates" format="YYYYMMDD"/>
                  <a-range-picker @change="dateParamChange" v-model="dates" format="YYYYMMDD" :allow-clear="false"/>
                </a-form-item>
              </a-col>
              <a-col :md="6" :sm="6" :xs="6">
                <a-form-item label="时间段">
                  <a-time-picker :default-value="moment('00:00', 'HH:mm')" format="HH:mm" @change="onChangeStart"/>
                  <a-time-picker :default-value="moment('00:00', 'HH:mm')" format="HH:mm" @change="onChangeStart" :allow-clear="false"/>
                  至
                  <a-time-picker :default-value="moment('08:00', 'HH:mm')" format="HH:mm" @change="onChangeEnd"/>
                  <a-time-picker :default-value="moment('08:00', 'HH:mm')" format="HH:mm" @change="onChangeEnd" :allow-clear="false"/>
                </a-form-item>
              </a-col>
              <a-col :md="2" :sm="3" :xs="3">
@@ -236,47 +236,40 @@
        }
      },
      searchQuery() {
        if (this.queryParam.startTime && this.queryParam.endTime && this.dates && this.dates.length > 0) {
          this.loading = true
          this.spaceTime = []
          this.usingRates = []
          if (this.queryParams.typeTree == '1') {
            this.queryParams.parentId = this.queryParamEquip.parentId
            // this.queryParams.equipmentId =  this.queryParamEquip.equipmentId
        this.loading = true
        this.spaceTime = []
        this.usingRates = []
        if (this.queryParams.typeTree == '1') {
          this.queryParams.parentId = this.queryParamEquip.parentId
          // this.queryParams.equipmentId =  this.queryParamEquip.equipmentId
          } else {
            this.queryParams.parentId = this.queryParamEquip.parentId
            // this.queryParams.equipmentId = ""
          }
          this.AnalysisList = []
          //获取查询条件
          this.queryParam.parentId = this.queryParams.parentId
          this.queryParam.equipmentId = this.queryParams.equipmentId
          this.queryParam.typeTree = this.queryParams.typeTree
          getAction(this.url.dayUtilizationRateContrast, this.queryParam).then((res) => {
            if (res.success) {
              this.spaceTime = res.result.dateList
              for (let i = 0; i < res.result.dayRateDto.length; i++) {
                // res.result[i].useRateDayShift = this.numFilter(res.result[i].useRateDayShift)
                this.usingRates.push(this.numFilter(res.result.dayRateDto[i].utilizationRate))
              }
              this.drawTu()
            } else {
              // this.$message.warning(res.message)
              this.$notification.warning({
                message: '消息',
                description: res.message
              })
            }
          }).finally(() => {
            this.loading = false
          })
        } else {
          this.$notification.warning({
            message: '消息',
            description: '请选择时间或时间段'
          })
          this.queryParams.parentId = this.queryParamEquip.parentId
          // this.queryParams.equipmentId = ""
        }
        this.AnalysisList = []
        //获取查询条件
        this.queryParam.parentId = this.queryParams.parentId
        this.queryParam.equipmentId = this.queryParams.equipmentId
        this.queryParam.typeTree = this.queryParams.typeTree
        getAction(this.url.dayUtilizationRateContrast, this.queryParam).then((res) => {
          if (res.success) {
            this.spaceTime = res.result.dateList
            for (let i = 0; i < res.result.dayRateDto.length; i++) {
              // res.result[i].useRateDayShift = this.numFilter(res.result[i].useRateDayShift)
              this.usingRates.push(this.numFilter(res.result.dayRateDto[i].utilizationRate))
            }
            this.drawTu()
          } else {
            // this.$message.warning(res.message)
            this.$notification.warning({
              message: '消息',
              description: res.message
            })
          }
        }).finally(() => {
          this.loading = false
        })
      },
      searchReset() {
        this.loading = true