From 297fc2b1dc68809571efbec3ad3686b0025ad851 Mon Sep 17 00:00:00 2001 From: "[liang]" <[595996918@qq.com]> Date: Mon, 8 Aug 2022 18:23:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=B8=8D=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/request.js | 5 +++-- src/components/companySummary/talent.vue | 19 ++++++++++--------- src/components/scrollArc/index.vue | 7 +++++-- src/components/szBar/index.vue | 12 ++++++++---- src/views/Brand.vue | 2 +- 5 files changed, 27 insertions(+), 18 deletions(-) diff --git a/src/api/request.js b/src/api/request.js index ab585e1..8a358f0 100644 --- a/src/api/request.js +++ b/src/api/request.js @@ -7,9 +7,10 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8' // 创建axios实例 const service = axios.create({ // axios中请求配置有baseURL选项,表示请求URL公共部分 - baseURL: 'http://192.168.31.128:8866', + // baseURL: 'http://192.168.31.128:8866', + baseURL: 'http://parking.weirui0755.com/prod-api', // 超时 - timeout: 15000 + timeout: 30000 }) // request拦截器 service.interceptors.request.use(config => { diff --git a/src/components/companySummary/talent.vue b/src/components/companySummary/talent.vue index 71c7b73..66b980b 100644 --- a/src/components/companySummary/talent.vue +++ b/src/components/companySummary/talent.vue @@ -77,6 +77,7 @@ export default { return parseInt(Math.round(Number((num / sum) * 100))); }, getEchartLeft2() { + // eslint-disable-next-line no-undef let myChart = echarts.init(document.getElementById('chart_left2')); let scaleData = [{ name: '支付宝支付', @@ -133,16 +134,16 @@ export default { // console.log(legendData) let option = { - title: { - text: `总金额: ${this.chartData ? this.chartData.totalAmount || 0 : 0} 元`, - top: '12%', - left: '45%', - textStyle: { - //文字颜色 - color: '#fff', - } + // title: { + // text: `总金额: ${this.chartData ? this.chartData.totalAmount || 0 : 0} 元`, + // top: '12%', + // left: '45%', + // textStyle: { + // //文字颜色 + // color: '#fff', + // } - }, + // }, legend: { right: '35%', orient: 'vertical', diff --git a/src/components/scrollArc/index.vue b/src/components/scrollArc/index.vue index a2c309f..ecd247d 100644 --- a/src/components/scrollArc/index.vue +++ b/src/components/scrollArc/index.vue @@ -59,13 +59,14 @@ export default { this.xData=[] this.dataIn=[] this.dataOut=[] - for (var i = 0; i < this.chartData.inStatistics.length; i++) { + for (let i = 0; i < this.chartData.inStatistics.length; i++) { this.xData.push(this.chartData.inStatistics[i].timeUnit) this.dataIn.push(this.chartData.inStatistics[i].num) } - for (var i = 0; i < this.chartData.outStatistics.length; i++) { + for (let i = 0; i < this.chartData.outStatistics.length; i++) { this.dataOut.push(this.chartData.outStatistics[i].num) } + // eslint-disable-next-line no-undef let myChart = echarts.init(document.getElementById('chart_arc')); this.option = { tooltip: { @@ -75,6 +76,7 @@ export default { axisPointer: { type: 'shadow', shadowStyle: { + // eslint-disable-next-line no-undef color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{ offset: 1, color: '#5d83ff' @@ -174,6 +176,7 @@ export default { }, areaStyle: { normal: { + // eslint-disable-next-line no-undef color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{ offset: 0, color: '#1BDB7F' diff --git a/src/components/szBar/index.vue b/src/components/szBar/index.vue index fcbb9dc..197aa2f 100644 --- a/src/components/szBar/index.vue +++ b/src/components/szBar/index.vue @@ -41,16 +41,20 @@ export default { mounted() { setTimeout(() => { // console.log(this.chartData) - for (var i = 0; i < this.chartData.inStatistics.length; i++) { - this.xAxisData.push(this.chartData.inStatistics[i].timeUnit) - this.yData1.push(this.chartData.inStatistics[i].num) - } + this.getEchart(); }, 800); }, methods: { getEchart() { + this.xAxisData=[]; + this.yData1=[]; + for (var i = 0; i < this.chartData.inStatistics.length; i++) { + this.xAxisData.push(this.chartData.inStatistics[i].timeUnit) + this.yData1.push(this.chartData.inStatistics[i].num) + } + // eslint-disable-next-line no-undef let myChart = echarts.init(document.getElementById('chart_bar')); let barWidth = '15%'; let dataCoord = [ diff --git a/src/views/Brand.vue b/src/views/Brand.vue index fee569a..68b0c18 100644 --- a/src/views/Brand.vue +++ b/src/views/Brand.vue @@ -923,7 +923,7 @@ export default { .mainbox { min-width: 1366px; - max-width: 1920px; + // max-width: 1920px; padding: 0.125rem 0.125rem 0; display: flex;