开始日期不能大于或等于结束日期!
This commit is contained in:
@@ -113,8 +113,7 @@ export default {
|
||||
// console.log(res);
|
||||
})
|
||||
},
|
||||
|
||||
filterBtn() {},
|
||||
|
||||
reset() {
|
||||
this.startTime = '',
|
||||
this.endTime = ''
|
||||
@@ -122,6 +121,15 @@ export default {
|
||||
selectConfirm() {
|
||||
this.start = this.startTime,
|
||||
this.end = this.endTime
|
||||
let startTmp = this.start.split("-");
|
||||
let endTmp = this.end.split("-");
|
||||
let stT = new Date(startTmp[0], startTmp[1], startTmp[2]);
|
||||
let edT = new Date(endTmp[0], endTmp[1], endTmp[2]);
|
||||
if (stT.getTime() >= edT.getTime()) {
|
||||
this.$u.toast("开始日期不能大于或等于结束日期!");
|
||||
this.filterShow = true
|
||||
return
|
||||
}
|
||||
this.filterShow = false
|
||||
this.getList()
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user