| | |
| | | </a-col> |
| | | <a-col :md="4" :sm="4" :xs="4"> |
| | | <a-form-item label="日期"> |
| | | <a-date-picker v-model="queryParam.dateTime" :disabledDate="disabledDate" format='YYYYMMDD' |
| | | <a-date-picker v-model="queryParam.dateTime" :disabledDate="disabledDate" format='YYYYMMDD' :allow-clear="false" |
| | | @change="dataChange"/> |
| | | </a-form-item> |
| | | </a-col> |
| | |
| | | }) |
| | | } |
| | | }, |
| | | searchReset() { |
| | | this.spaceTime = [] |
| | | this.useingRates = [] |
| | | if (this.queryParams.typeTree == '1') { |
| | | this.typeTree = this.queryParams.typeTree |
| | | this.typeParent = this.queryParams.parentId |
| | | this.typeEquipment = this.queryParams.equipmentId |
| | | this.queryParams = {} |
| | | this.queryParam = {} |
| | | this.queryParams.typeTree = this.typeTree |
| | | this.queryParams.parentId = this.typeParent |
| | | if (this.queryParams.parentId != '') { |
| | | this.queryParams.equipmentId = '' |
| | | this.initEquipment() |
| | | } else { |
| | | if (this.queryParams.equipmentId == this.queryParamEquip.equipmentId) { |
| | | this.queryParams.equipmentId = this.typeEquipment |
| | | } else { |
| | | this.queryParams.equipmentId = this.queryParamEquip.equipmentId |
| | | } |
| | | } |
| | | getAction(this.url.dayUtilizationRate, this.queryParams).then((res) => { |
| | | if (res.success) { |
| | | this.spaceTime = res.result.dateList |
| | | for (var i = 0; i < res.result.dayRateDto.length; i++) { |
| | | this.useingRates.push(this.numFilter(res.result.dayRateDto[i].utilizationRate)) |
| | | } |
| | | this.drawTu() |
| | | } else { |
| | | this.$notification.warning({ |
| | | message: '消息', |
| | | description: res.message |
| | | }) |
| | | } |
| | | }).finally(() => { |
| | | this.loading = false |
| | | }) |
| | | } else { |
| | | this.typeTree = this.queryParams.typeTree |
| | | this.typeParent = this.queryParams.parentId |
| | | this.typeEquipment = this.queryParams.equipmentId |
| | | this.queryParams = {} |
| | | this.queryParam = {} |
| | | this.dates = [] |
| | | this.queryParams.typeTree = this.typeTree |
| | | this.queryParams.parentId = this.typeParent |
| | | if (this.queryParams.parentId != '') { |
| | | this.queryParams.equipmentId = '' |
| | | this.initEquipment() |
| | | } else { |
| | | if (this.queryParams.equipmentId == this.queryParamEquip.equipmentId) { |
| | | this.queryParams.equipmentId = this.typeEquipment |
| | | } else { |
| | | this.queryParams.equipmentId = this.queryParamEquip.equipmentId |
| | | } |
| | | } |
| | | getAction(this.url.dayUtilizationRate, this.queryParams).then((res) => { |
| | | if (res.success) { |
| | | this.spaceTime = res.result.dateList |
| | | for (var i = 0; i < res.result.dayRateDto.length; i++) { |
| | | this.useingRates.push(this.numFilter(res.result.dayRateDto[i].utilizationRate)) |
| | | } |
| | | this.drawTu() |
| | | } else { |
| | | this.$notification.warning({ |
| | | message: '消息', |
| | | description: res.message |
| | | }) |
| | | } |
| | | }).finally(() => { |
| | | this.loading = false |
| | | }) |
| | | } |
| | | |
| | | }, |
| | | initEquipment(id) { |
| | | let _this = this |
| | | getAction(this.url.getEquipmentByPid, { pid: id }).then((res) => { |
| | |
| | | }, |
| | | created() { |
| | | let collectTime = moment(moment().add(-1, 'd'), 'YYYY-MM-DD') |
| | | |
| | | this.queryParams.collectTime = collectTime |
| | | |
| | | this.queryParam.dateTime = this.queryParams.collectTime.format('YYYYMMDD') |
| | | this.queryParams.typeTree = '1' |
| | | this.initEquipment() |