import request from '@/utils/request'


export function getVideoList(query) {
  return request({
    url: '/vod/video/',
    method: 'get',
    params: query
  })
}

export function getsignature() {
  return request({
    url: '/vod/signature/',
    method: 'get'
  })
}
export function createVideo(data) {
  return request({
    url: '/vod/video/',
    method: 'post',
    data
  })
}
export function deletevideo(id, data) {
  return request({
    url: `/vod/video/${id}/`,
    method: 'delete',
    data
  })
}
export function updatevideo(id, data) {
  return request({
    url: `/vod/video/${id}/`,
    method: 'put',
    data
  })
}
export function getVideo(id) {
  return request({
    url: `/vod/video/${id}/`,
    method: 'get'
  })
}

export function getMyView(id, data) {
  return request({
    url: `/vod/video/${id}/myview/`,
    method: 'put',
    data
  })
}