import request from '@/config/axios'

export const addJx = async (data) => {
  return await request.post({
    url: '/admin-api/applet/xunjia/question/jx/add',
    data: data
  })
}

export const getJxQuestionList = async (params) => {
  return await request.get({
    url: '/admin-api/applet/xunjia/question/jx/list',
    params: params
  })
}

export const delJxData = async (id) => {
  return await request.delete({
    url: `/admin-api/applet/xunjia/question/jx/delete?id=${id}`
  })
}

export const addMj = async (data) => {
  return await request.post({
    url: '/admin-api/applet/xunjia/secret/add',
    data: data
  })
}

export const getMjList = async (params) => {
  return await request.get({
    url: '/admin-api/applet/xunjia/secret/list',
    params: params
  })
}

export const delMj = async (secretId) => {
  return await request.delete({
    url: `/admin-api/applet/xunjia/secret/delete?secretId=${secretId}`
  })
}

export const clearMj = async (secretId) => {
  return await request.delete({
    url: `/admin-api/applet/xunjia/secret/clear?secretId=${secretId}`
  })
}

export const getMjQuestionList = async (params) => {
  return await request.get({
    url: '/admin-api/applet/xunjia/secret/question/list',
    params: params
  })
}

export const addMjQuestion = async (data) => {
  return await request.post({
    url: '/admin-api/applet/xunjia/secret/question/add',
    data: data
  })
}

export const delMjQuestion = async (id) => {
  return await request.delete({
    url: `/admin-api/applet/xunjia/secret/question/delete?id=${id}`
  })
}
