Compare commits
No commits in common. "174f5ac79e38c48df43cf60ed489a24dffa4a7c1" and "8b739366c0f600bde07636dcd6ba199bc89be863" have entirely different histories.
174f5ac79e
...
8b739366c0
|
@ -1,7 +1,5 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
presets: [
|
presets: [
|
||||||
'@vue/cli-plugin-babel/preset'
|
'@vue/cli-plugin-babel/preset'
|
||||||
],
|
]
|
||||||
plugins: ['transform-remove-console']
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
"echarts": "^4.8.0",
|
"echarts": "^4.8.0",
|
||||||
"element-ui": "^2.13.2",
|
"element-ui": "^2.13.2",
|
||||||
"lodash": "^4.17.15",
|
"lodash": "^4.17.15",
|
||||||
"nprogress": "^0.2.0",
|
|
||||||
"vue": "^2.6.11",
|
"vue": "^2.6.11",
|
||||||
"vue-quill-editor": "^3.0.6",
|
"vue-quill-editor": "^3.0.6",
|
||||||
"vue-router": "^3.2.0",
|
"vue-router": "^3.2.0",
|
||||||
|
@ -26,7 +25,6 @@
|
||||||
"@vue/cli-service": "~4.4.0",
|
"@vue/cli-service": "~4.4.0",
|
||||||
"@vue/eslint-config-standard": "^5.1.2",
|
"@vue/eslint-config-standard": "^5.1.2",
|
||||||
"babel-eslint": "^10.1.0",
|
"babel-eslint": "^10.1.0",
|
||||||
"babel-plugin-transform-remove-console": "^6.9.4",
|
|
||||||
"eslint": "^6.7.2",
|
"eslint": "^6.7.2",
|
||||||
"eslint-plugin-import": "^2.20.2",
|
"eslint-plugin-import": "^2.20.2",
|
||||||
"eslint-plugin-node": "^11.1.0",
|
"eslint-plugin-node": "^11.1.0",
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -17,7 +17,8 @@ import echarts from 'echarts'
|
||||||
import _ from 'lodash'
|
import _ from 'lodash'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: {},
|
props: {
|
||||||
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
|
@ -57,7 +58,9 @@ export default {
|
||||||
const chart = echarts.init(document.querySelector('#main'))
|
const chart = echarts.init(document.querySelector('#main'))
|
||||||
this.$http.get('reports/type/1').then(response => {
|
this.$http.get('reports/type/1').then(response => {
|
||||||
const res = response.data
|
const res = response.data
|
||||||
|
console.log(res.data, this.options)
|
||||||
const r = _.merge(res.data, this.options)
|
const r = _.merge(res.data, this.options)
|
||||||
|
console.log(r)
|
||||||
chart.setOption(r)
|
chart.setOption(r)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
10
src/main.js
10
src/main.js
|
@ -14,25 +14,17 @@ import 'quill/dist/quill.snow.css' // for snow theme
|
||||||
import 'quill/dist/quill.bubble.css' // for bubble theme
|
import 'quill/dist/quill.bubble.css' // for bubble theme
|
||||||
import timeline from 'element-ui/lib/timeline'
|
import timeline from 'element-ui/lib/timeline'
|
||||||
import timelineItem from 'element-ui/lib/timeline-item'
|
import timelineItem from 'element-ui/lib/timeline-item'
|
||||||
// 进度条
|
|
||||||
import NProgres from 'nprogress'
|
|
||||||
import 'nprogress/nprogress.css'
|
|
||||||
|
|
||||||
Vue.use(timeline)
|
Vue.use(timeline)
|
||||||
Vue.use(timelineItem)
|
Vue.use(timelineItem)
|
||||||
Vue.use(vueQuillEditor)
|
Vue.use(vueQuillEditor)
|
||||||
Vue.component('table-tree', tableTree)
|
Vue.component('table-tree', tableTree)
|
||||||
axios.defaults.baseURL = 'http://127.0.0.1:8888/api/private/v1/'
|
axios.defaults.baseURL = 'http://127.0.0.1:8888/api/private/v1/'
|
||||||
// 为每个ajax请求头挂一个 token 并加载进度条
|
// 为每个请求头挂一个 token
|
||||||
axios.interceptors.request.use(config => {
|
axios.interceptors.request.use(config => {
|
||||||
NProgres.start()
|
|
||||||
config.headers.Authorization = sessionStorage.getItem('token')
|
config.headers.Authorization = sessionStorage.getItem('token')
|
||||||
return config
|
return config
|
||||||
})
|
})
|
||||||
axios.interceptors.response.use(response => {
|
|
||||||
NProgres.done()
|
|
||||||
return response
|
|
||||||
})
|
|
||||||
|
|
||||||
Vue.filter('dataFormat', (time) => {
|
Vue.filter('dataFormat', (time) => {
|
||||||
const dt = (new Date(time))
|
const dt = (new Date(time))
|
||||||
|
|
10
yarn.lock
10
yarn.lock
|
@ -1695,11 +1695,6 @@ babel-plugin-dynamic-import-node@^2.3.3:
|
||||||
dependencies:
|
dependencies:
|
||||||
object.assign "^4.1.0"
|
object.assign "^4.1.0"
|
||||||
|
|
||||||
babel-plugin-transform-remove-console@^6.9.4:
|
|
||||||
version "6.9.4"
|
|
||||||
resolved "https://registry.npm.taobao.org/babel-plugin-transform-remove-console/download/babel-plugin-transform-remove-console-6.9.4.tgz#b980360c067384e24b357a588d807d3c83527780"
|
|
||||||
integrity sha1-uYA2DAZzhOJLNXpYjYB9PINSd4A=
|
|
||||||
|
|
||||||
babel-runtime@6.x:
|
babel-runtime@6.x:
|
||||||
version "6.26.0"
|
version "6.26.0"
|
||||||
resolved "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe"
|
resolved "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe"
|
||||||
|
@ -5743,11 +5738,6 @@ npm-run-path@^4.0.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
path-key "^3.0.0"
|
path-key "^3.0.0"
|
||||||
|
|
||||||
nprogress@^0.2.0:
|
|
||||||
version "0.2.0"
|
|
||||||
resolved "https://registry.npm.taobao.org/nprogress/download/nprogress-0.2.0.tgz#cb8f34c53213d895723fcbab907e9422adbcafb1"
|
|
||||||
integrity sha1-y480xTIT2JVyP8urkH6UIq28r7E=
|
|
||||||
|
|
||||||
nth-check@^1.0.2, nth-check@~1.0.1:
|
nth-check@^1.0.2, nth-check@~1.0.1:
|
||||||
version "1.0.2"
|
version "1.0.2"
|
||||||
resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.2.tgz#b2bd295c37e3dd58a3bf0700376663ba4d9cf05c"
|
resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.2.tgz#b2bd295c37e3dd58a3bf0700376663ba4d9cf05c"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user