import { requestApi } from '../util/network'
// 获取视频
export const getLiveApplyList =
    (params) =>
      requestApi(
        '/seller_live_apply/get_live_apply_list',
        'POST',
        {
          'page': params.page,
          'per_page': params.per_page
        },
        'seller'
      )
export const getLiveApplyInfo =
    (live_apply_id) =>
      requestApi(
        '/seller_live_apply/get_live_apply_info',
        'POST',
        {
          live_apply_id: live_apply_id
        },
        'seller'
      )
// 视频保存
export const saveLiveApply =
    (live) =>
      requestApi(
        '/seller_live_apply/save_live_apply',
        'POST',
        live,
        'seller'
      )
export const joinLiveApply =
    (data) =>
      requestApi(
        '/seller_live_apply/join_live',
        'POST',
        data,
        'seller'
      )
export const leaveLiveApply =
    (data) =>
      requestApi(
        '/seller_live_apply/leave_live',
        'POST',
        data,
        'seller'
      )
export const changeLiveApply =
    (data) =>
      requestApi(
        '/seller_live_apply/change_live',
        'POST',
        data,
        'seller'
      )
// 删除视频
export const delLiveApply =
    (live_apply_id) =>
      requestApi(
        '/seller_live_apply/del_live_apply',
        'POST',
        {
          live_apply_id: live_apply_id
        },
        'seller'
      )
// 上传封面
export const uploadInfoFile =
    (file) =>
      requestApi(
        '/seller_live_apply/image_upload',
        'POST',
        file,
        'seller',
        true
      )
