diff --git a/src/jvmMain/kotlin/de/kif/backend/route/Board.kt b/src/jvmMain/kotlin/de/kif/backend/route/Board.kt index 86d7bc3..5c21274 100644 --- a/src/jvmMain/kotlin/de/kif/backend/route/Board.kt +++ b/src/jvmMain/kotlin/de/kif/backend/route/Board.kt @@ -55,7 +55,7 @@ fun Route.board() { val refDay = Calendar.getInstance().also { it.time = todayDate }.get(Calendar.DAY_OF_YEAR) val todayDay = Calendar.getInstance().also { it.time = refDate }.get(Calendar.DAY_OF_YEAR) - val day = todayDay - refDay + val day = refDay - todayDay val list = ScheduleRepository.getByDay(day) val rooms = RoomRepository.all() diff --git a/src/jvmMain/kotlin/de/kif/backend/route/Calendar.kt b/src/jvmMain/kotlin/de/kif/backend/route/Calendar.kt index d6cdf91..2634573 100644 --- a/src/jvmMain/kotlin/de/kif/backend/route/Calendar.kt +++ b/src/jvmMain/kotlin/de/kif/backend/route/Calendar.kt @@ -199,7 +199,7 @@ fun Route.calendar() { val refDay = Calendar.getInstance().also { it.time = todayDate }.get(Calendar.DAY_OF_YEAR) val todayDay = Calendar.getInstance().also { it.time = refDate }.get(Calendar.DAY_OF_YEAR) - val day = todayDay - refDay + val day = refDay - todayDay call.respondRedirect("$prefix/calendar/$day", false) }