You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.1 KiB
47 lines
1.1 KiB
import request from '@/config/axios'
|
|
|
|
export interface VideoVO {
|
|
id: number
|
|
titleEn: string
|
|
content: string
|
|
contentEn: string
|
|
source: string
|
|
sourceEn: string
|
|
viewsCount: number
|
|
memo: string
|
|
status: number
|
|
sort: number
|
|
title: string
|
|
picUrl: string
|
|
videoUrl: string
|
|
}
|
|
|
|
// 查询视频列表
|
|
export const getVideoPage = async (params) => {
|
|
return await request.get({ url: '/cms/video/page', params })
|
|
}
|
|
|
|
// 查询视频详情
|
|
export const getVideo = async (id: number) => {
|
|
return await request.get({ url: '/cms/video/get?id=' + id })
|
|
}
|
|
|
|
// 新增视频
|
|
export const createVideo = async (data: VideoVO) => {
|
|
return await request.post({ url: '/cms/video/create', data })
|
|
}
|
|
|
|
// 修改视频
|
|
export const updateVideo = async (data: VideoVO) => {
|
|
return await request.put({ url: '/cms/video/update', data })
|
|
}
|
|
|
|
// 删除视频
|
|
export const deleteVideo = async (id: number) => {
|
|
return await request.delete({ url: '/cms/video/delete?id=' + id })
|
|
}
|
|
|
|
// 导出视频 Excel
|
|
export const exportVideoApi = async (params) => {
|
|
return await request.download({ url: '/cms/video/export-excel', params })
|
|
}
|