import request from "@/utils/request";

// 查询网络文章列表
export function listArticle(query) {
  return request({
    url: "/zongzhi/article/list",
    method: "get",
    params: query,
  });
}

// 查询网络文章详细
export function getArticle(id) {
  return request({
    url: "/zongzhi/article/" + id,
    method: "get",
  });
}

// 新增网络文章
export function addArticle(data) {
  return request({
    url: "/zongzhi/article",
    method: "post",
    data: data,
  });
}

// 修改网络文章
export function updateArticle(data) {
  return request({
    url: "/zongzhi/article",
    method: "put",
    data: data,
  });
}

// 删除网络文章
export function delArticle(id) {
  return request({
    url: "/zongzhi/article/" + id,
    method: "delete",
  });
}

// 导出网络文章
export function exportArticle(data) {
  return request({
    url: "/zongzhi/article/export",
    method: "post",
    data,
  });
}
