Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

手動作成の授業の編集後の保存ができない #677

Open
HosokawaR opened this issue Apr 7, 2023 · 3 comments
Open

手動作成の授業の編集後の保存ができない #677

HosokawaR opened this issue Apr 7, 2023 · 3 comments

Comments

@HosokawaR
Copy link
Member

再現

  1. 手動で授業を作成
  2. その授業を編集する
    担当教員名のみを変更しても保存ボタンがアクティブにならない
@hayato24s
Copy link
Contributor

hayato24s commented Apr 7, 2023

roomscheduleを紐づけてないとか?

export const validateRooms = (rooms: Room[]): boolean => {
return rooms.every(
({ name, schedules }) => name !== "" && schedules.length > 0
);
};

@hayato24s
Copy link
Contributor

バリデーションを以下の2パターンで行なっています。

export const validateInstructors = (instructors: string[]): boolean => {
if (instructors.some((instructor) => instructor === "")) return false;
if (new Set(instructors).size !== instructors.length) return false;
return true;
};

@HosokawaR
Copy link
Member Author

担当教員名のみを変更しても保存ボタンがアクティブにならない

すみませんこれ逆でした

担当教員名を編集しないとアクティブにならない、です

2023-04-08.013915.mp4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants