no message
Former-commit-id: a686cbec6aa82ccf0a5a2f738602d72ff3fa00e5 Former-commit-id: 7e986278ddb45ad7f2373e759f923148f92a3981 Former-commit-id: 4efa4699c64d12049ead46e050e95d495364516b
This commit is contained in:
24
src/mock/chart/G2Column.js
Normal file
24
src/mock/chart/G2Column.js
Normal file
@@ -0,0 +1,24 @@
|
||||
import Mock from 'mockjs'
|
||||
|
||||
Mock.mock('/api/chart/G2Column', 'post', ({body, type, url}) => {
|
||||
const _body = JSON.parse(body)
|
||||
switch (_body.code) {
|
||||
case 1:
|
||||
return {
|
||||
code: 0,
|
||||
msg: '请求成功',
|
||||
data: [
|
||||
{ year: '1951 年', sales: 38 },
|
||||
{ year: '1952 年', sales: 52 },
|
||||
{ year: '1956 年', sales: 61 },
|
||||
{ year: '1957 年', sales: 145 },
|
||||
{ year: '1958 年', sales: 48 },
|
||||
{ year: '1959 年', sales: 38 },
|
||||
{ year: '1960 年', sales: 38 },
|
||||
{ year: '1962 年', sales: 38 }
|
||||
]
|
||||
}
|
||||
default:
|
||||
return {}
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user