1.修复查询错误及默认日期写死问题

master
董哲奇 1 year ago
parent 137a82ff06
commit f61407662e

@ -344,14 +344,14 @@ export default {
this.generatedCol() this.generatedCol()
getList(this.queryParam).then((res) => { getList(this.queryParam).then((res) => {
if (res.data){ if (res.data){
this.list = res.data.list this.list = res.data
this.list2 = res.data.hz // this.list2 = res.data.hz
if (this.$refs.xGrid) { // if (this.$refs.xGrid) {
this.$refs.xGrid.loadData(this.list) // this.$refs.xGrid.loadData(this.list)
} // }
if (this.$refs.xGrid2) { // if (this.$refs.xGrid2) {
this.$refs.xGrid2.loadData(this.list2) // this.$refs.xGrid2.loadData(this.list2)
} // }
} }
}) })
this.activeName='first' this.activeName='first'

@ -80,8 +80,8 @@ export default {
data() { data() {
return { return {
queryParam: { queryParam: {
beginTime:'2023/08/01', beginTime:new Date(),
endTime:'2023/10/01', endTime:XEUtils.getWhatMonth(new Date(), 3),
gdZt:'' gdZt:''
}, },
gdZtOptions:[ gdZtOptions:[
@ -338,6 +338,11 @@ export default {
this.getHeight() this.getHeight()
this.initBase() this.initBase()
}, },
watch: {
'queryParam.beginTime'(newValue, Value){
this.queryParam.endTime= XEUtils.getWhatMonth(newValue, 3)
},
},
methods: { methods: {
cellClickEvent ( column ) { cellClickEvent ( column ) {
}, },

@ -88,8 +88,8 @@ export default {
data() { data() {
return { return {
queryParam: { queryParam: {
beginTime:'2023/08/01', beginTime:new Date(),
endTime:'2023/10/01', endTime:XEUtils.getWhatMonth(new Date(), 3),
gdZt:'1' gdZt:'1'
}, },
gdZtOptions:[ gdZtOptions:[
@ -352,6 +352,9 @@ export default {
this.initBase() this.initBase()
}, },
watch: { watch: {
'queryParam.beginTime'(newValue, Value){
this.queryParam.endTime= XEUtils.getWhatMonth(newValue, 3)
},
'$route'(){ '$route'(){
this.getParams(); this.getParams();
} }

@ -105,8 +105,8 @@ export default {
data() { data() {
return { return {
queryParam: { queryParam: {
beginTime:'2023/08/01', beginTime:new Date(),
endTime:'2023/10/01', endTime:XEUtils.getWhatMonth(new Date(), 3),
gdZt:'0' gdZt:'0'
}, },
gdZtOptions:[ gdZtOptions:[
@ -359,9 +359,12 @@ export default {
this.initBase() this.initBase()
}, },
watch: { watch: {
'queryParam.beginTime'(newValue, Value){
this.queryParam.endTime= XEUtils.getWhatMonth(newValue, 3)
},
'$route'(){ '$route'(){
this.getParams(); this.getParams();
} },
}, },
methods: { methods: {
getParams(){ getParams(){

Loading…
Cancel
Save