|
@@ -30,18 +30,19 @@
|
|
|
:picker-options="pickerOptions"
|
|
:picker-options="pickerOptions"
|
|
|
clearable
|
|
clearable
|
|
|
@change="changeDateRange"
|
|
@change="changeDateRange"
|
|
|
|
|
+ @clear="changeDateRange"
|
|
|
class="filter-input"
|
|
class="filter-input"
|
|
|
v-if="filter.pageVo.reportType === 'APENDIXF'"/>
|
|
v-if="filter.pageVo.reportType === 'APENDIXF'"/>
|
|
|
<el-date-picker
|
|
<el-date-picker
|
|
|
- v-model="dateRange"
|
|
|
|
|
- type="daterange"
|
|
|
|
|
|
|
+ v-model="monthRange"
|
|
|
|
|
+ type="monthrange"
|
|
|
value-format="yyyy-MM"
|
|
value-format="yyyy-MM"
|
|
|
format="yyyy-MM"
|
|
format="yyyy-MM"
|
|
|
start-placeholder="Start Month"
|
|
start-placeholder="Start Month"
|
|
|
end-placeholder="End Month"
|
|
end-placeholder="End Month"
|
|
|
- :picker-options="pickerOptions"
|
|
|
|
|
clearable
|
|
clearable
|
|
|
- @change="changeDateRange"
|
|
|
|
|
|
|
+ @change="changeMonthRange"
|
|
|
|
|
+ @clear="changeMonthRange"
|
|
|
class="filter-input"
|
|
class="filter-input"
|
|
|
v-if="filter.pageVo.reportType == 'MNTHADHOC'"/>
|
|
v-if="filter.pageVo.reportType == 'MNTHADHOC'"/>
|
|
|
<el-date-picker
|
|
<el-date-picker
|
|
@@ -245,6 +246,7 @@ export default {
|
|
|
generate: false
|
|
generate: false
|
|
|
},
|
|
},
|
|
|
dateRange: [],
|
|
dateRange: [],
|
|
|
|
|
+ monthRange: [],
|
|
|
filter: {
|
|
filter: {
|
|
|
pageNo: 1,
|
|
pageNo: 1,
|
|
|
pageSize: 10,
|
|
pageSize: 10,
|
|
@@ -253,6 +255,8 @@ export default {
|
|
|
month: '',
|
|
month: '',
|
|
|
startDate: "",
|
|
startDate: "",
|
|
|
endDate: "",
|
|
endDate: "",
|
|
|
|
|
+ startMonth: "",
|
|
|
|
|
+ endMonth: "",
|
|
|
reportType: '',
|
|
reportType: '',
|
|
|
sitePks: [],
|
|
sitePks: [],
|
|
|
groupPks: [],
|
|
groupPks: [],
|
|
@@ -328,13 +332,28 @@ export default {
|
|
|
this.filter.pageVo.startDate = "";
|
|
this.filter.pageVo.startDate = "";
|
|
|
this.filter.pageVo.endDate = "";
|
|
this.filter.pageVo.endDate = "";
|
|
|
this.filter.pageVo.month = "";
|
|
this.filter.pageVo.month = "";
|
|
|
|
|
+ this.filter.pageVo.startMonth = "";
|
|
|
|
|
+ this.filter.pageVo.endMonth = "";
|
|
|
this.dateRange = [];
|
|
this.dateRange = [];
|
|
|
|
|
+ this.monthRange = [];
|
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
|
},
|
|
},
|
|
|
changeDateRange(range) {
|
|
changeDateRange(range) {
|
|
|
- if (this.dateRange.length == 2) {
|
|
|
|
|
|
|
+ if (this.dateRange && this.dateRange.length == 2) {
|
|
|
this.filter.pageVo.startDate = this.dateRange[0]
|
|
this.filter.pageVo.startDate = this.dateRange[0]
|
|
|
this.filter.pageVo.endDate = this.dateRange[1]
|
|
this.filter.pageVo.endDate = this.dateRange[1]
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.filter.pageVo.startDate = "";
|
|
|
|
|
+ this.filter.pageVo.endDate = "";
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+ changeMonthRange(range) {
|
|
|
|
|
+ if (this.monthRange && this.monthRange.length == 2) {
|
|
|
|
|
+ this.filter.pageVo.startMonth = this.monthRange[0]
|
|
|
|
|
+ this.filter.pageVo.endMonth = this.monthRange[1]
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.filter.pageVo.startMonth = "";
|
|
|
|
|
+ this.filter.pageVo.endMonth = "";
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onSearch() {
|
|
onSearch() {
|