text: import request from '@/utils/request'
  
  // 获取文章列表
  export function fetchList(params) {
      return request({
          url: '/article/selectArticle',
          method: 'post',
          data: {
              from: params.from,
              keyword: params.keyword,
              category: params.category
          },
      })
  }
  // 获取焦点
  export function fetchFocus() {
      return request({
          url: '/site/getFocus',
          method: 'get',
          params: {}
      })
  }
  
  // 目录
  export function fetchCategory() {
      return request({
          url: '/site/getCategory',
          method: 'get',
          params: {}
      })
  }
  
  // 社交信息
  export function fetchSocial() {
      return request({
          url: '/site/getSocial',
          method: 'get',
          params: {}
      });
  }
  
  // 网站信息
  export function fetchSiteInfo() {
      return request({
          url: '/site/getSite',
          method: 'get',
          params: {}
      })
  }
  
  // 文章内容
  export function fetchContent(id) {
      return request({
          url: '/article/getContent/' + id,
          method: 'get',
          params: {}
      })
  }
  // 归档
  export function fetchArchive() {
      return request({
          url: '/article/getArchive',
          method: 'get',
          params: {}
      })
  }
  
  // ------------------------------操作类--------------
  
  export function starArticle(id) {
      return request({
          url: '/article/star',
          method: 'get',
          params: {id: id}
      })
  }
  
  export function watchArticle(id) {
      return request({
          url: '/article/watch',
          method: 'get',
          params: {id: id}
      })
  }
  
  
  export function login(user) {
      return request({
          url: '/login',
          method: 'get',
          params: {
              username: user.username,
              password: user.password
          }
      })
  }
  
  
  