From 3c6bdb6f439ff7af04765259fd6a91b6d201d095 Mon Sep 17 00:00:00 2001 From: zxl <763096477@qq.com> Date: 星期四, 19 六月 2025 17:12:25 +0800 Subject: [PATCH] 工单,数据中心用户查看数据的权限,合同考核每日,以及导出每日和按月 --- src/main.js | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 56 insertions(+), 2 deletions(-) diff --git a/src/main.js b/src/main.js index a8d407c..2d9996d 100644 --- a/src/main.js +++ b/src/main.js @@ -1,10 +1,11 @@ import Vue from 'vue' import Cookies from 'js-cookie' -import {getToken} from "@/utils/auth"; +import { getToken } from "@/utils/auth"; import Element from 'element-ui' import './assets/styles/element-variables.scss' - +import * as echarts from 'echarts' +import 'echarts-gl' import '@/assets/styles/index.scss' // global css import '@/assets/styles/ruoyi.scss' // ruoyi css import App from './App' @@ -37,6 +38,15 @@ import VueMeta from 'vue-meta' // 瀛楀吀鏁版嵁缁勪欢 import DictData from '@/components/DictData' +import VueAnimateNumber from 'vue-animate-number' +// 澶у睆 +import VScaleScreen from 'v-scale-screen' +import dataV from '@jiaminghi/data-view' + +import gsap from 'gsap'; +import { formatNumber } from './utils/format'; + + // 鍏ㄥ眬鏂规硶鎸傝浇 Vue.prototype.getDicts = getDicts @@ -49,6 +59,9 @@ Vue.prototype.download = download Vue.prototype.handleTree = handleTree Vue.prototype.getToken = getToken +Vue.prototype.$uploadUrl = process.env.VUE_APP_BASE_API + "/common/upload" +Vue.prototype.$img = process.env.VUE_APP_BASE_API +Vue.prototype.$echarts = echarts // 鍏ㄥ眬缁勪欢鎸傝浇 Vue.component('DictTag', DictTag) @@ -62,7 +75,13 @@ Vue.use(directive) Vue.use(plugins) Vue.use(VueMeta) +Vue.use(VScaleScreen) +Vue.use(dataV) +Vue.use(VueAnimateNumber) DictData.install() + +// websocket +Vue.prototype.$websocket = null; /** * If you don't want to use mock-server @@ -79,6 +98,41 @@ Vue.config.productionTip = true + +// 鍏ㄥ眬鎸囦护 +Vue.directive('roll', { + inserted: (el, binding) => { + let target = { + count: 0 + }; + let finalNumber = el.innerText; + gsap.to(target, { + count: finalNumber, + duration: 1, + ease: "power2.out", + onUpdate: () => { + // el.innerText = formatNumber(target.count.toFixed(0)); + } + }) + + }, + update: (el, binding) => { + let target = { + count: el.innerText + }; + let finalNumber = el.getAttribute('value'); + gsap.to(target, { + count: finalNumber, + duration: 1, + ease: "power2.out", + onUpdate: () => { + // el.innerText = formatNumber(target.count.toFixed(0)); + } + }) + } +}) + + new Vue({ el: '#app', router, -- Gitblit v1.8.0