{"size": 1112, "ext": "js", "max_stars_repo_path": "src/api/index.js", "max_stars_repo_name": "gggg2614/geek-navigation-old", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/api/index.js", "max_issues_repo_name": "gggg2614/geek-navigation-old", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/api/index.js", "max_forks_repo_name": "gggg2614/geek-navigation-old", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 20.2181818182, "max_line_length": 58, "alphanum_fraction": 0.5989208633}

import request from './config'


const api = {
  getHome() {
    return request.get('/api/index')
  },
  addAudit(data) {
    return request.post('/api/audit/add', data)
  },
  getAuditList(status = 0) {
    return request.get(`/api/audit/list?status=${status}`)
  },
  delAuditNav(data) {
    return request.post('/api/audit/del', data)
  },
  fastRejectAudit() {
    return request.post('/api/audit/fastReject')
  },
  addNav(data) {
    return request.post('/api/nav/add', data)
  },
  editNav(data) {
    return request.post('/api/nav/edit', data)
  },
  delNav(id) {
    return request.post('/api/nav/del', {
      id,
    })
  },
  findNav(id) {
    return request.post('/api/nav/find', {
      id
    })
  },
  login(data) {
    return request.post('/api/login', data)
  },

  getCategoryList() {
    return request.get('/api/category/list')
  },
  addCategory(data) {
    return request.post('/api/category/add', data)
  },
  delCategory(id) {
    return request.post('/api/category/del', { id })
  },
  editCategory(data) {
    return request.post('/api/category/edit', data)
  },
}

export default api