mirror of
https://github.com/SimpleMobileTools/Simple-Calendar.git
synced 2025-02-07 05:55:26 +01:00
Merge pull request #1167 from Honk2/master
modified day code validation for multi day events to fix 1164
This commit is contained in:
commit
847262170b
@ -601,8 +601,9 @@ class WeekFragment : Fragment(), WeeklyCalendar {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
val dayCode = Formatter.getDayCodeFromDateTime(startDateTime)
|
val dayCodeStart = Formatter.getDayCodeFromDateTime(startDateTime).toInt()
|
||||||
val dayOfWeek = dayColumns.indexOfFirst { it.tag == dayCode }
|
val dayCodeEnd = Formatter.getDayCodeFromDateTime(endDateTime).toInt()
|
||||||
|
val dayOfWeek = dayColumns.indexOfFirst { it.tag.toInt() == dayCodeStart || (it.tag.toInt() > dayCodeStart && it.tag.toInt() <= dayCodeEnd) }
|
||||||
if (dayOfWeek == -1) {
|
if (dayOfWeek == -1) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user