245c026e50
CI / build (push) Failing after 14m56s
데모 user 대신 member 기반. 목록·검색·역할·상태 변경·삭제, 관리자 전용·모바일 대응 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
47 lines
1.2 KiB
JavaScript
47 lines
1.2 KiB
JavaScript
import http from './http'
|
|
|
|
// 관리자 태그 관리 API (/api/admin)
|
|
export const adminApi = {
|
|
categories() {
|
|
return http.get('/admin/tag-categories')
|
|
},
|
|
createCategory(payload) {
|
|
return http.post('/admin/tag-categories', payload)
|
|
},
|
|
updateCategory(id, payload) {
|
|
return http.put(`/admin/tag-categories/${id}`, payload)
|
|
},
|
|
removeCategory(id) {
|
|
return http.delete(`/admin/tag-categories/${id}`)
|
|
},
|
|
createTag(payload) {
|
|
return http.post('/admin/tags', payload)
|
|
},
|
|
updateTag(id, payload) {
|
|
return http.put(`/admin/tags/${id}`, payload)
|
|
},
|
|
removeTag(id) {
|
|
return http.delete(`/admin/tags/${id}`)
|
|
},
|
|
getBoardSetting() {
|
|
return http.get('/admin/board-setting')
|
|
},
|
|
setBoardSetting(tagCategoryId) {
|
|
return http.put('/admin/board-setting', { tagCategoryId })
|
|
},
|
|
|
|
// 회원 관리 (관리자)
|
|
members() {
|
|
return http.get('/admin/members')
|
|
},
|
|
updateMemberRole(id, role) {
|
|
return http.put(`/admin/members/${id}/role`, { role })
|
|
},
|
|
updateMemberStatus(id, status) {
|
|
return http.put(`/admin/members/${id}/status`, { status })
|
|
},
|
|
removeMember(id) {
|
|
return http.delete(`/admin/members/${id}`)
|
|
},
|
|
}
|