123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- import http from "@/api/http.js"
- /* 培训管理模块 */
- //标签管理
- export const TagInterface = {
- /**
- * 获取标签列表
- * @param {Object} params
- * @param {Number} params.PageSize
- * @param {Number} params.CurrentIndex
- * @param {String} params.Keyword
- * @returns
- */
- getTagList:(params)=>{
- return http.get('/eta_training_video/tag/page_list',params)
- },
- /**
- * 新增标签
- * @param {Object} params
- * @param {String} params.TagName
- * @returns
- */
- addTag:(params)=>{
- return http.post('/eta_training_video/tag/add',params)
- },
- /**
- * 编辑标签
- * @param {Object} params
- * @param {Number} params.TagId
- * @param {String} params.TagName
- * @returns
- */
- editTag:(params)=>{
- return http.post('/eta_training_video/tag/edit',params)
- },
- /**
- * 删除标签
- * @param {Object} params
- * @param {Number} params.TagId
- * @returns
- */
- deleteTag:(params)=>{
- return http.post('/eta_training_video/tag/remove',params)
- }
- }
- //分类管理
- export const ClassifyInterface = {
- /**
- * 获取分类列表
- * @param {Object} params
- * @param {Number} params.Keyword
- * @returns
- */
- getClassifyList:(params)=>{
- return http.get('/eta_training_video/classify/tree',params)
- },
- /**
- * 新增分类
- * @param {Object} params
- * @param {Number} params.ParentId
- * @param {String} params.ClassifyName
- * @returns
- */
- addClassify:(params)=>{
- return http.post('/eta_training_video/classify/add',params)
- },
- /**
- * 编辑分类
- * @param {Object} params
- * @param {Number} params.ParentId
- * @param {Number} params.ClassifyId
- * @param {String} params.ClassifyName
- * @returns
- */
- editClassify:(params)=>{
- return http.post('/eta_training_video/classify/edit',params)
- },
- /**
- * 删除分类
- * @param {Object} params
- * @param {Number} params.ClassifyId
- * @returns
- */
- deleteClassify:(params)=>{
- return http.post('/eta_training_video/classify/remove',params)
- }
- }
- //视频管理
- export const VideoInterface = {
- /**
- * 获取视频列表
- * @param {Object} params
- * @param {Number} params.PageSize
- * @param {Number} params.CurrentIndex
- * @param {String} params.Keyword
- * @param {String} params.StartTime
- * @param {String} params.EndTime
- * @param {Number} params.ClassifyId
- * @param {String} params.TagIds 标签IDs, 英文逗号拼接
- * @param {Number} params.PublishState 发布状态:1-未发布;2-已发布
- * @returns
- */
- getVideoList:(params)=>{
- return http.get('/eta_training_video/page_list',params)
- },
- /**
- * 新增视频
- * @param {Object} params
- * @param {String} params.Title
- * @param {String} params.Introduce
- * @param {String} params.CoverImg
- * @param {String} params.VideoUrl
- * @param {Number} params.ClassifyId
- * @param {Array} params.TagIds
- * @returns
- */
- addVideo:(params)=>{
- return http.post('/eta_training_video/add',params)
- },
- /**
- * 编辑视频
- * @param {Object} params
- * @param {Number} params.VideoId
- * 其他同上
- * @returns
- */
- editVideo:(params)=>{
- return http.post('/eta_training_video/edit',params)
- },
- /**
- * 发布/取消发布视频
- * @param {Object} params
- * @param {Number} params.VideoId
- * @param {Number} params.PublishState 发布状态:0-取消发布;1-发布
- * @returns
- */
- publishVideo:(params)=>{
- return http.post('/eta_training_video/publish',params)
- },
- /**
- * 删除视频
- * @param {Object} params
- * @param {Number} params.VideoId
- * @returns
- */
- deleteVideo:(params)=>{
- return http.post('/eta_training_video/remove',params)
- },
- /**
- * 获取视频详情
- * @param {Object} params
- * @param {Number} params.VideoId
- * @returns
- */
- getVideoDetail:(params)=>{
- return http.get('/eta_training_video/detail',params)
- }
- }
|