import service from '@/utils/request'

// @Tags Arts
// @Summary 创建Arts
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.Arts true "创建Arts"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /arts/createArts [post]
export const createArts = (data) => {
  return service({
    url: '/arts/createArts',
    method: 'post',
    data
  })
}

// @Tags Arts
// @Summary 删除Arts
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.Arts true "删除Arts"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /arts/deleteArts [delete]
export const deleteArts = (data) => {
  return service({
    url: '/arts/deleteArts',
    method: 'delete',
    data
  })
}

// @Tags Arts
// @Summary 删除Arts
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body request.IdsReq true "批量删除Arts"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /arts/deleteArts [delete]
export const deleteArtsByIds = (data) => {
  return service({
    url: '/arts/deleteArtsByIds',
    method: 'delete',
    data
  })
}

// @Tags Arts
// @Summary 更新Arts
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.Arts true "更新Arts"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"更新成功"}"
// @Router /arts/updateArts [put]
export const updateArts = (data) => {
  return service({
    url: '/arts/updateArts',
    method: 'put',
    data
  })
}

// @Tags Arts
// @Summary 用id查询Arts
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query model.Arts true "用id查询Arts"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"查询成功"}"
// @Router /arts/findArts [get]
export const findArts = (params) => {
  return service({
    url: '/arts/findArts',
    method: 'get',
    params
  })
}

// @Tags Arts
// @Summary 分页获取Arts列表
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query request.PageInfo true "分页获取Arts列表"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /arts/getArtsList [get]
export const getArtsList = (params) => {
  return service({
    url: '/arts/getArtsList',
    method: 'get',
    params
  })
}
