This commit is contained in:
Pan
2017-08-28 13:12:44 +08:00
committed by 花裤衩
parent b98860ace1
commit f7aee3b5a3
50 changed files with 386 additions and 416 deletions

View File

@@ -1,16 +1,25 @@
import fetch from 'utils/fetch'
import fetch from '@/utils/fetch'
export function getList() {
export function fetchList(query) {
return fetch({
url: '/article/list',
method: 'get'
method: 'get',
params: query
})
}
export function getArticle() {
export function fetchArticle() {
return fetch({
url: '/article/detail',
method: 'get'
})
}
export function fetchPv(pv) {
return fetch({
url: '/article/pv',
method: 'get',
params: { pv }
})
}

View File

@@ -1,17 +0,0 @@
import fetch from 'utils/fetch'
export function fetchList(query) {
return fetch({
url: '/article_table/list',
method: 'get',
params: query
})
}
export function fetchPv(pv) {
return fetch({
url: '/article_table/pv',
method: 'get',
params: { pv }
})
}

View File

@@ -1,4 +1,4 @@
import fetch from 'utils/fetch'
import fetch from '@/utils/fetch'
export function loginByUsername(username, password) {
const data = {

View File

@@ -1,4 +1,4 @@
import fetch from 'utils/fetch'
import fetch from '@/utils/fetch'
export function getToken() {
return fetch({

View File

@@ -1,4 +1,4 @@
import fetch from 'utils/fetch'
import fetch from '@/utils/fetch'
export function userSearch(name) {
return fetch({