From c2a4a644171b42442d83730ea4dc69b912799297 Mon Sep 17 00:00:00 2001 From: Yu Sung Date: Thu, 16 Jan 2025 02:34:48 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9D=B4=EB=B2=A4=ED=8A=B8=20=EB=B0=B0?= =?UTF-8?q?=EB=84=88=20API=20-=20Admin=20API=20URL=EB=A1=9C=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/event.js | 8 ++++---- src/views/Promotion/EventView.vue | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/api/event.js b/src/api/event.js index 58862fd..60c9806 100644 --- a/src/api/event.js +++ b/src/api/event.js @@ -1,7 +1,7 @@ import Vue from 'vue'; async function save(formData) { - return Vue.axios.post('/event', formData, { + return Vue.axios.post('/admin/event/banner', formData, { headers: { "Content-Type": "multipart/form-data", }, @@ -9,7 +9,7 @@ async function save(formData) { } async function modify(formData) { - return Vue.axios.put('/event', formData, { + return Vue.axios.put('/admin/event/banner', formData, { headers: { "Content-Type": "multipart/form-data", }, @@ -17,11 +17,11 @@ async function modify(formData) { } async function deleteEvent(id) { - return Vue.axios.delete("/event/" + id) + return Vue.axios.delete("/admin/event/banner/" + id) } async function getEvents() { - return Vue.axios.get("/event") + return Vue.axios.get("/admin/event/banner") } export {save, modify, deleteEvent, getEvents} diff --git a/src/views/Promotion/EventView.vue b/src/views/Promotion/EventView.vue index 3c94f33..5b914ef 100644 --- a/src/views/Promotion/EventView.vue +++ b/src/views/Promotion/EventView.vue @@ -343,7 +343,7 @@ export default { try { const res = await api.getEvents(this.page) if (res.status === 200 && res.data.success === true) { - this.events = res.data.data.eventList + this.events = res.data.data } else { this.notifyError(res.data.message || '알 수 없는 오류가 발생했습니다. 다시 시도해 주세요.') }