fix: hide event ending at 00:00 in the next day, fix #352

This commit is contained in:
lesion 2024-08-05 18:40:59 +02:00
parent a10ccb3007
commit 10a2aa0e7c
No known key found for this signature in database
GPG key ID: 352918250B012177

View file

@ -88,7 +88,7 @@ export default {
if (this.selectedDay) { if (this.selectedDay) {
const min = this.selectedDay.startOf('day').toUnixInteger() const min = this.selectedDay.startOf('day').toUnixInteger()
const max = this.selectedDay.endOf('day').toUnixInteger() 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)) return this.events.filter(e => (e.start_datetime <= max && (e.end_datetime || (e.start_datetime + 1)) > min) && (this.filter.show_recurrent || !e.parentId))
} else if (this.isCurrentMonth && !this.filter.query) { } else if (this.isCurrentMonth && !this.filter.query) {
return this.events.filter(e => { return this.events.filter(e => {
const max_datetime = Math.max(e.start_datetime, e.end_datetime) const max_datetime = Math.max(e.start_datetime, e.end_datetime)