회원 탈퇴와 덱 일괄 삭제 추가
This commit is contained in:
@@ -201,6 +201,13 @@ const UaDeckApi = (() => {
|
||||
body: JSON.stringify({ currentPassword, newPassword }),
|
||||
}),
|
||||
|
||||
/** @param {string} confirmation */
|
||||
deleteMyAccount: (confirmation) =>
|
||||
request('/auth/me', {
|
||||
method: 'DELETE',
|
||||
body: JSON.stringify({ confirmation }),
|
||||
}),
|
||||
|
||||
/** @param {string} shareCode */
|
||||
getDeck: (shareCode) => request(`/decks/${shareCode}`),
|
||||
|
||||
@@ -257,6 +264,13 @@ const UaDeckApi = (() => {
|
||||
body: JSON.stringify({ newPassword }),
|
||||
}),
|
||||
|
||||
/** @param {number} id @param {string} confirmation */
|
||||
adminDeleteUser: (id, confirmation) =>
|
||||
request(`/admin/users/${id}`, {
|
||||
method: 'DELETE',
|
||||
body: JSON.stringify({ confirmation }),
|
||||
}),
|
||||
|
||||
adminGetDecks: () => request('/admin/decks'),
|
||||
|
||||
adminGetOrphanPreviews: () => request('/admin/previews/orphans'),
|
||||
@@ -268,6 +282,13 @@ const UaDeckApi = (() => {
|
||||
adminCreatePreset: (body) =>
|
||||
request('/admin/decks/preset', { method: 'POST', body: JSON.stringify(body) }),
|
||||
|
||||
/** @param {string[]} shareCodes */
|
||||
adminDeleteDecks: (shareCodes) =>
|
||||
request('/admin/decks/bulk-delete', {
|
||||
method: 'POST',
|
||||
body: JSON.stringify({ shareCodes }),
|
||||
}),
|
||||
|
||||
/** @param {string} shareCode */
|
||||
adminDeleteDeck: (shareCode) =>
|
||||
request(`/admin/decks/${shareCode}`, { method: 'DELETE' }),
|
||||
|
||||
Reference in New Issue
Block a user