<a-range-picker
:value="createValue"
@change="handleDateChange"
ref="createTime"/>
data() {
return {
createValue: [],
queryParams: {
createTimeFrom: '',
createTimeTo: ''
}
}
},
methods: {
//选择时间
handleDateChange (dates, dateStrings) {
if (dates, dateStrings) {
this.createValue = dates
this.queryParams.createTimeFrom = dateStrings[0]
this.queryParams.createTimeTo = dateStrings[1]
}
},
// 重置
btnReset () {
this.createValue = []
this.queryParams.createTimeFrom = ''
this.queryParams.createTimeTo = ''
},
}
ant design vue日期组件怎么清空(a-range-picker)
最新推荐文章于 2024-09-27 16:55:42 发布