import request from '@/utils/request'

//热门商品
export function hotSkuList() {
  return request({
    url: '/mall-sku/hotSku/list',
    method: 'get',
  })
}
//商城新品
export function newSkuList() {
  return request({
    url: '/mall-sku/newSku/list',
    method: 'get',
  })
}

//首页活动
export function indexList() {
  return request({
    url: '/mall-act/user/index/list',
    method: 'get',
  })
}


//2024中秋签到
export function MidAutumnSignIn(query) {
  return request({
    url: '/MidAutumn/Activity/signIn',
    method: 'get',
    params:query
  })
}
//获取培训上传备注
export function remarkHtml(query) {
  return request({
    url: '/news/mall/getNotice',
    method: 'get',
    params: query
  })
}

//员工互动记录列表
export function postList(query) {
  return request({
    url: '/mall-post/user/center/list',
    method: 'get',
    params:query
  })
}

//员工互动提交
export function postInteractSave(data) {
  return request({
    url: '/mall-post/add/comment',
    method: 'post',
    data
  })
}

//员工互动列表
export function postInteractList(query) {
  return request({
    url: '/mall-post/user/list',
    method: 'get',
    params:query
  })
}

//员工互动详情
export function postInteractInfo(query) {
  return request({
    url: '/mall-post/user/answer/info',
    method: 'get',
    params:query
  })
}

//个人中心用户答题记录列表
export function answerList(query) {
  return request({
    url: '/answer/user/list',
    method: 'get',
    params:query
  })
}

//用户游戏记录列表
export function gameLogList(query) {
  return request({
    url: '/MoonFestival/user/game/log',
    method: 'get',
    params:query
  })
}

// //用户游戏记录列表
// export function gameLogList(query) {
//   return request({
//     url: '/MoonFestival/user/top',
//     method: 'get',
//     params:query
//   })
// }

//用户抽奖记录列表
export function prizeList(query) {
  return request({
    url: '/mall-prize/prize/user/log',
    method: 'get',
    params:query
  })
}

//用户阅读消息中心
export function readAllMsg(query) {
  return request({
    url: '/mall-user/msg/readAll',
    method: 'post',
    params:query
  })
}

//用户阅读消息中心
export function readMsg(query) {
  return request({
    url: '/mall-user/msg/read',
    method: 'post',
    params:query
  })
}

//用户没过期兑换卷列表
export function couponList(query) {
  return request({
    url: '/coupon/user/list',
    method: 'get',
    params:query
  })
}

// 每日问答-首页数据
export function homeData(query) {
  return request({
    url: '/answer/top',
    method: 'get',
    params:query
  })
}

// 每日问答-获取题目
export function questionList(query) {
  return request({
    url: '/answer/room',
    method: 'get',
    params:query
  })
}

// 每日问答-提交答案
export function submitAnswer(data) {
  return request({
    url: '/answer/submit',
    method: 'post',
    data
  })
}
// 字典列表
export function dictList(query) {
  return request({
    url: '/system/dict/data/type',
    method: 'get',
    params:query
  })
}

// 人员列表
export function allUserList(query) {
  return request({
    url: '/sys/user/getAll',
    method: 'post',
    params:query
  })
}

// 培训列表
export function trainList(query) {
  return request({
    url: '/mall-train/user/page',
    method: 'get',
    params:query
  })
}

//培训上传
export function uploadTrain(data) {
  return request({
    url: '/mall-train/user/upload',
    method: 'post',
    data
  })
}
//培训修改
export function editTrain(data) {
  return request({
    url: '/mall-train/user/edit',
    method: 'post',
    data
  })
}



// 客户表彰列表
export function citeList(query) {
  return request({
    url: '/customer/commend/user/page',
    method: 'get',
    params:query
  })
}


//表彰修改
export function editCite(data) {
  return request({
    url: '/customer/commend/user/edit',
    method: 'post',
    data
  })
}

//客户表彰上传
export function uploadCite(data) {
  return request({
    url: '/customer/commend/upload',
    method: 'post',
    data
  })
}

// 初始化积分领取
export function lockStatus(query) {
  return request({
    url: 'mall-user/lockStatus',
    method: 'get',
    params:query
  })
}
// 初始化积分领取
export function unlock(query) {
  return request({
    url: '/mall-user/unlock',
    method: 'post',
    params:query
  })
}
// 节日活动
export function actList(data) {
  return request({
    url: '/mall-act/user/list',
    method: 'get',
    data
  })
}
//积分规则类型
export function integralTypes(query) {
  return request({
    url: '/system/dict/data/type',
    method: 'get',
    params:query
  })
}
// 员工积分记录列表
export function userlogs(query) {
  return request({
    url: '/mall-integral/userlogs',
    method: 'get',
    params:query
  })
}
//表彰墙
export function commendPage(query) {
  return request({
    url: '/mall-integral-obtain/commend/user/page',
    method: 'get',
    params:query
  })
}

//勋章墙
export function medalList(query) {
  return request({
    url: '/mall-user-medal/list',
    method: 'get',
    params:query
  })
}

// 表彰详情
export function commendDetail(query) {
  return request({
    url: '/mall-commend/commend/staff/info',
    method: 'get',
    params: query
  })
}

//证书类型
export function certificatType(query) {
  return request({
    url: '/mall-certificat/list',
    method: 'get',
    params:query
  })
}

//证书列表
export function certificatePage(query) {
  return request({
    url: '/mall-integral-obtain/certificate/user/page',
    method: 'post',
    params:query
  })
}

//证书上传
export function certificateUpload(data) {
  return request({
    url: '/mall-integral-obtain/certificate/upload',
    method: 'post',
    data
  })
}

//用户-积分排行榜
export function integralTop(query) {
  return request({
    url: '/mall-integral/user/top',
    method: 'get',
    params:query
  })
}

// 商品兑换列表
export function integralList(query) {
  return request({
    url: '/mall-sku/integral/user/list',
    method: 'get',
    params:query
  })
}

// 商品详情
export function integralInfo(query) {
  return request({
    url: '/mall-sku/integral/info',
    method: 'get',
    params: query
  })
}

// 节日礼品兑换列表
export function festivalList(query) {
  return request({
    url: '/mall-sku/festival/user/list',
    method: 'post',
    params: query
  })
}

// 节日礼品详情
export function festivalInfo(query) {
  return request({
    url: '/mall-sku/festival/user/info',
    method: 'get',
    params: query
  })
}
// 兑换须知   商品兑换须知 goodsNotice 礼品兑换须知giftNotice  积分规则integralNotice
export function notice(query) {
  return request({
    url: '/news/mall/getNotice',
    method: 'get',
    params: query
  })
}

//积分兑换
export function start(query) {
  return request({
    url: '/mall-order/start',
    method: 'post',
    data:query
  })
}
//福利券兑换
export function kill(query) {
  return request({
    url: '/mall-order/coupon/start',
    method: 'post',
    data:query
  })
}


//福利分类
export function welfareType(data) {
  return request({
    url: '/mall-sku/user/getWelfare',
    method: 'post',
    data
  })
}


//兑换券列表
export function myWelfareList(query) {
  return request({
    url: '/coupon/user/centre/list',
    method: 'get',
    params:query
  })
}

//用户福利
export function welfareList(query) {
  return request({
    url: '/mall-act/user/welfare/list',
    method: 'get',
    params:query
  })
}

//用户福利领取
export function receiveWelfare(query) {
  return request({
    url: '/coupon/user/receive',
    method: 'post',
    params:query
  })
}


//用户兑换列表
export function orderList(query) {
  return request({
    url: '/mall-order/user/list',
    method: 'post',
    params:query
  })
}

//订单详情
export function orderInfo(query) {
  return request({
    url: '/mall-order/info',
    method: 'post',
    params:query
  })
}


//员工确认
export function orderConfirm(query) {
  return request({
    url: '/mall-order/user/confirm',
    method: 'post',
    params:query
  })
}

//首页消息列表
export function msgList(query) {
  return request({
    url: '/mall-msg/page',
    method: 'get',
    params:query
  })
}

//首页消息详情
export function msgInfo(query) {
  return request({
    url: '/mall-msg/info',
    method: 'get',
    params:query
  })
}

//首页获取用户信息
export function useInfo(query) {
  return request({
    url: '/mall-integral/getUseInfo',
    method: 'get',
    params:query
  })
}


export function sign(query) {
  return request({
    url: '/mall-sign/sgin',
    method: 'post',
    params:query
  })
}

export function signInfo(query) {
  return request({
    url: '/mall-sign/signCount',
    method: 'get',
    params:query
  })
}

export function deleteNews(data) {
  return request({
    url: '/news/delete',
    method: 'post',
    data
  })
}

export function deleteAllNews(data) {
  return request({
    url: '/news/deleteQuantity',
    method: 'post',
    params: data
  })
}

//侧边栏中奖记录列表
export function winningList(query) {
  return request({
    url: '/mall-act/user/winning/list',
    method: 'get',
    params:query
  })
}
