import request from '@/utils/request'

//1.资讯中心 start ------------------------------------->

//1.1 获取资讯列表
export function getArticleList(params) {
  return request({
    url: '/news/getArticleList',
    method: 'get',
    params
  })
}

//1.2 添加资讯
export function addArticle(data) {
  return request({
    url: '/news/addArticle',
    method: 'post',
    data
  })
}

//1.3 删除资讯
export function delArticle(data) {
  return request({
    url: '/news/delArticle',
    method: 'post',
    data
  })
}

//1.4 查看资讯
export function getArticleInfo(params) {
  return request({
    url: '/news/getArticleInfo',
    method: 'get',
    params
  })
}

//1.5 修改资讯内容
export function updateArticle(data) {
  return request({
    url: '/news/updateArticle',
    method: 'post',
    data
  })
}

//1.5 修改资讯状态
export function upArticleStatus(data) {
  return request({
    url: '/news/upArticleStatus',
    method: 'post',
    data
  })
}

