From 4632b1429e3395cec0461db0a2ab5277fccb399c Mon Sep 17 00:00:00 2001 From: j1ack <1209452658@qq.com> Date: Fri, 5 Aug 2022 17:56:12 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=95=B4=E4=BD=93loading?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/companySummary/talent.vue | 9 ++++----- src/main.js | 4 ++-- src/views/Brand.vue | 6 +++++- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/src/components/companySummary/talent.vue b/src/components/companySummary/talent.vue index 8a67d9e..2bf9961 100644 --- a/src/components/companySummary/talent.vue +++ b/src/components/companySummary/talent.vue @@ -120,8 +120,8 @@ export default { let option = { title: { text: `总金额: ${this.chartData ? this.chartData.totalAmount || 0 : 0} 元`, - top: 20, - left: 200, + top: '12%', + left: '45%', textStyle: { //文字颜色 color: '#fff', @@ -129,10 +129,9 @@ export default { }, legend: { - right: 210, + right: '35%', orient: 'vertical', - top: 60, - bottom: 20, + top: '25%', data: legendData, icon: "circle", textStyle: { diff --git a/src/main.js b/src/main.js index 038859b..912ec86 100644 --- a/src/main.js +++ b/src/main.js @@ -14,10 +14,10 @@ import dayjs from 'dayjs' import '@/assets/styles/base.scss' import '@/assets/styles/common.scss' import '@/assets/iconfont/iconfont.css' - +import loadingViewerVue from 'loading-view-vue' +Vue.use(loadingViewerVue) Vue.use(vueParticles) Vue.use(Vcomp) - Vue.config.productionTip = false Vue.prototype.axios = axios Vue.prototype.dayjs = dayjs diff --git a/src/views/Brand.vue b/src/views/Brand.vue index 672dd7f..4e58ce2 100644 --- a/src/views/Brand.vue +++ b/src/views/Brand.vue @@ -141,7 +141,6 @@ import { BiApi } from "@/api/form"; import "@/assets/js/flexible"; import "@/assets/js/china"; import countTo from "vue-count-to"; - const paramsArr = window.location.href.split('?') let authCode = '' if (paramsArr.length > 1) { @@ -203,10 +202,15 @@ export default { }, mounted() { if (authCode && typeof +authCode === 'number') { + this.$showLoading(); this.heart(); setTimeout(() => { this.getEchart(); }, 800); + // loading + setTimeout(() => { + this.$hideLoading(); + }, 900); } else { // console.log('授权码为空', authCode); alert('授权码为空,请从系统调用页面!')