콘텐츠 리스트 - 오픈 / 오픈 예정 추가

This commit is contained in:
Yu Sung 2024-10-16 12:34:04 +09:00
parent 704b8803f5
commit f460b76ff7
2 changed files with 22 additions and 21 deletions

View File

@ -1,8 +1,8 @@
import Vue from 'vue';
async function getAudioContentList(page) {
async function getAudioContentList(status, page) {
return Vue.axios.get(
"/admin/audio-content/list?page=" + (page - 1) +
"/admin/audio-content/list?status=" + status + "&page=" + (page - 1) +
"&size=10"
)
}

View File

@ -10,26 +10,25 @@
<v-container>
<v-row>
<v-col>
<v-text-field
v-model="utm_source"
label="예) youtube, google"
/>
<v-col cols="8">
<v-radio-group
v-model="status"
row
@change="getAudioContent"
>
<v-radio
label="오픈됨"
value="OPEN"
/>
<v-radio
label="오픈예정"
value="SCHEDULED"
/>
</v-radio-group>
</v-col>
<v-spacer />
<v-col>
<v-text-field
v-model="utm_medium"
label="예) email, cpc"
/>
</v-col>
<v-col>
<v-text-field
v-model="utm_campaign"
label="예) 화이트데이"
/>
</v-col>
<v-col cols="2" />
<v-col cols="4">
<v-text-field
v-model="search_word"
label="콘텐츠 제목 혹은 크리에이터 닉네임을 입력하세요"
@ -412,6 +411,7 @@ export default {
show_delete_confirm_dialog: false,
page: 1,
total_page: 0,
status: 'OPEN',
search_word: '',
audio_content: {},
audio_contents: [],
@ -621,10 +621,11 @@ export default {
async getAudioContent() {
this.is_loading = true
try {
const res = await api.getAudioContentList(this.page)
const res = await api.getAudioContentList(this.status, this.page)
if (res.status === 200 && res.data.success === true) {
const data = res.data.data
console.log(data.totalCount)
const total_page = Math.ceil(data.totalCount / 10)
this.audio_contents = data.items