fix end_datetime
This commit is contained in:
parent
184896bff8
commit
10d8eb0107
2 changed files with 5 additions and 2 deletions
|
@ -249,7 +249,7 @@ export default {
|
|||
if (!!this.date.multidate) {
|
||||
formData.append('end_datetime', this.$time.fromDateInput(this.date.due, this.date.dueHour || '23:59'))
|
||||
} else if (this.date.dueHour) {
|
||||
formData.append('end_datetime', this.$time.fromDateInput(this.date.from, this.date.dueHour))
|
||||
formData.append('end_datetime', this.$time.fromDateInput(this.date.due, this.date.dueHour))
|
||||
}
|
||||
|
||||
if (this.edit) {
|
||||
|
|
|
@ -83,7 +83,10 @@ export default {
|
|||
const max = this.selectedDay.endOf('day').toUnixInteger()
|
||||
return this.events.filter(e => (e.start_datetime <= max && (e.end_datetime || e.start_datetime) >= min) && (this.filter.show_recurrent || !e.parentId))
|
||||
} else if (this.isCurrentMonth && !this.filter.query) {
|
||||
return this.events.filter(e => ((e.end_datetime ? e.end_datetime >= now : e.start_datetime + 3 * 60 * 60 >= now) && (this.filter.show_recurrent || !e.parentId)))
|
||||
return this.events.filter(e => {
|
||||
const max_datetime = Math.max(e.start_datetime, e.end_datetime)
|
||||
return (e.end_datetime ? max_datetime >= now : e.start_datetime + 3 * 60 * 60 >= now) && (this.filter.show_recurrent || !e.parentId)
|
||||
})
|
||||
} else {
|
||||
return this.events.filter(e => this.filter.show_recurrent || !e.parentId)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue