Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
mono424 committed Sep 27, 2023
1 parent e937127 commit 03dec0b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@
<template x-if="!lectureData.premiere && !lectureData.vodup">
<label :for="endId">
<span class="text-sm text-5">End</span>
<span class="text-sm font-light opacity-75"
x-change-set-listen.text="changeSet.durationFormatted"
>
<span :class="lectureData.duration > 0 ? 'text-sm font-light bg-gray-500/20 px-1 rounded opacity-75' : 'text-sm font-light bg-red-500 px-1 rounded opacity-75'"
x-text="lectureData.durationFormatted">

</span>
<input class="tl-input"
name="newEndTime"
Expand Down
7 changes: 5 additions & 2 deletions web/ts/edit-course.ts
Original file line number Diff line number Diff line change
Expand Up @@ -434,11 +434,14 @@ export function lectureEditor(lecture: Lecture): AlpineComponent {
// Save new date and time
if (changedKeys.includes("start") || changedKeys.includes("end")) {
const startDate = new Date(start);
const endDate = new Date(end)
const endDate = new Date(end);
endDate.setFullYear(startDate.getFullYear());
endDate.setMonth(startDate.getMonth());
endDate.setDate(startDate.getDate());
await DataStore.adminLectureList.updateStartEnd(courseId, lectureId, { start: startDate, end: endDate });
await DataStore.adminLectureList.updateStartEnd(courseId, lectureId, {
start: startDate,
end: endDate,
});
}

// Saving VideoSections
Expand Down

0 comments on commit 03dec0b

Please sign in to comment.