-
Notifications
You must be signed in to change notification settings - Fork 2
教員の論理削除を追加 #775
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
教員の論理削除を追加 #775
Conversation
…9-teacher-logical-delete
Kubosaka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
いくつかコメントしました
→指摘してるくせに自分のコードができていなかったみたいです
|
|
||
| export const del = async (url: string, data: number[]) => { | ||
| const res = await fetch(url, { | ||
| method: 'DELETE', | ||
| mode: 'cors', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| }, | ||
| body: JSON.stringify({ deleteIDs: data }), | ||
| }); | ||
| return await res.status; | ||
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
これusersと共有みたいだし、まとめてもらってもいい?
…9-teacher-logical-delete
…Fes/FinanSu into feat/hikahana/769-teacher-logical-delete
Kubosaka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
コメントしました
| return res; | ||
| }; | ||
|
|
||
| export const dels = async (url: string, data: number[]) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
関数名が分かりにくいので、multiDelとかにして欲しいです
Kubosaka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM

対応Issue
resolve #769
概要
teacherのカラムにis_deletedを追加し、これのbooleanで論理削除を行うようにした。
sql文のgetでis_deletedがfalseのものを取得するように修正した。
MultiDestoryを追加し、複数削除をできるようにした。
上に伴い、teachersの削除を複数で行えるようにチェックボックスを配置した。
画面スクリーンショット等
URLスクリーンショット
テスト項目
-vからのmake buildでteacherのカラムにis_deletedが追加されているかlocalhost:3000/teachersにアクセスし、教員の複数削除が行えるか備考
API作って満足してました。
これから削除するページ作ります。
ps.
teachersはあった。複数削除できるようにしてみた