16 Commits

Author SHA1 Message Date
guanj
54f336ab45 修改现场问题 2026-05-21 09:37:58 +08:00
39093641d8 用能系统功能调整 2025-07-24 11:40:23 +08:00
guanj
c88484caf7 修改现场问题 2025-07-16 18:10:24 +08:00
GGJ
bb7eb039b5 修改 监测指标数据质量统计字段名称 2025-04-21 13:33:40 +08:00
GGJ
b317bf9c7d Merge branch 'master' of http://192.168.1.22:3000/root/HB_PMS3.0_WEB 2025-04-18 15:15:09 +08:00
GGJ
0a521bdcb7 配置超高压生产嵌入系统 2025-04-18 15:15:00 +08:00
263cd764f3 1.主网台账修改 2025-03-21 16:20:25 +08:00
a04bb33206 1.主配网测点数据重算功能bug
2.监督计划新增校验
2025-03-21 08:58:54 +08:00
GGJ
f4a22dbed1 联调cvt执行算法页面 2025-03-11 15:29:31 +08:00
GGJ
566949569a Merge branch 'master' of http://192.168.1.22:3000/root/HB_PMS3.0_WEB 2025-03-10 11:29:55 +08:00
GGJ
52a0b67f96 联调cvt执行算法 修改测试bug 2025-03-10 11:29:46 +08:00
cdf
50573bb748 验收问题修改 2025-03-10 09:13:12 +08:00
cdf
15e1be00af 问题修改 2025-03-06 16:57:05 +08:00
cdf
4233317f5d 问题修改 2025-03-06 16:50:07 +08:00
cdf
452e0f3dbb 问题修改 2025-03-06 14:44:33 +08:00
GGJ
72051ba10e 联调cvt系数页面与cvt绑定 2025-02-12 14:00:11 +08:00
84 changed files with 55915 additions and 33205 deletions

20941
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,166 +1,168 @@
{
"name": "vue-pc-admin",
"version": "0.1.0",
"description": "这是一个基于 vue admin 管理后台",
"author": "caojinwei",
"license": "NJCN",
"scripts": {
"dev": "vue-cli-service serve",
"dev-zoom": "cross-env VUE_APP_ZOOM=1 vue-cli-service serve",
"dev-cgyqr": "cross-env VUE_APP_MODE=cgyqr vue-cli-service serve",
"dev-hbqr": "cross-env VUE_APP_MODE=cgyqr VUE_APP_HB=hbqr vue-cli-service serve",
"dev-jbqr": "cross-env VUE_APP_MODE=jbqr vue-cli-service serve",
"build": "vue-cli-service build",
"build-zoom": "cross-env VUE_APP_ZOOM=1 vue-cli-service build",
"build-hbqr": "cross-env VUE_APP_MODE=cgyqr VUE_APP_HB=hbqr vue-cli-service build",
"build-cgyqr": "cross-env VUE_APP_MODE=cgyqr vue-cli-service build",
"build-jbqr": "cross-env VUE_APP_MODE=jbqr vue-cli-service build",
"preview": "node build/index.js --preview",
"deploy-18": "cross-env VUE_APP_ZOOM=1 vue-cli-service build && ./upload_script/upload_18.sh"
},
"dependencies": {
"@ckeditor/ckeditor5-vue": "^1.0.1",
"@jiaminghi/data-view": "^2.10.0",
"@riophae/vue-treeselect": "^0.4.0",
"@toast-ui/editor": "^2.0.1",
"@toast-ui/vue-editor": "^2.0.1",
"@vue/composition-api": "^1.3.0",
"@wangeditor/editor": "^5.1.23",
"@wangeditor/editor-for-vue": "^1.0.2",
"axios": "^0.27.2",
"baidu-map": "^0.1.4",
"bpmn-js": "^11.1.0",
"bpmn-js-bpmnlint": "^0.15.0",
"bpmnlint": "^6.4.0",
"bpmnlint-loader": "^0.1.4",
"codemirror": "5.39.2",
"core-js": "^2.6.12",
"cross-storage": "^1.0.0",
"crypto-js": "^4.2.0",
"deepmerge": "^4.2.2",
"driver.js": "^0.9.8",
"echarts": "^5.4.3",
"echarts-gl": "^2.0.9",
"echarts-liquidfill": "^3.1.0",
"el-tree-transfer": "^2.4.7",
"element-resize-detector": "^1.2.4",
"element-ui": "^2.15.9",
"exceljs": "^4.3.0",
"fabric": "^5.3.0",
"file-saver": "^2.0.5",
"form-gen-parser": "^1.0.3",
"highcharts": "^10.0.0",
"highcharts-vue": "^1.4.0",
"html2canvas": "^1.4.1",
"jquery": "^3.6.0",
"jquery.panzoom": "^3.2.3",
"js-cookie": "2.2.0",
"json2csv": "^5.0.6",
"less": "^4.1.2",
"less-loader": "^5.0.0",
"lib-flexible": "^0.3.2",
"lodash.clonedeep": "^4.5.0",
"luckyexcel": "^1.0.1",
"mqtt": "^4.3.6",
"normalize.css": "7.0.0",
"nprogress": "0.2.0",
"path-to-regexp": "2.4.0",
"qiniu-js": "^3.1.2",
"qrcodejs2": "^0.0.2",
"sanitizer": "^0.1.3",
"screenfull": "^5.0.2",
"session-storage-sync": "^0.6.0",
"sortablejs": "^1.10.2",
"spin.js": "^4.1.1",
"sync-session-storage": "^0.0.13",
"throttle-debounce": "^1.1.0",
"timeline-slider-vue": "^1.0.6",
"umy-ui": "^1.1.6",
"v-loading-plugin": "^1.0.7",
"vue": "2.6.10",
"vue-baidu-map": "^0.21.22",
"vue-drag-resize": "^1.5.4",
"vue-echarts": "^6.6.2",
"vue-grid-layout": "^2.3.12",
"vue-jsonp": "^2.0.0",
"vue-masonry": "^0.16.0",
"vue-particles": "^1.0.9",
"vue-resize-observer": "^2.0.16",
"vue-router": "3.0.6",
"vue-slider-component": "^3.2.24",
"vue-svg-filler": "^1.0.6",
"vuedraggable": "^2.24.3",
"vuex": "3.1.0",
"vxe-table": "3.6.6",
"vxe-table-plugin-export-xlsx": "2.2.2",
"webpack-theme-color-replacer": "^1.3.7",
"xe-utils": "^3.5.14",
"xlsx": "^0.15.6"
},
"devDependencies": {
"@babel/core": "7.0.0",
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
"@babel/plugin-transform-modules-commonjs": "^7.9.0",
"@babel/register": "7.0.0",
"@vue/cli-plugin-babel": "3.6.0",
"@vue/cli-service": "^3.12.1",
"@vue/test-utils": "1.0.0-beta.29",
"autoprefixer": "^9.5.1",
"babel-core": "7.0.0-bridge.0",
"babel-plugin-transform-es2015-modules-commonjs": "^6.26.2",
"babel-plugin-transform-remove-console": "^6.9.4",
"chalk": "2.4.2",
"compression-webpack-plugin": "^3.1.0",
"connect": "3.6.6",
"cross-env": "^7.0.3",
"css-properties-sorting": "^1.0.10",
"d3": "^7.1.1",
"default-passive-events": "^2.0.0",
"highlight.js": "9.18.5",
"html-webpack-plugin": "3.2.0",
"less": "^4.1.1",
"less-loader": "^5.0.0",
"lint-staged": "8.1.5",
"open": "^7.0.3",
"postcss-loader": "^3.0.0",
"px2rem-loader": "^0.1.9",
"raw-loader": "^0.5.1",
"runjs": "^4.3.2",
"sass": "^1.62.0",
"sass-loader": "^7.1.0",
"sass-resources-loader": "^2.0.3",
"script-ext-html-webpack-plugin": "2.1.3",
"script-loader": "0.7.2",
"serve-static": "^1.13.2",
"stylelint": "^12.0.1",
"stylelint-config-standard": "^20.0.0",
"stylelint-order": "^4.1.0",
"stylelint-scss": "^3.18.0",
"svg-sprite-loader": "4.1.3",
"svgo": "1.2.2",
"vkbeautify": "^0.99.3",
"vue-particles": "^1.0.9",
"vue-template-compiler": "2.6.10",
"vue2-ace-editor": "^0.0.15",
"xcrud": "^0.4.19"
},
"lint-staged": {
"src/**/*.{js,vue}": [
"git add"
],
"src/**/*.{html,vue,css,sass,scss}": [
"stylelint --fix",
"git add"
"name": "vue-pc-admin",
"version": "0.1.0",
"description": "这是一个基于 vue admin 管理后台",
"author": "caojinwei",
"license": "NJCN",
"scripts": {
"dev": "vue-cli-service serve",
"dev-zoom": "cross-env VUE_APP_ZOOM=1 vue-cli-service serve",
"dev-cgyqr": "cross-env VUE_APP_MODE=cgyqr vue-cli-service serve",
"dev-cgyqr1": "cross-env VUE_APP_MODE=cgyqr VUE_APP_KEY=scqr vue-cli-service serve",
"dev-hbqr": "cross-env VUE_APP_MODE=cgyqr VUE_APP_HB=hbqr VUE_APP_KEY=scqr vue-cli-service serve",
"dev-jbqr": "cross-env VUE_APP_MODE=jbqr vue-cli-service serve",
"build": "vue-cli-service build",
"build-zoom": "cross-env VUE_APP_ZOOM=1 vue-cli-service build",
"build-hbqr": "cross-env VUE_APP_MODE=cgyqr VUE_APP_HB=hbqr VUE_APP_KEY=scqr vue-cli-service build",
"build-cgyqr": "cross-env VUE_APP_MODE=cgyqr vue-cli-service build",
"build-cgyqr1": "cross-env VUE_APP_MODE=cgyqr VUE_APP_KEY=scqr vue-cli-service build",
"build-jbqr": "cross-env VUE_APP_MODE=jbqr vue-cli-service build",
"preview": "node build/index.js --preview",
"deploy-18": "cross-env VUE_APP_ZOOM=1 vue-cli-service build && ./upload_script/upload_18.sh"
},
"dependencies": {
"@ckeditor/ckeditor5-vue": "^1.0.1",
"@jiaminghi/data-view": "^2.10.0",
"@riophae/vue-treeselect": "^0.4.0",
"@toast-ui/editor": "^2.0.1",
"@toast-ui/vue-editor": "^2.0.1",
"@vue/composition-api": "^1.3.0",
"@wangeditor/editor": "^5.1.23",
"@wangeditor/editor-for-vue": "^1.0.2",
"axios": "^0.27.2",
"baidu-map": "^0.1.4",
"bpmn-js": "^11.1.0",
"bpmn-js-bpmnlint": "^0.15.0",
"bpmnlint": "^6.4.0",
"bpmnlint-loader": "^0.1.4",
"codemirror": "5.39.2",
"core-js": "^2.6.12",
"cross-storage": "^1.0.0",
"crypto-js": "^4.2.0",
"deepmerge": "^4.2.2",
"driver.js": "^0.9.8",
"echarts": "^5.4.3",
"echarts-gl": "^2.0.9",
"echarts-liquidfill": "^3.1.0",
"el-tree-transfer": "^2.4.7",
"element-resize-detector": "^1.2.4",
"element-ui": "^2.15.9",
"exceljs": "^4.3.0",
"fabric": "^5.3.0",
"file-saver": "^2.0.5",
"form-gen-parser": "^1.0.3",
"highcharts": "^10.0.0",
"highcharts-vue": "^1.4.0",
"html2canvas": "^1.4.1",
"jquery": "^3.6.0",
"jquery.panzoom": "^3.2.3",
"js-cookie": "2.2.0",
"json2csv": "^5.0.6",
"less": "^4.1.2",
"less-loader": "^5.0.0",
"lib-flexible": "^0.3.2",
"lodash.clonedeep": "^4.5.0",
"luckyexcel": "^1.0.1",
"mqtt": "^4.3.6",
"normalize.css": "7.0.0",
"nprogress": "0.2.0",
"path-to-regexp": "2.4.0",
"qiniu-js": "^3.1.2",
"qrcodejs2": "^0.0.2",
"sanitizer": "^0.1.3",
"screenfull": "^5.0.2",
"session-storage-sync": "^0.6.0",
"sortablejs": "^1.10.2",
"spin.js": "^4.1.1",
"sync-session-storage": "^0.0.13",
"throttle-debounce": "^1.1.0",
"timeline-slider-vue": "^1.0.6",
"umy-ui": "^1.1.6",
"v-loading-plugin": "^1.0.7",
"vue": "2.6.10",
"vue-baidu-map": "^0.21.22",
"vue-drag-resize": "^1.5.4",
"vue-echarts": "^6.6.2",
"vue-grid-layout": "^2.3.12",
"vue-jsonp": "^2.0.0",
"vue-masonry": "^0.16.0",
"vue-particles": "^1.0.9",
"vue-resize-observer": "^2.0.16",
"vue-router": "3.0.6",
"vue-slider-component": "^3.2.24",
"vue-svg-filler": "^1.0.6",
"vuedraggable": "^2.24.3",
"vuex": "3.1.0",
"vxe-table": "3.6.6",
"vxe-table-plugin-export-xlsx": "2.2.2",
"webpack-theme-color-replacer": "^1.3.7",
"xe-utils": "^3.5.14",
"xlsx": "^0.15.6"
},
"devDependencies": {
"@babel/core": "7.0.0",
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
"@babel/plugin-transform-modules-commonjs": "^7.9.0",
"@babel/register": "7.0.0",
"@vue/cli-plugin-babel": "3.6.0",
"@vue/cli-service": "^3.12.1",
"@vue/test-utils": "1.0.0-beta.29",
"autoprefixer": "^9.5.1",
"babel-core": "7.0.0-bridge.0",
"babel-plugin-transform-es2015-modules-commonjs": "^6.26.2",
"babel-plugin-transform-remove-console": "^6.9.4",
"chalk": "2.4.2",
"compression-webpack-plugin": "^3.1.0",
"connect": "3.6.6",
"cross-env": "^7.0.3",
"css-properties-sorting": "^1.0.10",
"d3": "^7.1.1",
"default-passive-events": "^2.0.0",
"highlight.js": "9.18.5",
"html-webpack-plugin": "3.2.0",
"less": "^4.1.1",
"less-loader": "^5.0.0",
"lint-staged": "8.1.5",
"open": "^7.0.3",
"postcss-loader": "^3.0.0",
"px2rem-loader": "^0.1.9",
"raw-loader": "^0.5.1",
"runjs": "^4.3.2",
"sass": "^1.62.0",
"sass-loader": "^7.1.0",
"sass-resources-loader": "^2.0.3",
"script-ext-html-webpack-plugin": "2.1.3",
"script-loader": "0.7.2",
"serve-static": "^1.13.2",
"stylelint": "^12.0.1",
"stylelint-config-standard": "^20.0.0",
"stylelint-order": "^4.1.0",
"stylelint-scss": "^3.18.0",
"svg-sprite-loader": "4.1.3",
"svgo": "1.2.2",
"vkbeautify": "^0.99.3",
"vue-particles": "^1.0.9",
"vue-template-compiler": "2.6.10",
"vue2-ace-editor": "^0.0.15",
"xcrud": "^0.4.19"
},
"lint-staged": {
"src/**/*.{js,vue}": [
"git add"
],
"src/**/*.{html,vue,css,sass,scss}": [
"stylelint --fix",
"git add"
]
},
"engines": {
"node": ">=8.9",
"npm": ">= 3.0.0"
},
"browserslist": [
"> 1%",
"last 2 versions",
"not ie <= 11"
]
},
"engines": {
"node": ">=8.9",
"npm": ">= 3.0.0"
},
"browserslist": [
"> 1%",
"last 2 versions",
"not ie <= 11"
]
}

View File

@@ -1,273 +1,278 @@
<template>
<div ref="appheight" id="app" class="zindx" :class="themeName">
<router-view />
</div>
</template>
<script>
import { mapActions } from 'vuex'
import { getThemeColor } from '@/api/user'
import { themeColor } from './settings'
import '@/assets/font_3482754_22duxhlb6kw/iconfont'
export default {
name: 'app',
components: {},
data() {
return {
lastTime: null, //最后一次点击的时间
currentTime: null, //当前点击的时间
timeOut: 15 * 60 * 1000, //设置超时时间: 15分钟,
themecolor: '',
appheight: null,
appwidth: null,
themeName: '',
echartTimer: null
}
},
computed: {
settings() {
return this.$store.state.settings
}
},
created() {
if (process.env.VUE_APP_MODE === 'jbqr') {
window.addEventListener('message', function (e) {
if (e.data.info != undefined) {
window.localStorage.setItem('adminInfo', e.data.info)
}
// window.localStorage.setItem('adminInfo', e.data)
})
}
let DOMIN = window.location.origin
let STATIC_URL = DOMIN + '/api/system-boot/image/toStream?bgImage='
localStorage.setItem('STATIC_URL', STATIC_URL)
this.lastTime = new Date().getTime() //网页第一次打开时,记录当前时间
this.gettheme()
window.echartsArr = []
//定时清理
setInterval(() => {
if (window.echartsArr.length > 10) {
window.echartsArr.splice(0, window.echartsArr.length - 10)
}
}, 10000)
},
mounted() {
// 处理笔记本系统默认系统比例为150%带来的布局影响
if (process.env.VUE_APP_ZOOM) {
const m = this.detectZoom()
document.body.style.zoom = 100 / Number(m)
}
setTimeout(() => {
this.appwidth = document.body.offsetWidth - 205
this.appheight = document.body.offsetHeight - 105
window.sessionStorage.setItem('appwidth', this.appwidth)
window.sessionStorage.setItem('appheight', this.appheight)
if (process.env.VUE_APP_MODE === 'jbqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}else if(process.env.VUE_APP_MODE === 'cgyqr'){
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}
}, 100)
let timer = null
window.addEventListener('resize', () => {
// if (timer) {
// clearTimeout(timer)
// }
// timer = setTimeout(() => {
console.log('窗口变化')
this.appwidth = document.body.offsetWidth - 205
this.appheight = document.body.offsetHeight - 105
window.sessionStorage.setItem('appwidth', this.appwidth)
window.sessionStorage.setItem('appheight', this.appheight)
if (process.env.VUE_APP_MODE === 'jbqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}else if(process.env.VUE_APP_MODE === 'cgyqr'){
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}
// }, 100)
})
window.addEventListener('beforeunload', e => this.beforeunloadHandler(e))
window.addEventListener('unload', e => this.unloadHandler(e))
window.addEventListener('resize', this.handleResizeEcharts)
},
// destroyed() {
// window.removeEventListener('beforeunload', e => this.beforeunloadHandler(e))
// window.removeEventListener('unload', e => this.unloadHandler(e))
// window.removeEventListener('resize', this.handleResizeEcharts)
// },
methods: {
...mapActions({
changeSetting: 'settings/changeSetting'
}),
handleResizeEcharts() {
// 防抖
if (this.echartTimer) {
clearTimeout(this.echartTimer)
}
this.echartTimer = setTimeout(() => {
this.echartTimer = null
window.echartsArr.forEach(item => {
item.resize()
})
}, 200)
},
gettheme() {
//主题接口
getThemeColor().then(response => {
const data = response.data
var themecolor = data.color
var logoUrl = data.logoUrl
window.sessionStorage.setItem('logo', logoUrl)
var title = data.name
this.changeSetting({ themeColor: themecolor })
this.changeSetting({ logoUrl: logoUrl })
this.changeSetting({ title: title })
// // 深蓝色主题
let echartsColor = {}
if (data.color == '#044267') {
require.ensure([], function (require) {
require('../src/styles/element-uitwo.scss')
})
this.themeName = 'element-uitwo'
echartsColor = {
WordColor: '#fff',
thread: '#0379A0',
FigureColor: [
'#00CCFF',
'#FF9933',
'#41E398',
'#0192CD',
'#00FFFF',
'#FAC800',
'#12AFA6',
'#FF680B ',
'#FF0000 ',
'#07CCCA '
]
}
} else if (data.color == '#065252') {
// // 深绿色
require.ensure([], function (require) {
require('../src/styles/element-uione.scss')
})
this.themeName = 'element-uione'
echartsColor = {
WordColor: '#fff',
thread: '#268080',
FigureColor: [
'#01DFA3 ',
'#FAC800',
'#00CCFF',
'#00FFFF',
'#FF680B',
'#00FF00',
'#D5FF6B ',
'#FF9933 ',
'#5B6E96 ',
'#66FFCC '
]
}
} else if (data.color == '#4AB5A5') {
// // 浅色调
require.ensure([], function (require) {
require('../src/styles/element-uithree.scss')
})
this.themeName = 'element-uithree'
echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3'
]
}
} else {
//普通
require.ensure([], function (require) {
require('../src/styles/element-uiforth.scss')
})
this.themeName = 'element-uiforth'
echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3',
'#FF00FF',
'#CC00FF',
'#FF9999'
]
}
}
window.localStorage.setItem('echartsColor', JSON.stringify(echartsColor))
})
},
beforeunloadHandler() {
this._beforeUnload_time = new Date().getTime()
// var storage = window.localStorage;
// storage.clear()
},
unloadHandler(e) {
this._gap_time = new Date().getTime() - this._beforeUnload_time
// // debugger
// // 判断是窗口关闭还是刷新
// if (this._gap_time <= 5) {
// var storage = window.localStorage
// storage.clear()
// }
},
detectZoom() {
let ratio = 0,
screen = window.screen,
ua = navigator.userAgent.toLowerCase()
if (window.devicePixelRatio !== undefined) {
ratio = window.devicePixelRatio
} else if (~ua.indexOf('msie')) {
if (screen.deviceXDPI && screen.logicalXDPI) {
ratio = screen.deviceXDPI / screen.logicalXDPI
}
} else if (window.outerWidth !== undefined && window.innerWidth !== undefined) {
ratio = window.outerWidth / window.innerWidth
}
if (ratio) {
ratio = Math.round(ratio * 100)
}
return ratio
}
}
}
</script>
<style>
.zindx {
min-width: 1200px;
}
body .el-table th.gutter {
display: table-cell !important;
}
.plTableBox.el-table__header,
.el-table__body,
.el-table__footer {
width: 100% !important;
table-layout: fixed !important;
}
</style>
<template>
<div ref="appheight" id="app" class="zindx" :class="themeName">
<router-view />
</div>
</template>
<script>
import { mapActions } from 'vuex'
import { getThemeColor } from '@/api/user'
import { themeColor } from './settings'
import '@/assets/font_3482754_22duxhlb6kw/iconfont'
export default {
name: 'app',
components: {},
data() {
return {
lastTime: null, //最后一次点击的时间
currentTime: null, //当前点击的时间
timeOut: 15 * 60 * 1000, //设置超时时间: 15分钟,
themecolor: '',
appheight: null,
appwidth: null,
themeName: '',
echartTimer: null
}
},
computed: {
settings() {
return this.$store.state.settings
}
},
created() {
if (process.env.VUE_APP_MODE === 'jbqr') {
window.addEventListener('message', function (e) {
if (e.data.info != undefined) {
window.localStorage.setItem('adminInfo', e.data.info)
}
// window.localStorage.setItem('adminInfo', e.data)
})
}
let DOMIN = window.location.origin
let STATIC_URL = DOMIN + '/api/system-boot/image/toStream?bgImage='
localStorage.setItem('STATIC_URL', STATIC_URL)
this.lastTime = new Date().getTime() //网页第一次打开时,记录当前时间
this.gettheme()
window.echartsArr = []
//定时清理
setInterval(() => {
if (window.echartsArr.length > 10) {
window.echartsArr.splice(0, window.echartsArr.length - 10)
}
}, 10000)
},
async mounted() {
// 处理笔记本系统默认系统比例为150%带来的布局影响
if (process.env.VUE_APP_ZOOM) {
const m = this.detectZoom()
document.body.style.zoom = 100 / Number(m)
}
setTimeout(() => {
this.appwidth = document.body.offsetWidth - 205
this.appheight = document.body.offsetHeight - 105
window.sessionStorage.setItem('appwidth', this.appwidth)
window.sessionStorage.setItem('appheight', this.appheight)
if (process.env.VUE_APP_MODE === 'jbqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
} else if (process.env.VUE_APP_MODE === 'cgyqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}
}, 100)
let timer = null
window.addEventListener('resize', () => {
// if (timer) {
// clearTimeout(timer)
// }
// timer = setTimeout(() => {
console.log('窗口变化')
this.appwidth = document.body.offsetWidth - 205
this.appheight = document.body.offsetHeight - 105
window.sessionStorage.setItem('appwidth', this.appwidth)
window.sessionStorage.setItem('appheight', this.appheight)
if (process.env.VUE_APP_MODE === 'jbqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
} else if (process.env.VUE_APP_MODE === 'cgyqr') {
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
}
// }, 100)
})
window.addEventListener('beforeunload', e => this.beforeunloadHandler(e))
window.addEventListener('unload', e => this.unloadHandler(e))
window.addEventListener('resize', this.handleResizeEcharts)
let response = await fetch('/')
let MqttUrl = response.headers.get('X-Mqtt-Url')
console.log("🚀 ~ mounted ~ MqttUrl:", MqttUrl)
localStorage.setItem('MqttUrl', MqttUrl)
},
// destroyed() {
// window.removeEventListener('beforeunload', e => this.beforeunloadHandler(e))
// window.removeEventListener('unload', e => this.unloadHandler(e))
// window.removeEventListener('resize', this.handleResizeEcharts)
// },
methods: {
...mapActions({
changeSetting: 'settings/changeSetting'
}),
handleResizeEcharts() {
// 防抖
if (this.echartTimer) {
clearTimeout(this.echartTimer)
}
this.echartTimer = setTimeout(() => {
this.echartTimer = null
window.echartsArr.forEach(item => {
item.resize()
})
}, 200)
},
gettheme() {
//主题接口
getThemeColor().then(response => {
const data = response.data
var themecolor = data.color
var logoUrl = data.logoUrl
window.sessionStorage.setItem('logo', logoUrl)
var title = data.name
this.changeSetting({ themeColor: themecolor })
this.changeSetting({ logoUrl: logoUrl })
this.changeSetting({ title: title })
// // 深蓝色主题
let echartsColor = {}
if (data.color == '#044267') {
require.ensure([], function (require) {
require('../src/styles/element-uitwo.scss')
})
this.themeName = 'element-uitwo'
echartsColor = {
WordColor: '#fff',
thread: '#0379A0',
FigureColor: [
'#00CCFF',
'#FF9933',
'#41E398',
'#0192CD',
'#00FFFF',
'#FAC800',
'#12AFA6',
'#FF680B ',
'#FF0000 ',
'#07CCCA '
]
}
} else if (data.color == '#065252') {
// // 深绿色
require.ensure([], function (require) {
require('../src/styles/element-uione.scss')
})
this.themeName = 'element-uione'
echartsColor = {
WordColor: '#fff',
thread: '#268080',
FigureColor: [
'#01DFA3 ',
'#FAC800',
'#00CCFF',
'#00FFFF',
'#FF680B',
'#00FF00',
'#D5FF6B ',
'#FF9933 ',
'#5B6E96 ',
'#66FFCC '
]
}
} else if (data.color == '#4AB5A5') {
// // 浅色调
require.ensure([], function (require) {
require('../src/styles/element-uithree.scss')
})
this.themeName = 'element-uithree'
echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3'
]
}
} else {
//普通
require.ensure([], function (require) {
require('../src/styles/element-uiforth.scss')
})
this.themeName = 'element-uiforth'
echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3',
'#FF00FF',
'#CC00FF',
'#FF9999'
]
}
}
window.localStorage.setItem('echartsColor', JSON.stringify(echartsColor))
})
},
beforeunloadHandler() {
this._beforeUnload_time = new Date().getTime()
// var storage = window.localStorage;
// storage.clear()
},
unloadHandler(e) {
this._gap_time = new Date().getTime() - this._beforeUnload_time
// // debugger
// // 判断是窗口关闭还是刷新
// if (this._gap_time <= 5) {
// var storage = window.localStorage
// storage.clear()
// }
},
detectZoom() {
let ratio = 0,
screen = window.screen,
ua = navigator.userAgent.toLowerCase()
if (window.devicePixelRatio !== undefined) {
ratio = window.devicePixelRatio
} else if (~ua.indexOf('msie')) {
if (screen.deviceXDPI && screen.logicalXDPI) {
ratio = screen.deviceXDPI / screen.logicalXDPI
}
} else if (window.outerWidth !== undefined && window.innerWidth !== undefined) {
ratio = window.outerWidth / window.innerWidth
}
if (ratio) {
ratio = Math.round(ratio * 100)
}
return ratio
}
}
}
</script>
<style>
.zindx {
min-width: 1200px;
}
body .el-table th.gutter {
display: table-cell !important;
}
.plTableBox.el-table__header,
.el-table__body,
.el-table__footer {
width: 100% !important;
table-layout: fixed !important;
}
</style>

57
src/api/CVT/index.js Normal file
View File

@@ -0,0 +1,57 @@
import request from '@/utils/request'
// 新增cvt系数
export function addCVT(data) {
return request({
url: '/device-boot/cvt/add',
method: 'post',
data: data
})
}
// 删除cvt系数
export function deleteById(data) {
return request({
url: '/device-boot/cvt/deleteById',
method: 'post',
params: data
})
}
// 分页查询cvt
export function queryPage(data) {
return request({
url: '/device-boot/cvt/queryPage',
method: 'post',
data
})
}
// 修改cvt系数
export function updateCvt(data) {
return request({
url: '/device-boot/cvt/updateCvt',
method: 'post',
data: data
})
}
// 新增cvt系数绑定
export function cvtBind(data) {
return request({
url: '/device-boot/cvtBind/add',
method: 'post',
data: data
})
}
// 根据监测点id查询绑定cvt系数
export function queryByLineId(data) {
return request({
url: '/device-boot/cvtBind/queryByLineId',
method: 'post',
params: data
})
}
// 执行算法
export function measurementPointExecutorByHour(data) {
return request({
url: '/prepare-boot/executor/measurementPointExecutorByHour',
method: 'post',
data
})
}

View File

@@ -1,93 +1,93 @@
import request from '@/utils/request'
export function list(data) {
return request({
url: '/system-boot/dictType/list',
method: 'post',
data: data
})
}
export function updateType(data) {
return request({
url: '/system-boot/dictType/update',
method: 'post',
data: data
})
}
export function add(data) {
return request({
url: '/system-boot/dictType/add',
method: 'post',
data: data
})
}
export function addData(data) {
return request({
url: '/system-boot/dictData/add',
method: 'post',
data: data
})
}
export function deleteType(data) {
return request({
url: '/system-boot/dictType/delete',
method: 'post',
data: data
})
}
export function updateData(data) {
return request({
url: '/system-boot/dictData/update',
method: 'post',
data: data
})
}
export function deleteData(data) {
return request({
url: '/system-boot/dictData/delete',
method: 'post',
data: data
})
}
export function getTypeIdData(data) {
return request({
url: '/system-boot/dictData/getTypeIdData',
method: 'post',
data: data
})
}
export function getSysConfig() {
return request({
url: '/system-boot/config/getSysConfig',
method: 'get',
})
}
export function getDicTree() {
return request({
url: '/system-boot/dictTree/queryTree',
method: 'get',
})
}
export function getDicTreeAdd(data) {
return request({
url: '/system-boot/dic/add',
method: 'post',
data: data
})
}
export function getDicTreeUpdate(data) {
return request({
url: '/system-boot/dic/update',
method: 'put',
data: data
})
}
export function getDicTreeDelete(data) {
return request({
url: '/system-boot/dic/delete',
method: 'delete',
params: data
})
import request from '@/utils/request'
export function list(data) {
return request({
url: '/system-boot/dictType/list',
method: 'post',
data: data
})
}
export function updateType(data) {
return request({
url: '/system-boot/dictType/update',
method: 'post',
data: data
})
}
export function add(data) {
return request({
url: '/system-boot/dictType/add',
method: 'post',
data: data
})
}
export function addData(data) {
return request({
url: '/system-boot/dictData/add',
method: 'post',
data: data
})
}
export function deleteType(data) {
return request({
url: '/system-boot/dictType/delete',
method: 'post',
data: data
})
}
export function updateData(data) {
return request({
url: '/system-boot/dictData/update',
method: 'post',
data: data
})
}
export function deleteData(data) {
return request({
url: '/system-boot/dictData/delete',
method: 'post',
data: data
})
}
export function getTypeIdData(data) {
return request({
url: '/system-boot/dictData/getTypeIdData',
method: 'post',
data: data
})
}
export function getSysConfig() {
return request({
url: '/system-boot/config/getSysConfig',
method: 'get',
})
}
export function getDicTree() {
return request({
url: '/system-boot/dictTree/queryTree',
method: 'get',
})
}
export function getDicTreeAdd(data) {
return request({
url: '/system-boot/dictTree/add',
method: 'post',
data: data
})
}
export function getDicTreeUpdate(data) {
return request({
url: '/system-boot/dictTree/update',
method: 'put',
data: data
})
}
export function getDicTreeDelete(data) {
return request({
url: '/system-boot/dictTree/delete',
method: 'delete',
params: data
})
}

View File

@@ -8,6 +8,16 @@ export function getAllMonitorPageList(data) {
data
})
}
export function getAllMainUserPageList(data) {
return request({
url: '/device-boot/pms/monitor/getAllMainUserPageList',
method: 'post',
data
})
}
// 新增牵引站信息
export function addMonitor(data) {
return request({

View File

@@ -51,3 +51,11 @@ export function objType(data) {
params: data
})
}
export function objTypeStatis(data) {
return request({
url: '/device-boot/monitorStatistics/objTypeStatis',
method: 'post',
params: data
})
}

View File

@@ -15,6 +15,14 @@ export function heBeiToken(data) {
params: data,
});
}
// /超高压嵌入token校验
export function productionManagementCheck(data) {
return request({
url: "/pqs-auth/judgeToken/productionManagementCheck",
method: "post",
params: data,
});
}
//登录获取token
export function login(data) {
return request({

View File

@@ -9,7 +9,7 @@
v-show="!collapse"
class="sidebar-title"
:style="{ fontSize: settings.layout === 'layout1' && settings.title.length >= 8 ? '14px' : '24px'}"
>{{ settings.title }} </h1>
>{{ settings.title }} <span style="font-size: 14px">(v1.0.0)</span> </h1>
</transition>
</div>
</div>

View File

@@ -3,8 +3,7 @@ import store from './store'
import NProgress from 'nprogress' // progress bar
import 'nprogress/nprogress.css' // progress bar style
import getPageTitle from '@/utils/get-page-title'
import { logout } from '@/api/user.js'
import { productionManagementCheck } from '@/api/user.js'
// NProgress.configure({ showSpinner: false }) // NProgress Configuration
// && from.path === '/agreement' && from.path === '/policy'
const whiteList = ['/login', '/agreement', '/policy'] // no redirect whitelist
@@ -19,7 +18,12 @@ const cgyList = [
'/Statistical-analysis/baselineLevelAssessment',
'/Statistical-analysis/substationBackgroundHarmonic',
'/Statistical-analysis/steadyStateIndicators',
'/Statistical-analysis/transientIndicators'
'/Statistical-analysis/transientIndicators',
'/harmonicWave/homePage',
'/harmonicWave/pointmonitoring',
'/harmonicWave/regionalmonitoring',
'/harmonicWave/comprehensiveanalysis',
'/harmonicWave/CVT'
]
// 免登录判断
import { sm2, encrypt } from '@/assets/commjs/sm2.js'
@@ -27,7 +31,11 @@ import { sm3Digest } from '@/assets/commjs/sm3'
import { setDictype, setSysConfig } from '@/utils/auth'
import { gongkey, CodeSr, heBeiToken, menulist, updateFirstPassword, dictypeData, getSysConfig } from '@/api/user'
let routerPath = ''
let flag = false
router.beforeEach(async (to, from, next) => {
console.log('🚀 ~ to:', to)
console.log('🚀 ~ getURLParameter ~ window.location.href:', window.location.href)
// start progress bar
// NProgress.start()
@@ -43,6 +51,10 @@ router.beforeEach(async (to, from, next) => {
// 超高压河北免登录功能
if (process.env.VUE_APP_MODE === 'cgyqr') {
if (flag) {
flag = false
return next()
}
if (process.env.VUE_APP_HB == 'hbqr') {
// let data = JSON.parse(sessionStorage.getItem('userInfo1'))
// if (data.userToken == sessionStorage.getItem('HB_TOKEN')) {
@@ -54,7 +66,10 @@ router.beforeEach(async (to, from, next) => {
// window.sessionStorage.removeItem('cntoken')
// sessionStorage.setItem('HB_TOKEN', data.userToken)
// setTimeout(() => {
proceed(to, from, next, 'cdf')
// console.log('🚀 ~ getURLParameter ~ url:', url)
proceed({ path: window.location.href.split('#')[1].split('&')[0] }, from, next, 'cdf')
// }, 10)
// }
@@ -87,7 +102,25 @@ router.beforeEach(async (to, from, next) => {
// })
// }
} else {
proceed(to, from, next)
// const response = await fetch('/')
// const flag = response.headers.get('X-Xbqr')
let { accessToken, pathname } = getURLParameter('accessToken')
console.log('🚀 ~ accessToken:', accessToken, pathname)
// getURLParameter
if (accessToken) {
// 超高压嵌入 接受父应用传参
console.log('超高压嵌入')
productionManagementCheck({
token: accessToken
}).then(res => {
if (res.code == 'A0000') {
proceed({ path: pathname || to.path }, from, next, 'cdf1')
}
})
} else {
proceed(to, from, next)
}
}
// else {
@@ -131,11 +164,54 @@ router.beforeEach(async (to, from, next) => {
}
}
})
// 解析 URL 参数
function getURLParameter(name) {
// 获取当前页面的 URL
const url = window.location.href
// console.log('🚀 ~ getURLParameter ~ url:', url)
// 使用 URL 对象解析 URL
const urlObj = new URL(url)
console.log('🚀 ~ getURLParameter ~ urlObj:', urlObj)
// 获取查询参数
const params = new URLSearchParams(urlObj.search)
console.log(params.get(name)) // 输出: 123
console.log('pathname', urlObj.pathname) // 输出: 123
// 获取 id 参数
return {
accessToken: params.get('accessToken'),
pathname: urlObj.pathname
}
}
function getURLParameterHb(name) {
// 获取当前页面的 URL
const url = window.location.href
// console.log('🚀 ~ getURLParameter ~ url:', url)
// 使用 URL 对象解析 URL
const urlObj = new URL(url)
console.log('🚀 ~ getURLParameter ~ urlObj:', urlObj)
// 获取查询参数
const params = new URLSearchParams(urlObj.search)
console.log(params.get(name)) // 输出: 123
console.log('pathname', urlObj.pathname) // 输出: 123
// 获取 id 参数
return {
accessToken: params.get('accessToken'),
pathname: urlObj.pathname
}
}
async function proceed(to, from, next, HB_NAME) {
// 打印当前 name 和 sessionStorage 中 cntoken 是否为空的日志
let name = HB_NAME || 'cdf'
// 检查 sessionStorage 中是否没有 cntoken
console.log('🚀 ~ proceed ~ name:', name, window.sessionStorage.getItem('cntoken') == null)
// 定义默认密码
if (window.sessionStorage.getItem('cntoken') == null) {
// 初始化登录表单
let password = '@#001njcnpqs'
let loginjmForm = {
username: '',
@@ -143,47 +219,69 @@ async function proceed(to, from, next, HB_NAME) {
grant_type: 'captcha',
verifyCode: 0,
imageCode: ''
// 对 name 进行加密处理
}
let username = encrypt(name)
// 设置登录表单的用户名
// 将应用高度存储到 sessionStorage 中
loginjmForm.username = username
// 调用 gongkey 函数获取公钥
window.sessionStorage.setItem('appheight', document.body.offsetHeight - 10)
await gongkey({ loginName: username }).then(async response => {
window.publicKey = response.data
// 将公钥存储到全局变量和 localStorage 中
window.localStorage.setItem('publicKey', response.data)
var sm3Pwd = sm3Digest(password)
// 使用 SM3 算法对密码进行摘要处理
var jiamipassword = ''
// 使用 SM2 算法对密码进行加密
jiamipassword = sm2(sm3Pwd + '|' + password, publicKey, 0)
loginjmForm.password = jiamipassword
// 设置登录表单的加密密码
store
// 调用 Vuex 的 login 方法进行登录
.dispatch('user/login', loginjmForm)
.then(async response => {
if (response.code === 'A0101' && response.message === '登录认证,密码失效,请重置') {
// 如果登录响应需要重置密码
CodeSr().then(response => {
// 调用 CodeSr 函数获取验证码图片
let blob = new Blob([response], { type: 'image/jpg' })
let url = window.URL.createObjectURL(blob)
})
}
await store.dispatch('user/getInfo')
// 获取用户信息
// 根据角色生成可访问的路线图
const accessRoutes = await store.dispatch('permission/generateRoutes')
// 动态添加可访问的路由
setTimeout(() => {
router.addRoutes(accessRoutes)
if (response.code === 'A0000') {
// 如果登录成功
loginjmForm.verifyCode = 0
// 重置验证码
SysConfig()
// 调用 SysConfig 函数进行系统配置
// cgyList.indexOf(to.path) !== -1
store.dispatch('user/getmenu').then(async response => {
await getmuen(response.data[0])
router.push({
path: cgyList.indexOf(to.path) !== -1 ? to.path : to.path //routerPath
})
})
}
next()
if (process.env.VUE_APP_KEY == 'scqr') {
flag = true
next(to.path)
} else {
next()
}
}, 500)
})
.catch(error => {
@@ -195,7 +293,12 @@ async function proceed(to, from, next, HB_NAME) {
})
})
} else {
next()
if (process.env.VUE_APP_KEY == 'scqr') {
flag = true
next(to.path)
} else {
next()
}
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -7,10 +7,11 @@ import { CodeSr } from '@/api/user'
axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
const service = axios.create({
// baseURL: '/harmonicWaveApi',//超高压生产嵌入
// baseURL: '/PMS3/Application/third/aqcp-dnzl/harmonicWaveApi',//河北嵌入
baseURL: '/api',
timeout: 150000
})
// service.interceptors.request.use(
// config => {
// if(config.url !=='/pqs-oauth2/oauth/token' || config.params.grant_type=='refresh_token'){

View File

@@ -615,20 +615,24 @@ export default {
//台区台账表头
tableHeaderMonitoring: [
// { prop: 'id', label: '监测点编号', width: 120 },
{ prop: 'name', label: '监测点名称', width: 220 },
{ prop: 'name', label: '测点名称', width: 220 },
{ prop: 'monitorId', label: '测点编号', width: 220 },
{ prop: 'orgName', label: '组织机构名称', width: 170 },
{ prop: 'operationName', label: '运维单位名称', width: 170 },
{ prop: 'midStation', label: '变电站编号', width: 150 },
{ prop: 'powerrName', label: '变电站名称', width: 120 },
//{ prop: "generatrixName", label: "母线名称", width: 120 },
{ prop: 'busId', label: '母线编号', width: 180 },
{ prop: 'lineName', label: '母线名称', width: 180 },
// { prop: "lineId", label: "监测线路ID", width: 180 },
{ prop: "lineNum", label: "装置接线序号", width: 180 },
{ prop: 'voltageLevel', label: '电压等级', width: 100 },
{ prop: 'monitorState', label: '监测点状态', width: 120 },
{ prop: 'monitorObjectName', label: '监测对象名称', width: 250 },
{ prop: 'monitorType', label: '监测点类型', width: 120 },
{ prop: 'minShortCircuitCapacity', label: '最小短路容量', width: 120 },
{ prop: 'powerSupplyEqCapacity', label: '供电设备容量', width: 120 },
{ prop: 'userAgreementCapacity', label: '用户协议容量', width: 120 },
{ prop: 'putDate', label: '投运日期', width: 120 },
{
prop: 'voltageDeviationUpperLimit',
label: '电压偏差限值(上)',
@@ -654,7 +658,7 @@ export default {
{ prop: 'objType', label: '对象类型', width: 170 },
// { prop: "monitorObjectId", label: "监测对象编号", width:170 },
{ prop: 'monitorObjectName', label: '监测对象名称', width: 170 },
{ prop: 'tradeCode', label: '行业分类', width: 170 },
{ prop: 'statisticalInterval', label: '统计间隔(min)', width: 140 },
{ prop: 'terminalCode', label: '关联的监测终端编号', width: 190 },
@@ -1383,7 +1387,7 @@ export default {
form.pageSize = this.total
getAllMonitorPageList(form).then(res => {
this.$refs.Monitoringpoint.exportData({
filename: '监测点台账', // 文件名字
filename: '监测点台账'+new Date().getTime(), // 文件名字
sheetName: 'Sheet1',
type: 'xlsx', //导出文件类型 xlsx 和 csv
useStyle: true,
@@ -1401,7 +1405,7 @@ export default {
const url = window.URL.createObjectURL(blob)
const link = document.createElement('a') // 创建a标签
link.href = url // link.download = "电压暂降事件分析报告"; // 设置下载的文件名
link.download = '上送典型台账.xls' // 设置下载的文件名
link.download = '典型台账.xls' // 设置下载的文件名
document.body.appendChild(link)
link.click() //执行下载
document.body.removeChild(link)

View File

@@ -214,7 +214,7 @@ export default {
tableHeaderLine: [
{ prop: 'midBusId', label: '同源线路编号' },
{ prop: 'midBusName', label: '同源母线名称' },
{ prop: 'name', label: '线路名称' },
{ prop: 'name', label: '名称' },
{ prop: 'scale', label: '电压等级' },
{ prop: 'generatrixName', label: '所属母线' },
{ prop: 'stationName', label: '所属电站' },

View File

@@ -2,8 +2,12 @@
<template>
<div>
<el-form :inline="true" :model="ruleForm" class="demo-form-inline">
<el-form-item>
<Area @click="handleNodeArea"></Area>
</el-form-item>
<el-form-item label="信息查询:">
<el-input v-model.trim="ruleForm.searchValue" placeholder="请输入查询信息" clearable></el-input>
<el-input v-model.trim="ruleForm.searchValue" placeholder="请输入台区名称,所属线路" clearable></el-input>
</el-form-item>
<el-form-item>
@@ -174,8 +178,9 @@ import {
} from '@/api/hbaccountoperation/StationAreaInformation'
import { deptTree } from '@/api/admin/dept'
import { dicData } from '@/assets/commjs/dictypeData'
import Area from '@/views/components/Area/Area.vue'
export default {
components: { PMS_Data, Organization, Operation },
components: { PMS_Data, Organization, Operation,Area },
data() {
return {
vh: '',
@@ -187,7 +192,8 @@ export default {
ruleForm: {
searchValue: '',
pageNum: 1,
pageSize: 20
pageSize: 20,
orgId:JSON.parse(window.sessionStorage.getItem('Info')).deptId,
// orderBy: "",
// searchBeginTime: "",
// searchEndTime: "",
@@ -791,6 +797,11 @@ export default {
row.row.isUpToGrid = '是'
}
},
handleNodeArea(data) {
this.ruleForm.orgId = data.id
},
//导出
exportEvent() {
getPowerDistributionAreaList({

File diff suppressed because it is too large Load Diff

View File

@@ -4,10 +4,12 @@
<el-col>
<el-tabs v-model.trim="activeName" @tab-click="handleClick" type="border-card">
<el-tab-pane label="主网监测点台帐" name="second" :style="'height:' + vh + ';'">
<Monitoringpoint v-if="activeName == 'second'"></Monitoringpoint>
</el-tab-pane>
<el-tab-pane label="主网用户台账" name="Typical" :style="'height:' + vh + ';'">
<Typical :flag="1" v-if="activeName == 'Typical'"></Typical>
</el-tab-pane>
<el-tab-pane label="主网用户台账统计" name="statistics" :style="'height:' + vh + ';'">
<statistics v-if="activeName == 'statistics'"></statistics>
</el-tab-pane>
</el-tabs>
</el-col>
@@ -16,18 +18,20 @@
</template>
<script>
import Monitoringpoint from '../../components/Monitoringpoint'
import statistics from '@/views/Account-management/components/uploadGw/statistics'
import Typical from '@/views/Account-management/components/uploadGw/Monitoringpoint'
export default {
name: 'uploadGw',
components: {
Monitoringpoint
Typical,
statistics
},
data() {
return {
vh: '',
activeName: 'first',
activeName: 'Typical',
device: ''
}
},

View File

@@ -0,0 +1,172 @@
<template>
<div>
<el-form :inline="true" :model="ruleForm" class="demo-form-inline">
<el-form-item>
<Area @click="handleNodeArea"></Area>
</el-form-item>
<el-form-item>
<el-button type="primary" class="ml10" icon="el-icon-search" @click="Power">查询</el-button>
<el-button type="primary" icon="el-icon-download" @click="exportEvent">导出</el-button>
</el-form-item>
</el-form>
<template>
<vxe-table
stripe
:data="busData"
:height="height"
border
size="mini"
ref="setInformation"
v-loading="isLoading"
header-cell-class-name="table_header"
>
<vxe-table-column
v-for="(val, index) in tableHeaderPower"
align="center"
:field="val.prop"
:title="val.label"
:min-width="val.width"
:show-overflow="true"
></vxe-table-column>
</vxe-table>
</template>
</div>
</template>
<script>
// import bus from "@/assets/js/eventBus";
import { objType, objTypeStatis } from '@/api/hbaccountoperation/setInformation'
import Area from '@/views/components/Area/Area.vue'
import { dicData } from '@/assets/commjs/dictypeData'
export default {
components: { Area },
data() {
return {
ruleForm: {
deptId: JSON.parse(window.sessionStorage.getItem('Info')).deptId,
up:0
},
height: null,
isLoading: false,
multipleSelection: [],
Voltagelevel: [], //电压等级
//台区台账表头
tableHeaderPower: [],
busData: []
}
},
created() {},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.Power()
// this.sendMessage()
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
computed: {},
methods: {
setHeight() {
this.device = window.devicePixelRatio
this.height = window.sessionStorage.getItem('appheight') - 130
},
handleNodeArea(data) {
this.ruleForm.deptId = data.id
},
//获取类型
//查询母线信息
Power() {
this.isLoading = true
this.tableHeaderPower = []
this.busData = []
objTypeStatis(this.ruleForm).then(res => {
let data = res.data
let result = data[0].reduce(
(acc, item) => {
if (item === '合计') {
acc.push([])
} else {
acc[acc.length - 1].push(item)
}
return acc
},
[[]]
)
Array.from(result[0]).forEach((char, i) => {
this.tableHeaderPower.push({
prop: `prop${i}`,
label: char,
width: char.length > 9 ? 250 : 130
})
})
this.tableHeaderPower[0].width = 350
console.log(this.tableHeaderPower)
data.shift()
data.forEach((item, ind) => {
// console.log('🚀 ~ objType ~ item:', item)
this.busData.push({})
Array.from(item).forEach((char, i) => {
this.busData[ind][`prop${i}`] = char
})
})
console.log(this.busData)
this.isLoading = false
})
},
//导出
exportEvent() {
objType({
deptId: this.ruleForm.deptId
}).then(res => {
this.$refs.setInformation.exportData({
filename: '台账上送统计', // 文件名字
sheetName: 'Sheet1',
type: 'xlsx', //导出文件类型 xlsx 和 csv
useStyle: true,
data: res.data.records, // 数据源 // 过滤那个字段导出
columnFilterMethod: function (column, $columnIndex) {
return !(column.$columnIndex === 0)
}
})
})
}
}
}
</script>
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
::v-deep .vxe-table .cell {
text-align: center;
}
::v-deep .el-tabs--border-card > .el-tabs__content {
padding: 10px;
}
.pms {
margin-left: 10px;
}
.obtain {
margin-left: 1220px;
}
</style>

View File

@@ -10,6 +10,11 @@
<el-tab-pane label="主网监测点台帐" name="second" :style="'height:' + vh + ';'">
<Monitoringpoint v-if="activeName == 'second'"></Monitoringpoint>
</el-tab-pane>
<el-tab-pane label="主网监测点限值" name="Zhuwangjiancedianxianzhi" :style="'height:' + vh + ';'">
<Zhuwangjiancedianxianzhi
v-if="activeName == 'Zhuwangjiancedianxianzhi'"
></Zhuwangjiancedianxianzhi>
</el-tab-pane>
<!-- <el-tab-pane
label="配网监测点台帐"
@@ -31,15 +36,15 @@
<PowerGenerationAccount v-if="activeName == 'fifth'" />
</el-tab-pane>
<el-tab-pane label="监测终端台帐" name="sixth" :style="'height:' + vh + ';'">
<el-tab-pane label="终端台帐" name="sixth" :style="'height:' + vh + ';'">
<TerminalAccount v-if="activeName == 'sixth'"></TerminalAccount>
</el-tab-pane>
<el-tab-pane label="电站监测点设置信息" name="seventh" :style="'height:' + vh + ';'">
<el-tab-pane label="电站台账" name="seventh" :style="'height:' + vh + ';'">
<setInformation v-if="activeName == 'seventh'"></setInformation>
</el-tab-pane>
<el-tab-pane label="牵引站信息" name="eighth" :style="'height:' + vh + ';'">
<el-tab-pane label="牵引站台账" name="eighth" :style="'height:' + vh + ';'">
<TractionStationInformation v-if="activeName == 'eighth'"></TractionStationInformation>
</el-tab-pane>
@@ -47,15 +52,11 @@
<transformer v-if="activeName == 'ninth'"></transformer>
</el-tab-pane>
<el-tab-pane label="线台账" name="tenth" :style="'height:' + vh + ';'">
<el-tab-pane label="线台账" name="tenth" :style="'height:' + vh + ';'">
<RouteTable v-if="activeName == 'tenth'"></RouteTable>
</el-tab-pane>
<el-tab-pane label="主网监测点限值" name="Zhuwangjiancedianxianzhi" :style="'height:' + vh + ';'">
<Zhuwangjiancedianxianzhi
v-if="activeName == 'Zhuwangjiancedianxianzhi'"
></Zhuwangjiancedianxianzhi>
</el-tab-pane>
<el-tab-pane label="上送典型台账" name="Typical" :style="'height:' + vh + ';'">
<el-tab-pane label="典型台账" name="Typical" :style="'height:' + vh + ';'">
<Typical :flag="1" v-if="activeName == 'Typical'"></Typical>
</el-tab-pane>
<el-tab-pane label="台账上送统计" name="statistics" :style="'height:' + vh + ';'">

View File

@@ -1,120 +1,120 @@
<template>
<div class="pd10">
<el-form :inline="true" :model="formData" class="demo-form-inline">
<el-form-item>
<Timeinterval ref="interval" :interval="3"></Timeinterval>
</el-form-item>
<el-form-item label="筛选数据:">
<el-input v-model.trim="formData.loginName" placeholder="请输入筛选数据" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit" icon="el-icon-search">查询</el-button>
</el-form-item>
</el-form>
<el-table
stripe
size="mini"
:row-config="{ isCurrent: true, isHover: true }"
border
highlight-current-row
v-loading="loading"
element-loading-text="数据加载中"
header-cell-class-name="table_header"
:data="datamock"
style="width: 100%"
:height="vh + 'px'"
>
<el-table-column prop="userName" label="登录用户" align="center"></el-table-column>
<el-table-column prop="ip" label="登录ip" align="center"></el-table-column>
<el-table-column prop="time" label="登录时间" align="center"></el-table-column>
</el-table>
<el-pagination
background
align="right"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="formData.pageNum"
:page-sizes="[20, 30, 50, 100]"
:page-size="formData.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
class="mt10"
></el-pagination>
</div>
</template>
<script>
import Timeinterval from '@/views/components/Timeinterval.vue'
import { getAuditLog } from '@/api/AuditManagement/AuditManagement'
export default {
components: {
Timeinterval
},
props: {},
data() {
return {
loading: false,
zoom: '', //图表焦点校验
vh: undefined,
formData: {
operateType: '认证',
loginName: '',
pageNum: 1,
pageSize: 20
},
datamock: [],
total: undefined
}
},
created() {},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.onSubmit()
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.vh = window.sessionStorage.getItem('appheight') - 95
},
//查询
onSubmit() {
this.loading = true
this.item = this.$refs.interval.timeValue
this.formData.searchBeginTime = this.item[0]
this.formData.searchEndTime = this.item[1]
getAuditLog(this.formData).then(res => {
this.datamock = res.data.records
this.total = res.data.total
this.loading = false
})
},
//每页条数改变时触发 选择一页显示多少行
handleSizeChange(val) {
this.formData.pageSize = val
this.onSubmit()
},
//当前页改变时触发 跳转其他页
handleCurrentChange(val) {
this.formData.pageNum = val
this.onSubmit()
}
},
computed: {},
watch: {}
}
</script>
<style lang="less" scoped>
@import url('../../../styles/comStyle.less');
::v-deep .el-form-item--small .el-form-item__content,
.el-form-item--small .el-form-item__label {
height: 32px;
}
::v-deep .el-table .cell {
text-align: center;
}
</style>
<template>
<div class="pd10">
<el-form :inline="true" :model="formData" class="demo-form-inline">
<el-form-item>
<Timeinterval ref="interval" :interval="3"></Timeinterval>
</el-form-item>
<el-form-item label="筛选数据:">
<el-input v-model.trim="formData.loginName" placeholder="请输入筛选数据" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit" icon="el-icon-search">查询</el-button>
</el-form-item>
</el-form>
<el-table
stripe
size="mini"
:row-config="{ isCurrent: true, isHover: true }"
border
highlight-current-row
v-loading="loading"
element-loading-text="数据加载中"
header-cell-class-name="table_header"
:data="datamock"
style="width: 100%"
:height="vh + 'px'"
>
<el-table-column prop="userName" label="登录用户" align="center"></el-table-column>
<el-table-column prop="ip" label="登录IP" align="center"></el-table-column>
<el-table-column prop="time" label="登录时间" align="center"></el-table-column>
</el-table>
<el-pagination
background
align="right"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="formData.pageNum"
:page-sizes="[20, 30, 50, 100]"
:page-size="formData.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
class="mt10"
></el-pagination>
</div>
</template>
<script>
import Timeinterval from '@/views/components/Timeinterval.vue'
import { getAuditLog } from '@/api/AuditManagement/AuditManagement'
export default {
components: {
Timeinterval
},
props: {},
data() {
return {
loading: false,
zoom: '', //图表焦点校验
vh: undefined,
formData: {
operateType: '认证',
loginName: '',
pageNum: 1,
pageSize: 20
},
datamock: [],
total: undefined
}
},
created() {},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.onSubmit()
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.vh = window.sessionStorage.getItem('appheight') - 95
},
//查询
onSubmit() {
this.loading = true
this.item = this.$refs.interval.timeValue
this.formData.searchBeginTime = this.item[0]
this.formData.searchEndTime = this.item[1]
getAuditLog(this.formData).then(res => {
this.datamock = res.data.records
this.total = res.data.total
this.loading = false
})
},
//每页条数改变时触发 选择一页显示多少行
handleSizeChange(val) {
this.formData.pageSize = val
this.onSubmit()
},
//当前页改变时触发 跳转其他页
handleCurrentChange(val) {
this.formData.pageNum = val
this.onSubmit()
}
},
computed: {},
watch: {}
}
</script>
<style lang="less" scoped>
@import url('../../../styles/comStyle.less');
::v-deep .el-form-item--small .el-form-item__content,
.el-form-item--small .el-form-item__label {
height: 32px;
}
::v-deep .el-table .cell {
text-align: center;
}
</style>

View File

@@ -1,431 +1,431 @@
<template>
<div v-loading="loading">
<div>
<div id="boxi" :style="`height:${vh};overflow: hidden;`">
<div class="bx" id="wave"></div>
</div>
<el-tabs type="border-card">
<el-tab-pane label="暂态波形上送" :style="'height:' + vhh">
<el-table
stripe
:data="Data"
:height="height"
border
style="width: 100%"
header-cell-class-name="table_header"
>
<el-table-column align="center" prop="number" label="事件段"></el-table-column>
<el-table-column align="center" prop="number" label="波形起始点相位(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="跳变段电压变化率(V/ms)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="相位跳变(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="总分段数目"></el-table-column>
<el-table-column
align="center"
prop="number"
label="三相电压不平衡度(%)"
width="180"
></el-table-column>
<el-table-column align="center" prop="number" label="暂降类型"></el-table-column>
<el-table-column align="center" prop="number" label="暂降原因"></el-table-column>
</el-table>
</el-tab-pane>
</el-tabs>
</div>
</div>
</template>
<script>
import { getMonitorEventAnalyseWave } from '@/api/monitoringpointStatistics/echart'
import $ from 'jquery'
export default {
props: {
flag: {
type: Boolean,
default: false
},
DColor: {
type: Boolean,
default: false
},
boxoList: {
type: [Object, Array]
},
GJList: {
type: [Object, Array]
}
},
data() {
return {
loading: true,
url: require('@/assets/point.png'),
valA: 0,
isOpen: false,
time: '',
type: '',
severity: '',
iphasic: '',
eventValue: '',
persistTime: '',
lineName: '',
subName: '',
waveDatas: [],
Data: [],
height: null,
vhh: null,
ptpass: '',
waveHeight: undefined,
$wave: undefined,
color: '#006565',
charts: {},
arrpoints: [],
titles: '',
vh: null,
vw: null,
zoom: ''
}
},
created() {},
watch: {
value: function (a, b) {
if (a == 2) {
// $("#wave1").remove();
this.initWaves()
} else {
$('#wave1').remove()
this.initWaves()
}
}
},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.$wave = $('#wave').eq(0)
this.$nextTick(() => {
this.query()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
if (this.flag) {
// console.log(123);
this.vh = window.sessionStorage.getItem('appheight') - 210 + 'px'
} else {
// console.log(3333);
this.vh = window.sessionStorage.getItem('appheight') - 275 + 'px'
}
this.height = window.sessionStorage.getItem('appheight') / 2 - 300 + 'px'
this.vw = window.sessionStorage.getItem('appwidth') - 60 + 'px'
},
query() {
this.loading = true
this.initWave()
},
//开始画图
initWave() {
//清除之前增加的div
// $("#wave ~ .bx1").remove();
$('div.bx1').remove()
//设置暂降触发点的位置 一次值与二次值Y轴不同不是计算出来的
// var height = $(window).height() - 90;
var picHeight
var show = true
//var v = $("#interval").val();
var isvisible = false
picHeight = this.vh
this.$wave.css('height', picHeight)
this.$wave.css('width', this.vw)
var adata = []
var bdata = []
var cdata = []
var max = 0
var min = 0
//绘制横向第一个波形图
this.GJList.smp_x.forEach((item, ind) => {
if (this.GJList.smp_a[ind] > max) {
max = this.GJList.smp_a[ind]
} else if (this.GJList.smp_a[ind] < min) {
min = this.GJList.smp_a[ind]
}
if (this.GJList.smp_b[ind] > max) {
max = this.GJList.smp_b[ind]
} else if (this.GJList.smp_b[ind] < min) {
min = this.GJList.smp_b[ind]
}
if (this.GJList.smp_c[ind] > max) {
max = this.GJList.smp_c[ind]
} else if (this.GJList.smp_c[ind] < min) {
min = this.GJList.smp_c[ind]
}
adata.push([item, this.GJList.smp_a[ind]])
bdata.push([item, this.GJList.smp_b[ind]])
cdata.push([item, this.GJList.smp_c[ind]])
})
//绘制瞬时波形图
const echarts = require('echarts')
let wave = document.getElementById('wave')
let _this = this
var myChartes = echarts.init(wave)
let echartsColor = JSON.parse(window.localStorage.echartsColor)
var option = {
tooltip: {
top: '10px',
trigger: 'axis',
borderColor: 'grey',
backgroundColor: '#fff',
style: {
color: '#000',
fontSize: '15px',
padding: 10
},
formatter: function (params) {
// console.log(params)
var tips = ''
tips += '时刻:' + params[0].data[0] + '</br/>'
for (var i = 0; i < params.length; i++) {
if (params[i].seriesName != '暂降触发点') {
tips += params[i].seriesName + ':' + params[i].value[1] + '<br/>'
}
}
return tips
},
// axisPointer: {
// type: "cross",
// label: {
// color: "#fff",
// fontSize: 16,
// },
// },
textStyle: {
color: '#fff',
fontStyle: 'normal',
opacity: 0.35,
fontSize: 14
},
backgroundColor: 'rgba(0,0,0,0.35)',
borderWidth: 0
},
title: {
left: 'center',
text: '发生时刻:' + this.boxoList.startTime + ' PT变化:' + this.boxoList.measurementPointName,
textStyle: {
fontSize: 16,
color: _this.DColor ? '#fff' : echartsColor.WordColor
}
},
legend: {
left: '5%',
top: '20',
verticalAlign: 'top',
enabled: true,
itemDistance: 5,
textStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
rich: {
a: {
verticalAlign: 'middle'
}
},
padding: [2, 0, 0, 0] //[上、右、下、左]
}
},
toolbox: {
show: false,
feature: {
//restore: {},
saveAsImage: {
iconStyle: {
borderColor: _this.DColor ? '#fff' : echartsColor.WordColor
}
}
}
},
xAxis: {
type: 'value',
name: '时刻',
boundaryGap: false,
min: this.GJList.smp_x[0],
max: this.GJList.smp_x[this.GJList.smp_x.length - 1] + 1,
title: {
text: 'ms',
textStyle: {
fontSize: 12,
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
enabled: true,
align: 'high'
},
splitLine: {
show: false
},
axisTick: {
alignWithLabel: true
},
axisLine: {
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
if (_this.valA != (value - 0).toFixed(0)) {
_this.valA = (value - 0).toFixed(0)
return (value - 0).toFixed(0)
}
}
//rotate:39
}
// data: this.syncExtremes,
},
yAxis: {
type: 'value',
name: 'kV',
title: {
align: 'high',
offset: 0,
text: 'kV',
rotation: 0,
y: -10
},
boundaryGap: [0, '100%'],
showLastLabel: true,
max: (max + 10).toFixed(2),
min: (min - 10).toFixed(2),
opposite: false,
nameTextStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
//minInterval: 1,
type: 'value',
axisLine: {
show: true,
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
return (value - 0).toFixed(2)
}
},
splitLine: {
lineStyle: {
// 使用深浅的间隔色
color: [_this.DColor ? '#fff' : echartsColor.thread],
type: 'dashed',
opacity: 0.5
}
}
},
grid: {
left: '1%',
right: '40px',
bottom: '40px',
top: '55px',
containLabel: true
},
dataZoom: [
{
type: 'inside',
height: 13,
start: 0,
bottom: '20px',
end: 100
},
{
start: 0,
height: 13,
bottom: '20px',
end: 100
}
],
series: [
{
name: 'A相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#FFCC00'
},
data: adata
},
{
name: 'B相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#009900'
},
data: bdata
},
{
name: 'C相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#CC0000'
},
data: cdata
},
{
name: '暂降触发点',
type: 'scatter',
symbol: 'image://' + this.url,
itemStyle: {
width: 16,
height: 16
},
data: [[0, min]]
}
]
}
myChartes.setOption(option)
window.echartsArr.push(myChartes)
setTimeout(() => {
myChartes.resize()
this.loading = false
}, 400)
//第一个波形图数据绘制完毕后,绘制后续的波形图
// let waveDatasTemp = waveDatas.slice(1);
// waveDatasTemp.reverse();
}
}
}
</script>
<template>
<div v-loading="loading">
<div>
<div id="boxi" :style="`height:${vh};overflow: hidden;`">
<div class="bx" id="wave"></div>
</div>
<el-tabs type="border-card">
<el-tab-pane label="暂态波形上送" :style="'height:' + vhh">
<el-table
stripe
:data="Data"
:height="height"
border
style="width: 100%"
header-cell-class-name="table_header"
>
<el-table-column align="center" prop="number" label="事件段"></el-table-column>
<el-table-column align="center" prop="number" label="波形起始点相位(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="跳变段电压变化率(V/ms)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="相位跳变(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="总分段数目"></el-table-column>
<el-table-column
align="center"
prop="number"
label="三相电压不平衡度(%)"
width="180"
></el-table-column>
<el-table-column align="center" prop="number" label="暂降类型"></el-table-column>
<el-table-column align="center" prop="number" label="暂降原因"></el-table-column>
</el-table>
</el-tab-pane>
</el-tabs>
</div>
</div>
</template>
<script>
import { getMonitorEventAnalyseWave } from '@/api/monitoringpointStatistics/echart'
import $ from 'jquery'
export default {
props: {
flag: {
type: Boolean,
default: false
},
DColor: {
type: Boolean,
default: false
},
boxoList: {
type: [Object, Array]
},
GJList: {
type: [Object, Array]
}
},
data() {
return {
loading: true,
url: require('@/assets/point.png'),
valA: 0,
isOpen: false,
time: '',
type: '',
severity: '',
iphasic: '',
eventValue: '',
persistTime: '',
lineName: '',
subName: '',
waveDatas: [],
Data: [],
height: null,
vhh: null,
ptpass: '',
waveHeight: undefined,
$wave: undefined,
color: '#006565',
charts: {},
arrpoints: [],
titles: '',
vh: null,
vw: null,
zoom: ''
}
},
created() {},
watch: {
value: function (a, b) {
if (a == 2) {
// $("#wave1").remove();
this.initWaves()
} else {
$('#wave1').remove()
this.initWaves()
}
}
},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.$wave = $('#wave').eq(0)
this.$nextTick(() => {
this.query()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
if (this.flag) {
// console.log(123);
this.vh = window.sessionStorage.getItem('appheight') - 210 + 'px'
} else {
// console.log(3333);
this.vh = window.sessionStorage.getItem('appheight') - 275 + 'px'
}
this.height = window.sessionStorage.getItem('appheight') / 2 - 300 + 'px'
this.vw = window.sessionStorage.getItem('appwidth') - 60 + 'px'
},
query() {
this.loading = true
this.initWave()
},
//开始画图
initWave() {
//清除之前增加的div
// $("#wave ~ .bx1").remove();
$('div.bx1').remove()
//设置暂降触发点的位置 一次值与二次值Y轴不同不是计算出来的
// var height = $(window).height() - 90;
var picHeight
var show = true
//var v = $("#interval").val();
var isvisible = false
picHeight = this.vh
this.$wave.css('height', picHeight)
this.$wave.css('width', this.vw)
var adata = []
var bdata = []
var cdata = []
var max = 0
var min = 0
//绘制横向第一个波形图
this.GJList.smp_x.forEach((item, ind) => {
if (this.GJList.smp_a[ind] > max) {
max = this.GJList.smp_a[ind]
} else if (this.GJList.smp_a[ind] < min) {
min = this.GJList.smp_a[ind]
}
if (this.GJList.smp_b[ind] > max) {
max = this.GJList.smp_b[ind]
} else if (this.GJList.smp_b[ind] < min) {
min = this.GJList.smp_b[ind]
}
if (this.GJList.smp_c[ind] > max) {
max = this.GJList.smp_c[ind]
} else if (this.GJList.smp_c[ind] < min) {
min = this.GJList.smp_c[ind]
}
adata.push([item, this.GJList.smp_a[ind]])
bdata.push([item, this.GJList.smp_b[ind]])
cdata.push([item, this.GJList.smp_c[ind]])
})
//绘制瞬时波形图
const echarts = require('echarts')
let wave = document.getElementById('wave')
let _this = this
var myChartes = echarts.init(wave)
let echartsColor = JSON.parse(window.localStorage.echartsColor)
var option = {
tooltip: {
top: '10px',
trigger: 'axis',
borderColor: 'grey',
backgroundColor: '#fff',
style: {
color: '#000',
fontSize: '15px',
padding: 10
},
formatter: function (params) {
// console.log(params)
var tips = ''
tips += '时刻:' + params[0].data[0] + '</br/>'
for (var i = 0; i < params.length; i++) {
if (params[i].seriesName != '暂降触发点') {
tips += params[i].seriesName + ':' + params[i].value[1] + '<br/>'
}
}
return tips
},
// axisPointer: {
// type: "cross",
// label: {
// color: "#fff",
// fontSize: 16,
// },
// },
textStyle: {
color: '#fff',
fontStyle: 'normal',
opacity: 0.35,
fontSize: 14
},
backgroundColor: 'rgba(0,0,0,0.35)',
borderWidth: 0
},
title: {
left: 'center',
text: '发生时刻:' + this.boxoList.startTime + ' PT变化:' + this.boxoList.measurementPointName,
textStyle: {
fontSize: 16,
color: _this.DColor ? '#fff' : echartsColor.WordColor
}
},
legend: {
left: '5%',
top: '20',
verticalAlign: 'top',
enabled: true,
itemDistance: 5,
textStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
rich: {
a: {
verticalAlign: 'middle'
}
},
padding: [2, 0, 0, 0] //[上、右、下、左]
}
},
toolbox: {
show: false,
feature: {
//restore: {},
saveAsImage: {
iconStyle: {
borderColor: _this.DColor ? '#fff' : echartsColor.WordColor
}
}
}
},
xAxis: {
type: 'value',
name: '时刻',
boundaryGap: false,
min: this.GJList.smp_x[0],
max: this.GJList.smp_x[this.GJList.smp_x.length - 1] + 1,
title: {
text: 'ms',
textStyle: {
fontSize: 12,
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
enabled: true,
align: 'high'
},
splitLine: {
show: false
},
axisTick: {
alignWithLabel: true
},
axisLine: {
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
if (_this.valA != (value - 0).toFixed(0)) {
_this.valA = (value - 0).toFixed(0)
return (value - 0).toFixed(0)
}
}
//rotate:39
}
// data: this.syncExtremes,
},
yAxis: {
type: 'value',
name: 'kV',
title: {
align: 'high',
offset: 0,
text: 'kV',
rotation: 0,
y: -10
},
boundaryGap: [0, '100%'],
showLastLabel: true,
max: (max + 10).toFixed(2),
min: (min - 10).toFixed(2),
opposite: false,
nameTextStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
//minInterval: 1,
type: 'value',
axisLine: {
show: true,
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
return (value - 0).toFixed(2)
}
},
splitLine: {
lineStyle: {
// 使用深浅的间隔色
color: [_this.DColor ? '#fff' : echartsColor.thread],
type: 'dashed',
opacity: 0.5
}
}
},
grid: {
left: '1%',
right: '40px',
bottom: '40px',
top: '55px',
containLabel: true
},
dataZoom: [
{
type: 'inside',
height: 13,
start: 0,
bottom: '20px',
end: 100
},
{
start: 0,
height: 13,
bottom: '20px',
end: 100
}
],
series: [
{
name: 'A相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#FFCC00'
},
data: adata
},
{
name: 'B相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#009900'
},
data: bdata
},
{
name: 'C相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#CC0000'
},
data: cdata
},
{
name: '暂降触发点',
type: 'scatter',
symbol: 'image://' + this.url,
itemStyle: {
width: 16,
height: 16
},
data: [[0, min]]
}
]
}
myChartes.setOption(option)
window.echartsArr.push(myChartes)
setTimeout(() => {
myChartes.resize()
this.loading = false
}, 400)
//第一个波形图数据绘制完毕后,绘制后续的波形图
// let waveDatasTemp = waveDatas.slice(1);
// waveDatasTemp.reverse();
}
}
}
</script>

View File

@@ -88,7 +88,7 @@ export default {
{ prop: 'effectiveAccessRate', label: '有效接入率(%)' },
{ prop: 'dataIntegrityRate', label: '数据完整率(%)' },
{ prop: 'indexIntegrityRate', label: '指标完整率(%)' },
{ prop: 'isUnusual', label: '数据是否异常' }
{ prop: 'isUnusual', label: '异常监测点数' }
],
qualitystatisticsData: [],
device: '',
@@ -154,13 +154,13 @@ export default {
//判断数据是否异常
cellStyle(row) {
console.log(row)
if (row.columnIndex == 6) {
if (row.row.isUnusual == 0) {
row.row.isUnusual = '正常 '
} else if (row.row.isUnusual == 1) {
row.row.isUnusual = '异常'
}
}
// if (row.columnIndex == 6) {
// if (row.row.isUnusual == 0) {
// row.row.isUnusual = '正常 '
// } else if (row.row.isUnusual == 1) {
// row.row.isUnusual = '异常'
// }
// }
},
//导出
exportEvent() {

View File

@@ -2024,12 +2024,22 @@ export default {
this.$refs.ruleform.validate(value => {
// console.log(value);
if (value == true) {
if(this.ruleform.ifReleaseWarning == 1){
//需要提示预告警单不能为空
if(this.ruleform.workAlarmId == null || this.ruleform.workAlarmId == ''){
this.$message.warning("关联告预警单不可为空!");
return
}
}
this.$confirm('是否确认新增?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
addProblem(this.ruleform).then(res => {
if (res.code == 'A0000') {
this.$message({
@@ -2194,6 +2204,14 @@ export default {
this.$refs.ruleform.validate(value => {
// console.log(value);
if (value == true) {
if(this.ruleform.ifReleaseWarning == 1){
//需要提示预告警单不能为空
if(this.ruleform.workAlarmId == null || this.ruleform.workAlarmId == ''){
this.$message.warning("关联告预警单不可为空!");
return
}
}
this.$confirm('是否确认修改?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',

View File

@@ -29,7 +29,7 @@
<el-col :span="24">
<div class="button" style="float: left">
<el-button type="primary" icon="el-icon-circle-plus" @click="planAdditionFn">新增计划</el-button>
<el-button type="primary" icon="el-icon-s-claim" @click="planReviewFn">提交审核</el-button>
<!-- <el-button type="primary" icon="el-icon-s-claim" @click="planReviewFn">提交审核</el-button>-->
</div>
<div class="button">
@@ -667,7 +667,7 @@ export default {
//获取审核人列表
getAuditUser() {
let param = {roleType: 3}
let param = {roleType: 1}
getAuditUser(param).then(res => {
if (res && res.code === 'A0000') {
this.auditUserList = res.data

View File

@@ -1195,7 +1195,7 @@ export default {
//获取审核人列表
getAuditUser() {
let param = {roleType: 3}
let param = {roleType: 1}
getAuditUser(param).then(res => {
if (res && res.code === 'A0000') {
this.auditUserList = res.data

View File

@@ -6,9 +6,9 @@
<el-tab-pane label="普测计划管理" name="1" :style="'height:' + vh + 'px;'">
<Planmanagement v-if="activeName == '1'"></Planmanagement>
</el-tab-pane>
<el-tab-pane label="普测计划审批" name="2" :style="'height:' + vh + 'px;'">
<!-- <el-tab-pane label="普测计划审批" name="2" :style="'height:' + vh + 'px;'">
<Planapproval v-if="activeName == '2'" ref="planapprovalRef" :son="planId"></Planapproval>
</el-tab-pane>
</el-tab-pane>-->
<!-- <el-tab-pane label="普测结果管理" name="3" :style="'height:' + vh + 'px;'">
<Resultsmanagement v-if="activeName == '3'"></Resultsmanagement>
</el-tab-pane>

View File

@@ -35,13 +35,13 @@
<influence v-if="activeName == '4'"></influence>
</el-tab-pane>
<!-- <el-tab-pane
<el-tab-pane
label="详细数据表"
name="5"
:style="'height:' + vh + ';'"
>
<dataSheet v-if="activeName == '5'"></dataSheet>
</el-tab-pane> -->
</el-tab-pane>
</el-tabs>
</el-col>
</el-row>

View File

@@ -279,7 +279,7 @@ export default {
name: '超标点占比:%',
minInterval: 1,
axisLine: {
show: true,
lineStyle: {
@@ -644,7 +644,7 @@ export default {
let echartsColor = JSON.parse(window.localStorage.echartsColor)
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -278,7 +278,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -271,7 +271,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -18,9 +18,9 @@
<influence v-if="activeName == '4'"></influence>
</el-tab-pane>
<!-- <el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<dataSheet v-if="activeName == '5'"></dataSheet>
</el-tab-pane> -->
</el-tab-pane>
</el-tabs>
</el-col>
</el-row>

View File

@@ -278,7 +278,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -271,7 +271,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -19,9 +19,9 @@ l
<influence v-if="activeName == '4'"></influence>
</el-tab-pane>
<!-- <el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<dataSheet v-if="activeName == '5'"></dataSheet>
</el-tab-pane> -->
</el-tab-pane>
</el-tabs>
</el-col>
</el-row>

View File

@@ -275,7 +275,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -126,10 +126,10 @@ export default {
let hours = []
let days = [
'负序电压不平衡度',
'负序电压不平衡度平均超标天数',
'三项电压不平衡度',
'三项电压不平衡度平均超标天数',
'谐波电压平均超标天数',
'负序电压不平衡度超标占比'
'三项电压不平衡度超标占比'
]
let data = []
@@ -271,7 +271,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -19,9 +19,9 @@ l
<influence v-if="activeName == '4'"></influence>
</el-tab-pane>
<!-- <el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<el-tab-pane label="详细数据表" name="5" :style="'height:' + vh + ';'">
<dataSheet v-if="activeName == '5'"></dataSheet>
</el-tab-pane> -->
</el-tab-pane>
</el-tabs>
</el-col>
</el-row>

View File

@@ -21,10 +21,10 @@
</el-col>
</el-row>
<el-row :style="`height:${vh};position: relative;`">
<el-radio-group v-model="radio1" class="radioGroup" size="mini" @change="change">
<!-- <el-radio-group v-model="radio1" class="radioGroup" size="mini" @change="change">
<el-radio-button label="1">电压指标</el-radio-button>
<el-radio-button label="2">电流指标</el-radio-button>
</el-radio-group>
</el-radio-group>-->
<el-col :span="24" :style="`height:${vh}`">
<div v-loading="isLoading" id="electr3" style="width: 100%; height: 100%" />
</el-col>
@@ -605,7 +605,7 @@ export default {
let echartsColor = JSON.parse(window.localStorage.echartsColor)
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -278,7 +278,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -273,7 +273,7 @@ export default {
let option = {
title: {
text: '各单位指标',
text: '谐波指标',
left: 'center',
top: '5px',
textStyle: {

View File

@@ -539,7 +539,7 @@ export default {
}
option1 = {
title: {
text: '变电站态超标数量',
text: '变电站态超标数量',
left: 'center',
top: 10
},
@@ -777,7 +777,7 @@ export default {
}
option2 = {
title: {
text: '变电站态超标天数',
text: '变电站态超标天数',
left: 'center',
top: 20
},

View File

@@ -1,448 +1,449 @@
<template>
<el-container style="position: relative" id="dept">
<el-button type="primary" style="margin-top: -10px" class="flag" icon="el-icon-close" @click="$emit('close')">
返回
</el-button>
<el-main id="drag-dept-right ">
<div class="bm-view" id="container " :style="'height:' + (vh - 20) + 'px ;position: relative;'">
<div class="boxTop">
<el-form ref="form" :inline="true" :model="form">
<el-form-item label="模板:">
<el-select
value-key="id"
:popper-append-to-body="false"
v-model="form.TemplateId"
placeholder="请选择模板"
>
<el-option
v-for="item in options"
:key="item.id"
:label="item.name"
:value="item"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="报表类型:">
<el-select
v-model="form.TemplateId.reportForm"
:popper-append-to-body="false"
placeholder="请选择报表类型"
disabled
>
<el-option
v-for="item in reportFormList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item>
<Timeinterval ref="Timeinterval" :interval="3" />
</el-form-item>
<el-form-item>
<el-button
class="buttons"
size="small"
type="primary"
icon="el-icon-search"
@click="Template"
>
查询
</el-button>
<el-button
@click="downloadExcel"
class="buttons"
size="small"
type="primary"
icon="el-icon-download"
>
导出excel
</el-button>
</el-form-item>
</el-form>
</div>
<div
class="luckysheetBox"
style="padding: 0; margin: 0"
:style="`width:${vw - 50}px;height: ${vh - 200}px;`"
></div>
<div
id="luckysheet"
style="padding: 0; margin: 0"
:style="`width:${vw - 40}px;height: ${vh - 130}px;margin-top: 50px;`"
></div>
</div>
</el-main>
</el-container>
</template>
<script>
import jquery from 'jquery'
import { getCustomReport, getTemplateByDept } from '@/api/templateConfiguration'
import { exportExcel } from '@/views/components/luckyexcel/export'
import Timeinterval from '@/views/components/cgytree/TimeintervalTemplat.vue'
import TreeTemplat from '@/views/components/cgytree/TreeTemplat.vue'
import LuckyExcel from 'luckyexcel'
export default {
components: { TreeTemplat, Timeinterval },
props: {
reportID: {
type: String
}
},
data() {
return {
options: [],
zoom: '', //图表焦点校验
form: {
TemplateId: '',
reportForm: ''
},
reportFormList: [
{
value: '1',
label: '分析报表'
},
{
value: '2',
label: '统计报表'
},
{
value: '3',
label: '自定义报表'
}
],
loading: true,
vh: undefined,
vw: undefined,
view: true,
checkbox: false,
tablename: 1,
treenode: '',
statisticalList: {}, //树上面的选择框
data_info: [], //点位信息
map: null, //存储地图
flag: true,
showtoolbar: false, //富文本框头部显示
cellRightClickConfig: {
copy: false, // 复制
copyAs: false, // 复制为
paste: false, // 粘贴
insertRow: false, // 插入行
insertColumn: false, // 插入列
deleteRow: false, // 删除选中行
deleteColumn: false, // 删除选中列
deleteCell: false, // 删除单元格
hideRow: false, // 隐藏选中行和显示选中行
hideColumn: false, // 隐藏选中列和显示选中列
rowHeight: false, // 行高
columnWidth: false, // 列宽
clear: false, // 清除内容
matrix: false, // 矩阵操作选区
sort: false, // 排序选区
filter: false, // 筛选选区
chart: false, // 图表生成
image: false, // 插入图片
link: false, // 插入链接
data: false, // 数据验证
cellFormat: false // 设置单元格格式
}, //控制右键菜单
list: [
// {
// name: "Cell",
// index: 0,
// defaultRowHeight: 27,
// defaultColWidth: 105,
// },
],
deptId: ''
}
},
created() {},
mounted() {
this.deptId = JSON.parse(window.sessionStorage.getItem('Info')).deptId
this.zoom = 1 / document.body.style.zoom
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.$nextTick(() => {
this.getTemplateLists()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
this.vh = window.sessionStorage.getItem('appheight')
this.vw = document.getElementById('app-main-in').offsetWidth
},
async getTemplateLists() {
await getTemplateByDept({ id: this.deptId }).then(res => {
if (res != undefined && res.code == 'A0000') {
res.data.forEach(item => {
if (item.activation == 1) {
this.form.TemplateId = item
return
}
})
this.options = res.data
setTimeout(() => {
this.Template()
}, 0)
}
})
},
// 选择模板
Template() {
// debugger
let _this = this
getCustomReport({
startTime: this.$refs.Timeinterval.timeValue[0],
endTime: this.$refs.Timeinterval.timeValue[1],
type: this.$refs.Timeinterval.intervald,
tempId: this.form.TemplateId.id,
activation: this.form.TemplateId.activation,
lineId: this.reportID
// lineId: "8696be1d170e05b7d848accc059f4558",
}).then(response => {
_this.list = response
_this.init()
// jquery.getJSON(res.data[1], null, function (list) {
// _this.list = list;
//_this.init();
// });
})
// .then((res) => {
// console.log("res", res.data);
// let Datalist = JSON.parse(res.data);
// console.log(`13323`, JSON.parse(res.data));
// this.list = Datalist;
// this.init();
// });
},
// 初始化插件
init() {
window.luckysheet.destroy()
let options = {
container: 'luckysheet', //luckysheet为容器id
title: '',
lang: 'zh',
showinfobar: false,
cellRightClickConfig: this.cellRightClickConfig,
showtoolbar: this.showtoolbar,
// column:8,
// row:7,
showtoolbarConfig: {
textRotateMode: false // '文本旋转方式'
},
data: this.list
}
// console.log(options);
luckysheet.create(options)
},
// 下载表格
downloadExcel() {
// const value = this.selected;;
exportExcel(luckysheet.getAllSheets(), '下载')
// testaaa();
}
},
computed: {},
watch: {}
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
</style>
<style lang="scss" scoped>
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
.wrap {
display: flex;
justify-content: space-around;
}
#container {
width: 100%;
height: 83vh;
border: 1px solid rgb(0, 183, 255);
}
#container2 {
width: 500px;
height: 500px;
border: 3px solid pink;
}
#drag-dept-left {
min-width: 220px;
max-width: 35%;
}
.overview_scroll::-webkit-scrollbar {
width: 2px;
height: 1px;
background: rgba(6, 70, 122, 0.013);
}
.overview_scroll::-webkit-scrollbar-thumb {
border-radius: 4px;
margin-right: 5px;
-webkit-box-shadow: inset 0 0 0px #0090b411;
background: #03c1cf0e;
}
/**拖拽条样式 */
#drag-dept {
display: flex;
justify-content: center;
align-items: center;
position: relative;
top: 10;
right: 0;
width: 4px;
background-color: #04607c2a;
box-shadow: 0px 0px 1px rgba(0, 0, 0, 0.35);
cursor: col-resize;
}
#drag-dept i {
display: inline-block;
height: 14px;
width: 1px;
background-color: #e9e9e9;
margin: 0 1px;
}
.overview_scroll::-webkit-scrollbar {
width: 2px;
height: 1px;
background: rgba(6, 70, 122, 0.013);
}
::-webkit-scrollbar {
width: 5px;
height: 0px;
}
.el-tabs--border-card > .el-tabs__header {
background-color: #124da5;
border-bottom: 2px solid #e4e7ed;
margin: 0;
}
.el-tabs__header {
padding: 0;
position: relative;
margin: 0 px;
}
.el-tabs--border-card > .el-tabs__content {
padding: 0px;
}
.el-tabs__content {
overflow: hidden;
position: relative;
}
.el-aside,
.el-main {
margin-top: 0px;
}
.el-main {
padding-top: 0px;
padding-bottom: 0;
padding-right: 0;
}
::v-deep .boxDiv {
height: 25px;
line-height: 25px;
margin-left: 10px;
span:first-child {
font-weight: 600;
margin-right: 10px;
}
}
::v-deep .button {
margin-right: 5px;
background-color: $themeColor;
color: #fff;
height: 18px;
line-height: 18px;
border: 0 solid #000;
border-radius: 2px;
&:hover {
cursor: pointer;
}
}
.iconBox {
position: absolute;
top: 2px;
right: 2px;
width: 150px;
height: 260px;
padding: 10px;
z-index: 2000;
border-radius: 4px;
border: 1px solid #ccc;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12), 0 0 6px rgba(0, 0, 0, 0.04);
background: rgba(255, 255, 255, 0.75) !important;
.div {
display: flex;
margin-bottom: 5px;
img {
height: 20px;
margin-right: 5px;
}
// span {
// line-height: 20px;
// }
}
}
.boxTop {
position: absolute;
top: -48px;
left: 5px;
z-index: 2000;
}
::v-deep .el-select-dropdown__list {
display: flex;
flex-direction: column;
max-width: 240px;
}
.luckysheetBox {
position: absolute;
top: 0;
left: 0;
z-index: 1500;
// background-color: #000;
}
.anchorBL {
display: none !important;
}
::v-deep .el-select {
//width: 150px;
}
.flag {
position: absolute;
top: 10px;
right: 10px;
}
</style>
<template>
<el-container style="position: relative" id="dept">
<el-button type="primary" style="margin-top: -10px" class="flag" icon="el-icon-close" @click="$emit('close')">
返回
</el-button>
<el-main id="drag-dept-right ">
<div class="bm-view" id="container " :style="'height:' + (vh - 20) + 'px ;position: relative;'">
<div class="boxTop">
<el-form ref="form" :inline="true" :model="form">
<el-form-item label="模板:">
<el-select
value-key="id"
:popper-append-to-body="false"
v-model="form.TemplateId"
placeholder="请选择模板"
>
<el-option
v-for="item in options"
:key="item.id"
:label="item.name"
:value="item"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="报表类型:">
<el-select
v-model="form.TemplateId.reportForm"
:popper-append-to-body="false"
placeholder="请选择报表类型"
disabled
>
<el-option
v-for="item in reportFormList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item>
<Timeinterval ref="Timeinterval" :interval="3" />
</el-form-item>
<el-form-item>
<el-button
class="buttons"
size="small"
type="primary"
icon="el-icon-search"
@click="Template"
>
查询
</el-button>
<el-button
@click="downloadExcel"
class="buttons"
size="small"
type="primary"
icon="el-icon-download"
>
导出excel
</el-button>
</el-form-item>
</el-form>
</div>
<div
class="luckysheetBox"
style="padding: 0; margin: 0"
:style="`width:${vw - 50}px;height: ${vh - 200}px;`"
></div>
<div
id="luckysheet"
style="padding: 0; margin: 0"
:style="`width:${vw - 40}px;height: ${vh - 130}px;margin-top: 50px;`"
></div>
</div>
</el-main>
</el-container>
</template>
<script>
import jquery from 'jquery'
import { getCustomReport, getTemplateByDept } from '@/api/templateConfiguration'
import { exportExcel } from '@/views/components/luckyexcel/export'
import Timeinterval from '@/views/components/cgytree/TimeintervalTemplat.vue'
import TreeTemplat from '@/views/components/cgytree/TreeTemplat.vue'
import LuckyExcel from 'luckyexcel'
export default {
components: { TreeTemplat, Timeinterval },
props: {
reportID: {
type: String
}
},
data() {
return {
options: [],
zoom: '', //图表焦点校验
form: {
TemplateId: '',
reportForm: ''
},
reportFormList: [
{
value: '1',
label: '分析报表'
},
{
value: '2',
label: '统计报表'
},
{
value: '3',
label: '自定义报表'
}
],
loading: true,
vh: undefined,
vw: undefined,
view: true,
checkbox: false,
tablename: 1,
treenode: '',
statisticalList: {}, //树上面的选择框
data_info: [], //点位信息
map: null, //存储地图
flag: true,
showtoolbar: false, //富文本框头部显示
cellRightClickConfig: {
copy: false, // 复制
copyAs: false, // 复制为
paste: false, // 粘贴
insertRow: false, // 插入行
insertColumn: false, // 插入列
deleteRow: false, // 删除选中行
deleteColumn: false, // 删除选中列
deleteCell: false, // 删除单元格
hideRow: false, // 隐藏选中行和显示选中行
hideColumn: false, // 隐藏选中列和显示选中列
rowHeight: false, // 行高
columnWidth: false, // 列宽
clear: false, // 清除内容
matrix: false, // 矩阵操作选区
sort: false, // 排序选区
filter: false, // 筛选选区
chart: false, // 图表生成
image: false, // 插入图片
link: false, // 插入链接
data: false, // 数据验证
cellFormat: false // 设置单元格格式
}, //控制右键菜单
list: [
// {
// name: "Cell",
// index: 0,
// defaultRowHeight: 27,
// defaultColWidth: 105,
// },
],
deptId: ''
}
},
created() {},
mounted() {
this.deptId = JSON.parse(window.sessionStorage.getItem('Info')).deptId
this.zoom = 1 / document.body.style.zoom
this.$nextTick(() => {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.getTemplateLists()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
this.vh = window.sessionStorage.getItem('appheight')
this.vw = document.getElementById('app-main-in')?.offsetWidth
},
async getTemplateLists() {
await getTemplateByDept({ id: this.deptId }).then(res => {
if (res != undefined && res.code == 'A0000') {
res.data.forEach(item => {
if (item.activation == 1) {
this.form.TemplateId = item
return
}
})
this.options = res.data
setTimeout(() => {
this.Template()
}, 0)
}
})
},
// 选择模板
Template() {
// debugger
let _this = this
getCustomReport({
startTime: this.$refs.Timeinterval.timeValue[0],
endTime: this.$refs.Timeinterval.timeValue[1],
type: this.$refs.Timeinterval.intervald,
tempId: this.form.TemplateId.id,
activation: this.form.TemplateId.activation,
lineId: this.reportID
// lineId: "8696be1d170e05b7d848accc059f4558",
}).then(response => {
_this.list = response
_this.init()
// jquery.getJSON(res.data[1], null, function (list) {
// _this.list = list;
//_this.init();
// });
})
// .then((res) => {
// console.log("res", res.data);
// let Datalist = JSON.parse(res.data);
// console.log(`13323`, JSON.parse(res.data));
// this.list = Datalist;
// this.init();
// });
},
// 初始化插件
init() {
window.luckysheet.destroy()
let options = {
container: 'luckysheet', //luckysheet为容器id
title: '',
lang: 'zh',
showinfobar: false,
cellRightClickConfig: this.cellRightClickConfig,
showtoolbar: this.showtoolbar,
// column:8,
// row:7,
showtoolbarConfig: {
textRotateMode: false // '文本旋转方式'
},
data: this.list
}
// console.log(options);
luckysheet.create(options)
},
// 下载表格
downloadExcel() {
// const value = this.selected;;
exportExcel(luckysheet.getAllSheets(), '下载')
// testaaa();
}
},
computed: {},
watch: {}
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
</style>
<style lang="scss" scoped>
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
.wrap {
display: flex;
justify-content: space-around;
}
#container {
width: 100%;
height: 83vh;
border: 1px solid rgb(0, 183, 255);
}
#container2 {
width: 500px;
height: 500px;
border: 3px solid pink;
}
#drag-dept-left {
min-width: 220px;
max-width: 35%;
}
.overview_scroll::-webkit-scrollbar {
width: 2px;
height: 1px;
background: rgba(6, 70, 122, 0.013);
}
.overview_scroll::-webkit-scrollbar-thumb {
border-radius: 4px;
margin-right: 5px;
-webkit-box-shadow: inset 0 0 0px #0090b411;
background: #03c1cf0e;
}
/**拖拽条样式 */
#drag-dept {
display: flex;
justify-content: center;
align-items: center;
position: relative;
top: 10;
right: 0;
width: 4px;
background-color: #04607c2a;
box-shadow: 0px 0px 1px rgba(0, 0, 0, 0.35);
cursor: col-resize;
}
#drag-dept i {
display: inline-block;
height: 14px;
width: 1px;
background-color: #e9e9e9;
margin: 0 1px;
}
.overview_scroll::-webkit-scrollbar {
width: 2px;
height: 1px;
background: rgba(6, 70, 122, 0.013);
}
::-webkit-scrollbar {
width: 5px;
height: 0px;
}
.el-tabs--border-card > .el-tabs__header {
background-color: #124da5;
border-bottom: 2px solid #e4e7ed;
margin: 0;
}
.el-tabs__header {
padding: 0;
position: relative;
margin: 0 px;
}
.el-tabs--border-card > .el-tabs__content {
padding: 0px;
}
.el-tabs__content {
overflow: hidden;
position: relative;
}
.el-aside,
.el-main {
margin-top: 0px;
}
.el-main {
padding-top: 0px;
padding-bottom: 0;
padding-right: 0;
}
::v-deep .boxDiv {
height: 25px;
line-height: 25px;
margin-left: 10px;
span:first-child {
font-weight: 600;
margin-right: 10px;
}
}
::v-deep .button {
margin-right: 5px;
background-color: $themeColor;
color: #fff;
height: 18px;
line-height: 18px;
border: 0 solid #000;
border-radius: 2px;
&:hover {
cursor: pointer;
}
}
.iconBox {
position: absolute;
top: 2px;
right: 2px;
width: 150px;
height: 260px;
padding: 10px;
z-index: 2000;
border-radius: 4px;
border: 1px solid #ccc;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12), 0 0 6px rgba(0, 0, 0, 0.04);
background: rgba(255, 255, 255, 0.75) !important;
.div {
display: flex;
margin-bottom: 5px;
img {
height: 20px;
margin-right: 5px;
}
// span {
// line-height: 20px;
// }
}
}
.boxTop {
position: absolute;
top: -48px;
left: 5px;
z-index: 2000;
}
::v-deep .el-select-dropdown__list {
display: flex;
flex-direction: column;
max-width: 240px;
}
.luckysheetBox {
position: absolute;
top: 0;
left: 0;
z-index: 1500;
// background-color: #000;
}
.anchorBL {
display: none !important;
}
::v-deep .el-select {
//width: 150px;
}
.flag {
position: absolute;
top: 10px;
right: 10px;
}
</style>

View File

@@ -1,57 +1,57 @@
<template>
<div>
<!-- 台账 -->
<StandingBook v-show="flag && flags" @ViewReport="ViewReport" />
<!-- 报表 -->
<reportForm
v-if="!flag"
:reportID="reportID"
@close="
flag = true;
flags = true;
"
/>
<!-- 报告 -->
<SteadyStateReport
v-if="!flags"
:reportID="reportID"
@close="
flag = true;
flags = true;
"
/>
</div>
</template>
<script>
import SteadyStateReport from "./components/SteadyStateReport.vue";
import reportForm from "./components/reportForm";
import StandingBook from "./components/StandingBook";
export default {
components: { SteadyStateReport, reportForm, StandingBook },
props: {},
data() {
return {
flag: true,
flags: true,
reportID: "",
};
},
created() {},
methods: {
ViewReport(id, val) {
if (val == 0) {
this.flag = false;
} else {
this.flags = false;
}
this.reportID = id;
},
},
computed: {},
watch: {},
};
</script>
<style lang="scss" scoped></style>
<template>
<div>
<!-- 台账 -->
<StandingBook v-show="flag && flags" @ViewReport="ViewReport" />
<!-- 报表 -->
<reportForm
v-if="!flag"
:reportID="reportID"
@close="
flag = true;
flags = true;
"
/>
<!-- 报告 -->
<SteadyStateReport
v-if="!flags"
:reportID="reportID"
@close="
flag = true;
flags = true;
"
/>
</div>
</template>
<script>
import SteadyStateReport from "./components/SteadyStateReport.vue";
import reportForm from "./components/reportForm.vue";
import StandingBook from "./components/StandingBook.vue";
export default {
components: { SteadyStateReport, reportForm, StandingBook },
props: {},
data() {
return {
flag: true,
flags: true,
reportID: "",
};
},
created() {},
methods: {
ViewReport(id, val) {
if (val == 0) {
this.flag = false;
} else {
this.flags = false;
}
this.reportID = id;
},
},
computed: {},
watch: {},
};
</script>
<style lang="scss" scoped></style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -489,6 +489,7 @@ export default {
watch: {
//当前的树节点
currentNode2(newValue) {
console.log("🚀 ~ currentNode2 ~ newValue:", newValue)
this.treeMenuData = newValue
if (val) {
this.$nextTick(() => {

View File

@@ -43,14 +43,8 @@
></el-option>
</el-select>
</el-form-item>
<el-form-item label="CVT型号:" v-show="condition.includes('40')">
<!-- <el-cascader
v-model="cvt"
:options="cvtList"
:props="{ expandTrigger: 'hover' }"
clearable
filterable
></el-cascader> -->
<!-- <el-form-item label="CVT型号:" v-show="condition.includes('40')">
<el-select v-model="cvt" value-key="value" clearable filterable placeholder="请选择CVT型号">
<el-option
v-for="item in cvtList"
@@ -59,7 +53,7 @@
:value="item"
></el-option>
</el-select>
</el-form-item>
</el-form-item> -->
<el-form-item v-show="jxb" label="间谐波次数:">
<el-select v-model="formData.inHarmonic" placeholder="请选择间谐波">
<el-option

View File

@@ -12,15 +12,17 @@
执行日期:
<el-date-picker
v-model="time"
type="daterange"
type="datetimerange"
range-separator=""
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd HH:mm:ss"
format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
:clearable="false"
></el-date-picker>
</div>
<el-button type="primary" @click="handleClose"> </el-button>
<el-button type="primary" @click="execute"> </el-button>
</div>
<el-input placeholder="输入关键字检索" v-model="filterText" style="margin-bottom: 10px" clearable>
<i slot="prefix" class="el-input__icon el-icon-search"></i>
@@ -32,6 +34,7 @@
:show-checkbox="true"
:default-expanded-keys="expandID"
node-key="id"
:filter-node-method="filterNode"
:check-strictly="false"
:expand-on-click-node="true"
:highlight-current="true"
@@ -55,12 +58,14 @@
<script>
import api from '@/api/harmonic/onlineData'
import { dicData } from '@/assets/commjs/dictypeData'
import { measurementPointExecutorByHour } from '@/api/CVT/index.js'
export default {
components: {},
props: {},
data() {
return {
time: [new Date(), new Date()],
time: [],
// value1: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)],
dialogVisible: false,
checkedarr: [],
fiveData: [],
@@ -78,16 +83,23 @@ export default {
scale: null
},
filterText: '',
fiveData: []
fiveData: [],
fatherID: [],
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() - 8.64e6
// 或者return time.getTime() > Date.now();
}
}
}
},
created() {},
watch: {
filterText(val) {
this.$refs.menuTree.filter(val)
}
},
methods: {
handleFilter(val) {
this.$refs.menuTree.filter(val)
},
// 点击树节点
treeckeck(data, checked, indeterminate) {},
open() {
@@ -99,8 +111,23 @@ export default {
this.chuli()
}
})
// 获取年份
const year = new Date().getFullYear()
// 获取月份注意getMonth 返回值是 0 - 11所以要加 1并确保是两位数
const month = String(new Date().getMonth() + 1).padStart(2, '0')
// 获取日期,并确保是两位数
const day = String(new Date().getDate()).padStart(2, '0')
// 获取小时,并确保是两位数
const hours = String(new Date().getHours()).padStart(2, '0')
// 获取分钟,并确保是两位数
const minutes = String(new Date().getMinutes()).padStart(2, '0')
// 获取秒数,并确保是两位数
const seconds = String(new Date().getSeconds()).padStart(2, '0')
this.time = [`${year}-${month}-${day} 00:00:00`, `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`]
},
chuli() {
this.fatherID = []
var data = this.fiveData
var arr = []
data.forEach(item => {
@@ -127,8 +154,10 @@ export default {
if (arr[0].children[0].children[0].children.length > 0) {
arr.forEach(m => {
m.icon = 'el-icon-menu'
this.fatherID.push(m.id)
m.children.forEach(n => {
n.icon = 'el-icon-share'
this.fatherID.push(n.id)
n.children.forEach(d => {
d.icon = 'el-icon-s-flag'
d.children.forEach((f, i) => {
@@ -147,8 +176,10 @@ export default {
} else if (arr[0].children[0].children[0].children.length == 0) {
arr.forEach(m => {
m.icon = 'el-icon-menu'
this.fatherID.push(m.id)
m.children.forEach(n => {
n.icon = 'el-icon-share'
this.fatherID.push(n.id)
n.children.forEach((d, i) => {
d.icon = 'el-icon-warning'
d.name = i + 1 + '_' + d.name
@@ -168,9 +199,7 @@ export default {
window.sessionStorage.setItem('tree', this.tree)
this.expandID.push(this.currentNode)
this.$nextTick(() => {
this.$refs.menuTree.setCurrentKey(this.currentNode)
})
//初始化触发默认点击方法
//alert('初始1')
this.$emit('chushiData', this.currentNode, this.treeMenuData)
@@ -178,6 +207,7 @@ export default {
renderContent(h, { node, data, store }) {
this.onlinename = node.label
return (
<span style="flex: 1; display: flex; align-items: center; justify-content: space-between; padding-right: 8px;">
<span class="span-ellipsis">
@@ -190,11 +220,50 @@ export default {
</span>
)
},
// 执行算法
async execute() {
if (this.$refs.menuTree.getCheckedKeys().length == 0) return this.$message.error('请选择监测点!')
let data = {
beginTime: this.time[0],
dataDate: '',
endTime: this.time[1],
fullChain: false,
idList: this.$refs.menuTree.getCheckedKeys().filter(item => !this.fatherID.includes(item)),
repair: true,
tagNames: ['dataHarmRateVCvt']
}
await measurementPointExecutorByHour(data)
this.$message.success('算法执行成功!')
this.handleClose()
},
// 关闭弹窗
handleClose() {
console.log(this.time)
this.dialogVisible = false
this.$emit('close')
},
// 过滤树节点
filterNode(value, data, node) {
if (!value) {
return true
}
let _array = [] //这里使用数组存储 只是为了存储值。
this.getReturnNode(node, _array, value)
let result = false
_array.forEach(item => {
result = result || item
})
return result
},
getReturnNode(node, _array, value) {
let isPass = node.data && node.data.name && node.data.name.indexOf(value) !== -1
isPass ? _array.push(isPass) : ''
this.index++
if (!isPass && node.name != 1 && node.parent) {
this.getReturnNode(node.parent, _array, value)
}
}
},
mounted() {
@@ -207,8 +276,13 @@ export default {
},
computed: {},
watch: {
filterText(val) {
console.log('🚀 ~ filterText ~ val:', val)
watch: {}
this.$refs.menuTree.filter(val)
}
}
}
</script>
<style lang="less" scoped>
@@ -217,7 +291,7 @@ export default {
::v-deep .el-dialog .el-dialog__body {
padding: 20px !important;
}
.boxTop{
.boxTop {
display: flex;
justify-content: space-between;
}

View File

@@ -4,7 +4,6 @@
<muentree
@eleMenuData="getTreeText"
@chushiData="chushiData"
@ckeckData="ckeckData"
:checkbox="checkbox"
:number="number"
:tablename="tablename"
@@ -41,9 +40,8 @@
当前位置:
<span class="zt">{{ wezhiname }}</span>
</div>
</div>
<bindTab/>
<bindTab :clickData="clickData" ref="bindTabRef" />
</el-main>
</el-container>
</template>
@@ -83,10 +81,10 @@ export default {
view: true,
dataTree: [],
treenode: undefined,
linelist: [],
treedata: [],
deptIndex: '',
wezhiname: ''
wezhiname: '',
clickData: {}
}
},
created() {},
@@ -163,10 +161,11 @@ export default {
chushiData(id, data) {
this.id = id
window.sessionStorage.setItem('fist', id)
this.linelist.push(id)
this.treedata = data
this.wezhiname = data[0].name + '>' + data[0].children[0].name + '>' + data[0].children[0].children[0].name
this.clickData = data[0].children[0].children[0]
this.loading = false
this.$refs.bindTabRef.queryBind( this.clickData.id)
//alert(this.wezhiname)
},
//二次点击触发点击事件
@@ -174,21 +173,15 @@ export default {
if (treenode.data.level == 6) {
this.menudata = menudata
this.treenode = treenode
this.clickData = treenode.data
this.nodeCom = nodeCom
this.id = id
//this.wezhiname = name
this.linelist = []
this.linelist.push(id)
this.$refs.bindTabRef.queryBind(this.clickData.id)
} else {
return
}
},
ckeckData(checkedarr) {
this.linelist = []
//this.linelist = checkedarr
this.linelist = this.unique(checkedarr)
},
//去重
unique(arr) {
if (!Array.isArray(arr)) {

View File

@@ -1,48 +1,57 @@
<template>
<div v-loading="loading" element-loading-text="拼命加载中">
<el-form :inline="true" :model="form" class="demo-form-inline">
<el-form-item>
<!-- <el-form-item>
<timeindex :id="1" ref="fff" :interval="3"></timeindex>
</el-form-item>
</el-form-item> -->
<el-form-item label="筛选:" class="ml10">
<el-input v-model="form.search" placeholder="输入关键字搜索" style="width: 100%" />
<el-input v-model.trim="form.searchValue" placeholder="输入关键字搜索" style="width: 100%" clearable />
</el-form-item>
<el-form-item class="ml10">
<el-button type="primary" @click="querfromdata" icon="el-icon-search">查询</el-button>
<el-button type="primary" class="ml10" size="mini" icon="el-icon-plus">绑定</el-button>
<el-button type="primary" @click="handleBind" class="ml10" size="mini" icon="el-icon-sort">
绑定
</el-button>
</el-form-item>
</el-form>
<el-table
stripe
style="width: 100%"
:data="tables"
border
height="calc(100vh - 150px)"
header-cell-class-name="table_header"
highlight-current-row
>
<el-table-column type="selection" width="63" fixed="left"></el-table-column>
<el-table-column
v-for="item in column"
:key="item.prop"
:label="item.label"
align="center"
header-align="left"
:width="item.width"
:prop="item.prop"
<div style="height: calc(100vh - 150px)">
<vxe-table
:data="tables"
height="auto"
border
ref="tableRef"
stripe
:row-config="{ isCurrent: true, isHover: true }"
size="mini"
v-loading="isLoading"
style="width: 100%"
header-cell-class-name="table_header"
>
<el-table-column
v-for="k in item.children"
:key="k.prop"
:label="k.label"
<!-- <vxe-column type="radio" width="60"></vxe-column> -->
<vxe-column type="radio" width="65"></vxe-column>
<vxe-table-colgroup
align="center"
:width="k.width"
:prop="k.prop"
/>
</el-table-column>
</el-table>
v-for="(item, index) in column"
:field="item.prop"
:title="item.label"
:min-width="item.width"
show-overflow
:key="index"
>
<vxe-table-colgroup
align="center"
v-for="(item, index) in item.children"
:field="item.prop"
:title="item.label"
:min-width="item.width"
show-overflow
:key="index"
></vxe-table-colgroup>
</vxe-table-colgroup>
</vxe-table>
</div>
<!-- 新增修改 -->
<forms ref="formRef" />
@@ -66,358 +75,206 @@
import timeindex from '@/views/cgy-components/cgytree/TimeintervalTemplat.vue'
import forms from './forms.vue'
import algorithm from './algorithm.vue'
import { queryPage, cvtBind, queryByLineId } from '@/api/CVT/index.js'
export default {
components: { timeindex, forms, algorithm },
props: {},
props: {
clickData: {
type: Object
}
},
data() {
return {
loading: false,
form: {
currentPage: 1,
pageSize: 15,
search: ''
pageSize: 10000,
searchValue: ''
},
radioId: '',
isLoading: false,
spanArray: [], // 用于存储每个name字段合并的行数
position: 0, // 用于记录合并的位置
tables: [
{
name: '思源220kV-0.01W3',
model: 'C型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
{
name: '思源220kV-0.01W3',
model: 'C型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
{
name: '桂容220-0.01GH',
model: '三柱型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
{
name: '桂容220-0.01GH',
model: '三柱型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
}
],
tables: [],
column: [
{ label: 'CVT名称', prop: 'name', width: '200px' },
{ label: 'CVT型号', prop: 'model', width: '200px' },
{ label: 'CVT名称', prop: 'cvtName', width: '300px' },
{ label: 'CVT型号', prop: 'cvtModel', width: '300px' },
{
label: '谐波电压',
children: [
{ label: '2次', prop: 'num2' },
{ label: '3次', prop: 'num3' },
{ label: '4次', prop: 'num4' },
{ label: '5次', prop: 'num5' },
{ label: '6次', prop: 'num6' },
{ label: '7次', prop: 'num7' },
{ label: '8次', prop: 'num8' },
{ label: '9次', prop: 'num9' },
{ label: '10次', prop: 'num10' },
{ label: '11次', prop: 'num11' },
{ label: '12次', prop: 'num12' },
{ label: '13次', prop: 'num13' },
{ label: '14次', prop: 'num14' },
{ label: '15次', prop: 'num15' },
{ label: '16次', prop: 'num16' },
{ label: '17次', prop: 'num17' },
{ label: '18次', prop: 'num18' },
{ label: '19次', prop: 'num19' },
{ label: '20次', prop: 'num20' },
{ label: '21次', prop: 'num21' },
{ label: '22次', prop: 'num22' },
{ label: '23次', prop: 'num23' },
{ label: '24次', prop: 'num24' },
{ label: '25次', prop: 'num25' },
{ label: '26次', prop: 'num26' },
{ label: '27次', prop: 'num27' },
{ label: '28次', prop: 'num28' },
{ label: '29次', prop: 'num29' },
{ label: '30次', prop: 'num30' },
{ label: '31次', prop: 'num31' },
{ label: '32次', prop: 'num32' },
{ label: '33次', prop: 'num33' },
{ label: '34次', prop: 'num34' },
{ label: '35次', prop: 'num35' },
{ label: '36次', prop: 'num36' },
{ label: '37次', prop: 'num37' },
{ label: '38次', prop: 'num38' },
{ label: '39次', prop: 'num39' },
{ label: '40次', prop: 'num40' },
{ label: '41次', prop: 'num41' },
{ label: '42次', prop: 'num42' },
{ label: '43次', prop: 'num43' },
{ label: '44次', prop: 'num44' },
{ label: '45次', prop: 'num45' },
{ label: '46次', prop: 'num46' },
{ label: '47次', prop: 'num47' },
{ label: '48次', prop: 'num48' },
{ label: '49次', prop: 'num49' },
{ label: '50次', prop: 'num50' }
{ label: '2次', width: '80px', prop: 'h2' },
{ label: '3次', width: '80px', prop: 'h3' },
{ label: '4次', width: '80px', prop: 'h4' },
{ label: '5次', width: '80px', prop: 'h5' },
{ label: '6次', width: '80px', prop: 'h6' },
{ label: '7次', width: '80px', prop: 'h7' },
{ label: '8次', width: '80px', prop: 'h8' },
{ label: '9次', width: '80px', prop: 'h9' },
{ label: '10次', width: '80px', prop: 'h10' },
{ label: '11次', width: '80px', prop: 'h11' },
{ label: '12次', width: '80px', prop: 'h12' },
{ label: '13次', width: '80px', prop: 'h13' },
{ label: '14次', width: '80px', prop: 'h14' },
{ label: '15次', width: '80px', prop: 'h15' },
{ label: '16次', width: '80px', prop: 'h16' },
{ label: '17次', width: '80px', prop: 'h17' },
{ label: '18次', width: '80px', prop: 'h18' },
{ label: '19次', width: '80px', prop: 'h19' },
{ label: '20次', width: '80px', prop: 'h20' },
{ label: '21次', width: '80px', prop: 'h21' },
{ label: '22次', width: '80px', prop: 'h22' },
{ label: '23次', width: '80px', prop: 'h23' },
{ label: '24次', width: '80px', prop: 'h24' },
{ label: '25次', width: '80px', prop: 'h25' },
{ label: '26次', width: '80px', prop: 'h26' },
{ label: '27次', width: '80px', prop: 'h27' },
{ label: '28次', width: '80px', prop: 'h28' },
{ label: '29次', width: '80px', prop: 'h29' },
{ label: '30次', width: '80px', prop: 'h30' },
{ label: '31次', width: '80px', prop: 'h31' },
{ label: '32次', width: '80px', prop: 'h32' },
{ label: '33次', width: '80px', prop: 'h33' },
{ label: '34次', width: '80px', prop: 'h34' },
{ label: '35次', width: '80px', prop: 'h35' },
{ label: '36次', width: '80px', prop: 'h36' },
{ label: '37次', width: '80px', prop: 'h37' },
{ label: '38次', width: '80px', prop: 'h38' },
{ label: '39次', width: '80px', prop: 'h39' },
{ label: '40次', width: '80px', prop: 'h40' },
{ label: '41次', width: '80px', prop: 'h41' },
{ label: '42次', width: '80px', prop: 'h42' },
{ label: '43次', width: '80px', prop: 'h43' },
{ label: '44次', width: '80px', prop: 'h44' },
{ label: '45次', width: '80px', prop: 'h45' },
{ label: '46次', width: '80px', prop: 'h46' },
{ label: '47次', width: '80px', prop: 'h47' },
{ label: '48次', width: '80px', prop: 'h48' },
{ label: '49次', width: '80px', prop: 'h49' },
{ label: '50次', width: '80px', prop: 'h50' }
]
},
{ label: '新增时间', prop: 'addTime', width: '200px' },
{ label: '更新时间', prop: 'updatedTime', width: '200px' }
}
]
}
},
created() {},
methods: {
querfromdata() {},
handleSizeChange() {},
handleCurrentChange() {},
// 新增
handleAdd() {
this.$refs.formRef.title = '新增CVT系数'
this.$refs.formRef.dialogVisible = true
},
// 执行算法
handleAlgorithm() {
this.$refs.algorithmRef.open()
},
// 绑定监测点
handleBind(index, row) {
this.$refs.bindRef.open()
},
//编辑
handleEdit(index, row) {
this.$message({
message: '编辑',
type: 'success'
querfromdata() {
this.isLoading = true
queryPage(this.form).then(res => {
this.tables = res.data.records
this.tables.unshift({
cvtName: '默认',
cvtModel: '默认',
h2: 1,
h3: 1,
h4: 1,
h5: 1,
h6: 1,
h7: 1,
h8: 1,
h9: 1,
h10: 1,
h11: 1,
h12: 1,
h13: 1,
h14: 1,
h15: 1,
h16: 1,
h17: 1,
h18: 1,
h19: 1,
h20: 1,
h21: 1,
h22: 1,
h23: 1,
h24: 1,
h25: 1,
h26: 1,
h27: 1,
h28: 1,
h29: 1,
h30: 1,
h31: 1,
h32: 1,
h33: 1,
h34: 1,
h35: 1,
h36: 1,
h37: 1,
h38: 1,
h39: 1,
h40: 1,
h41: 1,
h42: 1,
h43: 1,
h44: 1,
h45: 1,
h46: 1,
h47: 1,
h48: 1,
h49: 1,
h50: 1,
id: ''
})
let data = this.tables.filter(item => item.id == this.radioId)
this.tables = this.tables.filter(item => {
// 将 a 和 b 属性的值转换为字符串,然后检查是否包含目标值转换后的字符串
return (
String(item.cvtName).includes(String(this.form.searchValue)) ||
String(item.cvtModel).includes(String(this.form.searchValue))
)
})
data.length > 0
? this.$refs.tableRef.setRadioRow(data[0])
: this.$refs.tableRef.setRadioRow(this.tables[0])
this.isLoading = false
}).catch(() => {
this.isLoading = false
})
},
//删除
handleDelete(index, row) {
this.$message({
message: '删除',
type: 'success'
clearRadioRowEvent() {
this.$refs.tableRef.clearRadioRow()
},
// 查询绑定的监cvt
queryBind(id) {
queryByLineId({ lineId: id }).then(res => {
this.radioId = res.data.id
this.querfromdata()
})
},
// 绑定监测点
handleBind() {
const currRow = this.$refs.tableRef.getRadioRecord()
cvtBind({ cvtId: currRow == null ? '' : currRow.id, lineId: this.clickData.id }).then(res => {
if (res.code == 'A0000') {
this.radioId = currRow == null ? null : currRow.id
this.$message.success('绑定成功!')
}
})
}
},
computed: {},
mounted() {},
watch: {
tables: {
handler() {
this.calculateSpan()
},
deep: true
}
mounted() {
// this.querfromdata()
}
}
</script>
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
::v-deep tr th:nth-child(4) {
div {
text-align: left !important;
}
div {
text-align: left !important;
}
}
::v-deep tr th:nth-child(1) {
div {
padding-left: 0px !important;
padding-right: 0px !important;
}
}
</style>

View File

@@ -1,11 +1,11 @@
<template>
<div v-loading="loading" element-loading-text="拼命加载中">
<el-form :inline="true" :model="form" class="demo-form-inline">
<el-form-item>
<!-- <el-form-item>
<timeindex :id="1" ref="fff" :interval="3"></timeindex>
</el-form-item>
</el-form-item> -->
<el-form-item label="筛选:" class="ml10">
<el-input v-model="form.search" placeholder="输入关键字搜索" style="width: 100%" />
<el-input v-model.trim="form.searchValue" clearable placeholder="输入关键字搜索" style="width: 100%" />
</el-form-item>
<el-form-item class="ml10">
@@ -14,60 +14,55 @@
<el-button type="primary" @click="handleAlgorithm" icon="el-icon-setting">执行算法</el-button>
</el-form-item>
</el-form>
<el-table
stripe
style="width: 100%"
:data="tables"
border
height="calc(100vh - 128px)"
header-cell-class-name="table_header"
highlight-current-row
>
<el-table-column
v-for="item in column"
:key="item.prop"
:label="item.label"
align="center"
header-align="left"
:width="item.width"
:prop="item.prop"
<div style="height: calc(100vh - 128px)">
<vxe-table
:data="tables"
height="auto"
border
stripe
:row-config="{ isCurrent: true, isHover: true }"
size="mini"
ref="classification"
style="width: 100%"
header-cell-class-name="table_header"
>
<el-table-column
v-for="k in item.children"
:key="k.prop"
:label="k.label"
<vxe-table-colgroup
align="center"
:width="k.width"
:prop="k.prop"
/>
</el-table-column>
<el-table-column label="操作" width="220" fixed="right" align="center">
<template slot-scope="scope">
<el-button
type="primary"
size="mini"
icon="el-icon-edit"
@click="handleEdit(scope.$index, scope.row)"
>
编辑
</el-button>
<el-button
type="danger"
size="mini"
icon="el-icon-delete"
@click="handleDelete(scope.$index, scope.row)"
>
删除
</el-button>
</template>
</el-table-column>
</el-table>
v-for="(item, index) in column"
:field="item.prop"
:title="item.label"
:min-width="item.width"
show-overflow
:key="index"
>
<vxe-table-colgroup
align="center"
v-for="(item, index) in item.children"
:field="item.prop"
:title="item.label"
:min-width="item.width"
show-overflow
:key="index"
></vxe-table-colgroup>
</vxe-table-colgroup>
<vxe-table-column align="center" title="操作" min-width="220px" fixed="right">
<template slot-scope="scope">
<el-button type="primary" size="mini" icon="el-icon-edit" @click="handleEdit(scope.row)">
编辑
</el-button>
<el-button type="danger" size="mini" icon="el-icon-delete" @click="handleDelete(scope.row)">
删除
</el-button>
</template>
</vxe-table-column>
</vxe-table>
</div>
<!-- 新增修改 -->
<forms ref="formRef" />
<forms ref="formRef" @querfromdata="querfromdata" @showForm="showForm = false" v-if="showForm" />
<!-- 执行算法 -->
<algorithm ref="algorithmRef" />
<algorithm ref="algorithmRef" v-if="showAlgorithm" @close="showAlgorithm = false" />
<!-- <el-pagination
background
align="right"
@@ -75,7 +70,7 @@
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:page-sizes="[15, 30, 50, 100]"
:current-page="form.currentPage"
:current-page="form.pageNum"
:page-size="form.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="this.tables.length"
@@ -85,6 +80,7 @@
<script>
import timeindex from '@/views/cgy-components/cgytree/TimeintervalTemplat.vue'
import forms from './forms.vue'
import { queryPage, deleteById } from '@/api/CVT/index.js'
import algorithm from './algorithm.vue'
export default {
components: { timeindex, forms, algorithm },
@@ -92,298 +88,150 @@ export default {
data() {
return {
loading: false,
showAlgorithm: false,
form: {
currentPage: 1,
pageSize: 15,
search: ''
pageNum: 1,
pageSize: 10000,
searchValue: ''
},
spanArray: [], // 用于存储每个name字段合并的行数
position: 0, // 用于记录合并的位置
tables: [
{
name: '思源220kV-0.01W3',
model: 'C型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
{
name: '思源220kV-0.01W3',
model: 'C型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
{
name: '桂容220-0.01GH',
model: '三柱型',
addTime: '2021-08-23 15:23:23',
updatedTime: '2021-08-23 15:23:23',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
},
],
showForm: false,
tables: [],
column: [
{ label: 'CVT名称', prop: 'name', width: '200px' },
{ label: 'CVT型号', prop: 'model', width: '200px' },
{ label: 'CVT名称', prop: 'cvtName', width: '300px' },
{ label: 'CVT型号', prop: 'cvtModel', width: '300px' },
{
label: '谐波电压',
children: [
{ label: '2次', prop: 'num2' },
{ label: '3次', prop: 'num3' },
{ label: '4次', prop: 'num4' },
{ label: '5次', prop: 'num5' },
{ label: '6次', prop: 'num6' },
{ label: '7次', prop: 'num7' },
{ label: '8次', prop: 'num8' },
{ label: '9次', prop: 'num9' },
{ label: '10次', prop: 'num10' },
{ label: '11次', prop: 'num11' },
{ label: '12次', prop: 'num12' },
{ label: '13次', prop: 'num13' },
{ label: '14次', prop: 'num14' },
{ label: '15次', prop: 'num15' },
{ label: '16次', prop: 'num16' },
{ label: '17次', prop: 'num17' },
{ label: '18次', prop: 'num18' },
{ label: '19次', prop: 'num19' },
{ label: '20次', prop: 'num20' },
{ label: '21次', prop: 'num21' },
{ label: '22次', prop: 'num22' },
{ label: '23次', prop: 'num23' },
{ label: '24次', prop: 'num24' },
{ label: '25次', prop: 'num25' },
{ label: '26次', prop: 'num26' },
{ label: '27次', prop: 'num27' },
{ label: '28次', prop: 'num28' },
{ label: '29次', prop: 'num29' },
{ label: '30次', prop: 'num30' },
{ label: '31次', prop: 'num31' },
{ label: '32次', prop: 'num32' },
{ label: '33次', prop: 'num33' },
{ label: '34次', prop: 'num34' },
{ label: '35次', prop: 'num35' },
{ label: '36次', prop: 'num36' },
{ label: '37次', prop: 'num37' },
{ label: '38次', prop: 'num38' },
{ label: '39次', prop: 'num39' },
{ label: '40次', prop: 'num40' },
{ label: '41次', prop: 'num41' },
{ label: '42次', prop: 'num42' },
{ label: '43次', prop: 'num43' },
{ label: '44次', prop: 'num44' },
{ label: '45次', prop: 'num45' },
{ label: '46次', prop: 'num46' },
{ label: '47次', prop: 'num47' },
{ label: '48次', prop: 'num48' },
{ label: '49次', prop: 'num49' },
{ label: '50次', prop: 'num50' }
{ label: '2次', width: '80px', prop: 'h2' },
{ label: '3次', width: '80px', prop: 'h3' },
{ label: '4次', width: '80px', prop: 'h4' },
{ label: '5次', width: '80px', prop: 'h5' },
{ label: '6次', width: '80px', prop: 'h6' },
{ label: '7次', width: '80px', prop: 'h7' },
{ label: '8次', width: '80px', prop: 'h8' },
{ label: '9次', width: '80px', prop: 'h9' },
{ label: '10次', width: '80px', prop: 'h10' },
{ label: '11次', width: '80px', prop: 'h11' },
{ label: '12次', width: '80px', prop: 'h12' },
{ label: '13次', width: '80px', prop: 'h13' },
{ label: '14次', width: '80px', prop: 'h14' },
{ label: '15次', width: '80px', prop: 'h15' },
{ label: '16次', width: '80px', prop: 'h16' },
{ label: '17次', width: '80px', prop: 'h17' },
{ label: '18次', width: '80px', prop: 'h18' },
{ label: '19次', width: '80px', prop: 'h19' },
{ label: '20次', width: '80px', prop: 'h20' },
{ label: '21次', width: '80px', prop: 'h21' },
{ label: '22次', width: '80px', prop: 'h22' },
{ label: '23次', width: '80px', prop: 'h23' },
{ label: '24次', width: '80px', prop: 'h24' },
{ label: '25次', width: '80px', prop: 'h25' },
{ label: '26次', width: '80px', prop: 'h26' },
{ label: '27次', width: '80px', prop: 'h27' },
{ label: '28次', width: '80px', prop: 'h28' },
{ label: '29次', width: '80px', prop: 'h29' },
{ label: '30次', width: '80px', prop: 'h30' },
{ label: '31次', width: '80px', prop: 'h31' },
{ label: '32次', width: '80px', prop: 'h32' },
{ label: '33次', width: '80px', prop: 'h33' },
{ label: '34次', width: '80px', prop: 'h34' },
{ label: '35次', width: '80px', prop: 'h35' },
{ label: '36次', width: '80px', prop: 'h36' },
{ label: '37次', width: '80px', prop: 'h37' },
{ label: '38次', width: '80px', prop: 'h38' },
{ label: '39次', width: '80px', prop: 'h39' },
{ label: '40次', width: '80px', prop: 'h40' },
{ label: '41次', width: '80px', prop: 'h41' },
{ label: '42次', width: '80px', prop: 'h42' },
{ label: '43次', width: '80px', prop: 'h43' },
{ label: '44次', width: '80px', prop: 'h44' },
{ label: '45次', width: '80px', prop: 'h45' },
{ label: '46次', width: '80px', prop: 'h46' },
{ label: '47次', width: '80px', prop: 'h47' },
{ label: '48次', width: '80px', prop: 'h48' },
{ label: '49次', width: '80px', prop: 'h49' },
{ label: '50次', width: '80px', prop: 'h50' }
]
},
{ label: '新时间', prop: 'addTime', width: '200px' },
{ label: '更新时间', prop: 'updatedTime', width: '200px' }
{ label: '新增时间', prop: 'createTime', width: '200px' },
{ label: '新时间', prop: 'updateTime', width: '200px' }
]
}
},
created() {},
methods: {
querfromdata() {},
//查询
querfromdata() {
this.showForm = false
this.loading = true
queryPage(this.form).then(res => {
this.tables = res.data.records
this.loading = false
})
},
handleSizeChange() {},
handleCurrentChange() {},
// 新增
handleAdd() {
this.$refs.formRef.title = '新增CVT系数'
this.$refs.formRef.dialogVisible = true
this.showForm = true
setTimeout(() => {
this.$refs.formRef.title = '新增CVT系数'
this.$refs.formRef.dialogVisible = true
}, 0)
},
// 执行算法
handleAlgorithm() {
this.$refs.algorithmRef.open()
this.showAlgorithm = true
setTimeout(() => {
this.$refs.algorithmRef.open()
}, 100)
},
// 绑定监测点
handleBind(index, row) {
this.$refs.bindRef.open()
},
//编辑
handleEdit(index, row) {
this.$message({
message: '编辑',
type: 'success'
})
handleEdit(row) {
this.showForm = true
setTimeout(() => {
this.$refs.formRef.doEdit(row)
this.$refs.formRef.title = '修改CVT系数'
this.$refs.formRef.dialogVisible = true
}, 0)
},
//删除
handleDelete(index, row) {
this.$message({
message: '删除',
type: 'success'
handleDelete(row) {
this.$confirm('请确认是否删除?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteById({ id: row.id }).then(res => {
if (res.code == 'A0000') {
this.$message({
type: 'success',
message: '删除成功!'
})
this.querfromdata()
}
})
})
}
},
computed: {},
mounted() {},
watch: {
tables: {
handler() {
this.calculateSpan()
},
deep: true
}
mounted() {
this.querfromdata()
}
}
</script>
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
::v-deep tr th:nth-child(3) {
div {
text-align: left !important;
}
div {
text-align: left !important;
}
}
</style>

View File

@@ -7,270 +7,386 @@
width="1000px"
:before-close="handleClose"
>
<el-form ref="form" :inline="true" :model="form" label-width="80px" class="form-two">
<el-form-item label="CVT名称:">
<el-input v-model="form.name" placeholder="请输入CVT名称"></el-input>
<el-form ref="form" :inline="true" :model="form" label-width="auto" :rules="rules" class="form">
<el-form-item label="CVT名称:" prop="cvtName" style="width: 49%">
<el-input v-model.trim="form.cvtName" placeholder="请输入CVT名称" />
</el-form-item>
<el-form-item label="CVT型号:">
<el-input v-model="form.model" placeholder="请输入CVT型号"></el-input>
<el-form-item label="CVT型号:" prop="cvtModel" style="width: 49%">
<el-input v-model.trim="form.cvtModel" placeholder="请输入CVT型号" />
</el-form-item>
</el-form>
<el-form ref="form" :inline="true" :model="form" label-width="80px" class="form">
<el-form-item label="2次:">
<el-input type="number" v-model="form.num2"></el-input>
<el-form-item v-for="item in frequency" :label="`${item}次:`" :prop="`h${item}`">
<el-input type="number" v-model.trim="form[`h${item}`]" @input="handleInput($event, `h${item}`)" />
</el-form-item>
<el-form-item label="3次:">
<el-input type="number" v-model="form.num3"></el-input>
<!-- <el-form-item label="2次:" prop="h2">
<el-input type="number" v-model="form.h2" @input="handleInput($event,'h2')"/>
</el-form-item>
<el-form-item label="4次:">
<el-input type="number" v-model="form.num4"></el-input>
<el-form-item label="3次:" prop="h3">
<el-input type="number" v-model="form.h3" @input="handleInput($event,'h3')"/>
</el-form-item>
<el-form-item label="5次:">
<el-input type="number" v-model="form.num5"></el-input>
<el-form-item label="4次:" prop="h4">
<el-input type="number" v-model="form.h4" @input="handleInput($event,'h4')"/>
</el-form-item>
<el-form-item label="6次:">
<el-input type="number" v-model="form.num6"></el-input>
<el-form-item label="5次:" prop="h5">
<el-input type="number" v-model="form.h5" @input="handleInput($event,'h5')"/>
</el-form-item>
<el-form-item label="7次:">
<el-input type="number" v-model="form.num7"></el-input>
<el-form-item label="6次:" prop="h6">
<el-input type="number" v-model="form.h6" @input="handleInput($event,'h6')"/>
</el-form-item>
<el-form-item label="8次:">
<el-input type="number" v-model="form.num8"></el-input>
<el-form-item label="7次:" prop="h7">
<el-input type="number" v-model="form.h7" @input="handleInput($event,'h7')"/>
</el-form-item>
<el-form-item label="9次:">
<el-input type="number" v-model="form.num9"></el-input>
<el-form-item label="8次:" prop="h8">
<el-input type="number" v-model="form.h8" @input="handleInput($event,'h8')"/>
</el-form-item>
<el-form-item label="10次:">
<el-input type="number" v-model="form.num10"></el-input>
<el-form-item label="9次:" prop="h9">
<el-input type="number" v-model="form.h9" @input="handleInput($event,'h9')"/>
</el-form-item>
<el-form-item label="11次:">
<el-input type="number" v-model="form.num11"></el-input>
<el-form-item label="10次:" prop="h10">
<el-input type="number" v-model="form.h10" @input="handleInput($event,'h10')"/>
</el-form-item>
<el-form-item label="12次:">
<el-input type="number" v-model="form.num12"></el-input>
<el-form-item label="11次:" prop="h11">
<el-input type="number" v-model="form.h11" @input="handleInput($event,'h11')"/>
</el-form-item>
<el-form-item label="13次:">
<el-input type="number" v-model="form.num13"></el-input>
<el-form-item label="12次:" prop="h12">
<el-input type="number" v-model="form.h12" @input="handleInput($event,'h12')"/>
</el-form-item>
<el-form-item label="14次:">
<el-input type="number" v-model="form.num14"></el-input>
<el-form-item label="13次:" prop="h13">
<el-input type="number" v-model="form.h13" @input="handleInput($event,'h13')"/>
</el-form-item>
<el-form-item label="15次:">
<el-input type="number" v-model="form.num15"></el-input>
<el-form-item label="14次:" prop="h14">
<el-input type="number" v-model="form.h14" @input="handleInput($event,'h14')"/>
</el-form-item>
<el-form-item label="16次:">
<el-input type="number" v-model="form.num16"></el-input>
<el-form-item label="15次:" prop="h15">
<el-input type="number" v-model="form.h15" @input="handleInput($event,'h15')"/>
</el-form-item>
<el-form-item label="17次:">
<el-input type="number" v-model="form.num17"></el-input>
<el-form-item label="16次:" prop="h16">
<el-input type="number" v-model="form.h16" @input="handleInput($event,'h16')"/>
</el-form-item>
<el-form-item label="18次:">
<el-input type="number" v-model="form.num18"></el-input>
<el-form-item label="17次:" prop="h17">
<el-input type="number" v-model="form.h17" @input="handleInput($event,'h17')"/>
</el-form-item>
<el-form-item label="19次:">
<el-input type="number" v-model="form.num19"></el-input>
<el-form-item label="18次:" prop="h18">
<el-input type="number" v-model="form.h18" @input="handleInput($event,'h18')"/>
</el-form-item>
<el-form-item label="20次:">
<el-input type="number" v-model="form.num20"></el-input>
<el-form-item label="19次:" prop="h19">
<el-input type="number" v-model="form.h19" @input="handleInput($event,'h19')"/>
</el-form-item>
<el-form-item label="21次:">
<el-input type="number" v-model="form.num21"></el-input>
<el-form-item label="20次:" prop="h20">
<el-input type="number" v-model="form.h20" @input="handleInput($event,'h20')"/>
</el-form-item>
<el-form-item label="22次:">
<el-input type="number" v-model="form.num22"></el-input>
<el-form-item label="21次:" prop="h21">
<el-input type="number" v-model="form.h21" @input="handleInput($event,'h21')"/>
</el-form-item>
<el-form-item label="23次:">
<el-input type="number" v-model="form.num23"></el-input>
<el-form-item label="22次:" prop="h22">
<el-input type="number" v-model="form.h22" @input="handleInput($event,'h22')"/>
</el-form-item>
<el-form-item label="24次:">
<el-input type="number" v-model="form.num24"></el-input>
<el-form-item label="23次:" prop="h23">
<el-input type="number" v-model="form.h23" @input="handleInput($event,'h23')"/>
</el-form-item>
<el-form-item label="25次:">
<el-input type="number" v-model="form.num25"></el-input>
<el-form-item label="24次:" prop="h24">
<el-input type="number" v-model="form.h24" @input="handleInput($event,'h24')"/>
</el-form-item>
<el-form-item label="26次:">
<el-input type="number" v-model="form.num26"></el-input>
<el-form-item label="25次:" prop="h25">
<el-input type="number" v-model="form.h25" @input="handleInput($event,'h25')"/>
</el-form-item>
<el-form-item label="27次:">
<el-input type="number" v-model="form.num27"></el-input>
<el-form-item label="26次:" prop="h26">
<el-input type="number" v-model="form.h26" @input="handleInput($event,'h26')"/>
</el-form-item>
<el-form-item label="28次:">
<el-input type="number" v-model="form.num28"></el-input>
<el-form-item label="27次:" prop="h27">
<el-input type="number" v-model="form.h27" @input="handleInput($event,'h27')"/>
</el-form-item>
<el-form-item label="29次:">
<el-input type="number" v-model="form.num29"></el-input>
<el-form-item label="28次:" prop="h28">
<el-input type="number" v-model="form.h28" @input="handleInput($event,'h28')"/>
</el-form-item>
<el-form-item label="30次:">
<el-input type="number" v-model="form.num30"></el-input>
<el-form-item label="29次:" prop="h29">
<el-input type="number" v-model="form.h29" @input="handleInput($event,'h29')"/>
</el-form-item>
<el-form-item label="31次:">
<el-input type="number" v-model="form.num31"></el-input>
<el-form-item label="30次:" prop="h30">
<el-input type="number" v-model="form.h30" @input="handleInput($event,'h30')"/>
</el-form-item>
<el-form-item label="32次:">
<el-input type="number" v-model="form.num32"></el-input>
<el-form-item label="31次:" prop="h31">
<el-input type="number" v-model="form.h31" @input="handleInput($event,'h31')"/>
</el-form-item>
<el-form-item label="33次:">
<el-input type="number" v-model="form.num33"></el-input>
<el-form-item label="32次:" prop="h32">
<el-input type="number" v-model="form.h32" @input="handleInput($event,'h32')"/>
</el-form-item>
<el-form-item label="34次:">
<el-input type="number" v-model="form.num34"></el-input>
<el-form-item label="33次:" prop="h33">
<el-input type="number" v-model="form.h33" @input="handleInput($event,'h33')"/>
</el-form-item>
<el-form-item label="35次:">
<el-input type="number" v-model="form.num35"></el-input>
<el-form-item label="34次:" prop="h34">
<el-input type="number" v-model="form.h34" @input="handleInput($event,'h34')"/>
</el-form-item>
<el-form-item label="36次:">
<el-input type="number" v-model="form.num36"></el-input>
<el-form-item label="35次:" prop="h35">
<el-input type="number" v-model="form.h35" @input="handleInput($event,'h35')"/>
</el-form-item>
<el-form-item label="37次:">
<el-input type="number" v-model="form.num37"></el-input>
<el-form-item label="36次:" prop="h36">
<el-input type="number" v-model="form.h36" @input="handleInput($event,'h36')"/>
</el-form-item>
<el-form-item label="38次:">
<el-input type="number" v-model="form.num38"></el-input>
<el-form-item label="37次:" prop="h37">
<el-input type="number" v-model="form.h37" @input="handleInput($event,'h37')"/>
</el-form-item>
<el-form-item label="39次:">
<el-input type="number" v-model="form.num39"></el-input>
<el-form-item label="38次:" prop="h38">
<el-input type="number" v-model="form.h38" @input="handleInput($event,'h38')"/>
</el-form-item>
<el-form-item label="40次:">
<el-input type="number" v-model="form.num40"></el-input>
<el-form-item label="39次:" prop="h39">
<el-input type="number" v-model="form.h39" @input="handleInput($event,'h39')"/>
</el-form-item>
<el-form-item label="41次:">
<el-input type="number" v-model="form.num41"></el-input>
<el-form-item label="40次:" prop="h40">
<el-input type="number" v-model="form.h40" @input="handleInput($event,'h40')"/>
</el-form-item>
<el-form-item label="42次:">
<el-input type="number" v-model="form.num42"></el-input>
<el-form-item label="41次:" prop="h41">
<el-input type="number" v-model="form.h41" @input="handleInput($event,'h41')"/>
</el-form-item>
<el-form-item label="43次:">
<el-input type="number" v-model="form.num43"></el-input>
<el-form-item label="42次:" prop="h42">
<el-input type="number" v-model="form.h42" @input="handleInput($event,'h42')"/>
</el-form-item>
<el-form-item label="44次:">
<el-input type="number" v-model="form.num44"></el-input>
<el-form-item label="43次:" prop="h43">
<el-input type="number" v-model="form.h43" @input="handleInput($event,'h43')"/>
</el-form-item>
<el-form-item label="45次:">
<el-input type="number" v-model="form.num45"></el-input>
<el-form-item label="44次:" prop="h44">
<el-input type="number" v-model="form.h44" @input="handleInput($event,'h44')"/>
</el-form-item>
<el-form-item label="46次:">
<el-input type="number" v-model="form.num46"></el-input>
<el-form-item label="45次:" prop="h45">
<el-input type="number" v-model="form.h45" @input="handleInput($event,'h45')"/>
</el-form-item>
<el-form-item label="47次:">
<el-input type="number" v-model="form.num47"></el-input>
<el-form-item label="46次:" prop="h46">
<el-input type="number" v-model="form.h46" @input="handleInput($event,'h46')"/>
</el-form-item>
<el-form-item label="48次:">
<el-input type="number" v-model="form.num48"></el-input>
<el-form-item label="47次:" prop="h47">
<el-input type="number" v-model="form.h47" @input="handleInput($event,'h47')"/>
</el-form-item>
<el-form-item label="49次:">
<el-input type="number" v-model="form.num49"></el-input>
<el-form-item label="48次:" prop="h48">
<el-input type="number" v-model="form.h48" @input="handleInput($event,'h48')"/>
</el-form-item>
<el-form-item label="50次:">
<el-input type="number" v-model="form.num50"></el-input>
<el-form-item label="49次:" prop="h49">
<el-input type="number" v-model="form.h49" @input="handleInput($event,'h49')"/>
</el-form-item>
<el-form-item label="50次:" prop="h50">
<el-input type="number" v-model="form.h50" @input="handleInput($event,'h50')"/>
</el-form-item> -->
</el-form>
<span slot="footer" class="dialog-footer">
<el-button @click="handleClose"> </el-button>
<el-button type="primary" @click="handleClose"> </el-button>
<el-button type="primary" @click="submit"> </el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { addCVT, updateCvt } from '@/api/CVT/index.js'
export default {
components: {},
props: {},
data() {
return {
frequency: [
2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50
],
dialogVisible: false,
title: '',
form: {
name: '',
model: '',
num2: '1',
num3: '1',
num4: '1',
num5: '1',
num6: '1',
num7: '1',
num8: '1',
num9: '1',
num10: '1',
num11: '1',
num12: '1',
num13: '1',
num14: '1',
num15: '1',
num16: '1',
num17: '1',
num18: '1',
num19: '1',
num20: '1',
num21: '1',
num22: '1',
num23: '1',
num24: '1',
num25: '1',
num26: '1',
num27: '1',
num28: '1',
num29: '1',
num30: '1',
num31: '1',
num32: '1',
num33: '1',
num34: '1',
num35: '1',
num36: '1',
num37: '1',
num38: '1',
num39: '1',
num40: '1',
num41: '1',
num42: '1',
num43: '1',
num44: '1',
num45: '1',
num46: '1',
num47: '1',
num48: '1',
num49: '1',
num50: '1'
cvtName: '',
cvtModel: '',
h2: '1',
h3: '1',
h4: '1',
h5: '1',
h6: '1',
h7: '1',
h8: '1',
h9: '1',
h10: '1',
h11: '1',
h12: '1',
h13: '1',
h14: '1',
h15: '1',
h16: '1',
h17: '1',
h18: '1',
h19: '1',
h20: '1',
h21: '1',
h22: '1',
h23: '1',
h24: '1',
h25: '1',
h26: '1',
h27: '1',
h28: '1',
h29: '1',
h30: '1',
h31: '1',
h32: '1',
h33: '1',
h34: '1',
h35: '1',
h36: '1',
h37: '1',
h38: '1',
h39: '1',
h40: '1',
h41: '1',
h42: '1',
h43: '1',
h44: '1',
h45: '1',
h46: '1',
h47: '1',
h48: '1',
h49: '1',
h50: '1'
},
rules: {
cvtName: [{ required: true, message: 'CVT名称不能为空', trigger: 'blur' }],
cvtModel: [{ required: true, message: 'CVT型号不能为空', trigger: 'blur' }],
h2: [{ required: true, message: '2次不能为空', trigger: 'blur' }],
h3: [{ required: true, message: '3次不能为空', trigger: 'blur' }],
h4: [{ required: true, message: '4次不能为空', trigger: 'blur' }],
h5: [{ required: true, message: '5次不能为空', trigger: 'blur' }],
h6: [{ required: true, message: '6次不能为空', trigger: 'blur' }],
h7: [{ required: true, message: '7次不能为空', trigger: 'blur' }],
h8: [{ required: true, message: '8次不能为空', trigger: 'blur' }],
h9: [{ required: true, message: '9次不能为空', trigger: 'blur' }],
h10: [{ required: true, message: '10次不能为空', trigger: 'blur' }],
h11: [{ required: true, message: '11次不能为空', trigger: 'blur' }],
h12: [{ required: true, message: '12次不能为空', trigger: 'blur' }],
h13: [{ required: true, message: '13次不能为空', trigger: 'blur' }],
h14: [{ required: true, message: '14次不能为空', trigger: 'blur' }],
h15: [{ required: true, message: '15次不能为空', trigger: 'blur' }],
h16: [{ required: true, message: '16次不能为空', trigger: 'blur' }],
h17: [{ required: true, message: '17次不能为空', trigger: 'blur' }],
h18: [{ required: true, message: '18次不能为空', trigger: 'blur' }],
h19: [{ required: true, message: '19次不能为空', trigger: 'blur' }],
h20: [{ required: true, message: '20次不能为空', trigger: 'blur' }],
h21: [{ required: true, message: '21次不能为空', trigger: 'blur' }],
h22: [{ required: true, message: '22次不能为空', trigger: 'blur' }],
h23: [{ required: true, message: '23次不能为空', trigger: 'blur' }],
h24: [{ required: true, message: '24次不能为空', trigger: 'blur' }],
h25: [{ required: true, message: '25次不能为空', trigger: 'blur' }],
h26: [{ required: true, message: '26次不能为空', trigger: 'blur' }],
h27: [{ required: true, message: '27次不能为空', trigger: 'blur' }],
h28: [{ required: true, message: '28次不能为空', trigger: 'blur' }],
h29: [{ required: true, message: '29次不能为空', trigger: 'blur' }],
h30: [{ required: true, message: '30次不能为空', trigger: 'blur' }],
h31: [{ required: true, message: '31次不能为空', trigger: 'blur' }],
h32: [{ required: true, message: '32次不能为空', trigger: 'blur' }],
h33: [{ required: true, message: '33次不能为空', trigger: 'blur' }],
h34: [{ required: true, message: '34次不能为空', trigger: 'blur' }],
h35: [{ required: true, message: '35次不能为空', trigger: 'blur' }],
h36: [{ required: true, message: '36次不能为空', trigger: 'blur' }],
h37: [{ required: true, message: '37次不能为空', trigger: 'blur' }],
h38: [{ required: true, message: '38次不能为空', trigger: 'blur' }],
h39: [{ required: true, message: '39次不能为空', trigger: 'blur' }],
h40: [{ required: true, message: '40次不能为空', trigger: 'blur' }],
h41: [{ required: true, message: '41次不能为空', trigger: 'blur' }],
h42: [{ required: true, message: '42次不能为空', trigger: 'blur' }],
h43: [{ required: true, message: '43次不能为空', trigger: 'blur' }],
h44: [{ required: true, message: '44次不能为空', trigger: 'blur' }],
h45: [{ required: true, message: '45次不能为空', trigger: 'blur' }],
h46: [{ required: true, message: '46次不能为空', trigger: 'blur' }],
h47: [{ required: true, message: '47次不能为空', trigger: 'blur' }],
h48: [{ required: true, message: '48次不能为空', trigger: 'blur' }],
h49: [{ required: true, message: '49次不能为空', trigger: 'blur' }],
h50: [{ required: true, message: '50次不能为空', trigger: 'blur' }]
}
}
},
created() {},
methods: {
// 提交
submit() {
this.$refs.form.validate(valid => {
if (valid) {
if (this.title == '新增CVT系数') {
addCVT(this.form).then(res => {
if (res.code == 'A0000') {
this.$emit('querfromdata')
this.$message({
type: 'success',
message: '新增成功!'
})
this.handleClose()
}
})
} else {
updateCvt(this.form).then(res => {
if (res.code == 'A0000') {
this.$emit('querfromdata')
this.$message({
type: 'success',
message: '修改成功!'
})
this.handleClose()
}
})
}
}
})
},
// 关闭弹窗
handleClose() {
this.dialogVisible = false
this.$refs.form.resetFields()
this.$emit('showForm')
},
// 修改
doEdit(row) {
this.form = JSON.parse(JSON.stringify(row))
},
handleInput(value, key) {
// 正则表达式,用于匹配最多保留 3 位小数的数字
const reg = /^\d*(\.\d{0,3})?$/
if (!reg.test(value)) {
// 若输入不符合要求,去除多余的小数部分
const parts = value.toString().split('.')
if (parts.length > 1) {
this.form[key] = `${parts[0]}.${parts[1].slice(0, 3)}`
} else {
this.form[key] = parts[0]
}
}
}
},
computed: {},
mounted() {
// let data = []
// for (let i = 2; i < 51; i++) {
// this.form[`h${i}`] = data[i - 2]
// }
// this.form.cvtName = '日新500-5H9.79kv中间变)'
// this.form.cvtModel = this.form.cvtName
},
watch: {}
}
</script>
<style lang="less" scoped>
@import url('../../../../styles/comStyle.less');
::v-deep .form-two {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
.el-form-item {
display: flex;
width: 49%;
.el-form-item__content {
flex: 1 !important;
.el-select {
width: 100%;
}
.el-input__inner {
width: 100% !important;
}
.el-date-editor {
width: 100%;
}
}
}
}
// ::v-deep .form-two {
// display: flex;
// flex-wrap: wrap;
// justify-content: space-between;
// .el-form-item {
// display: flex;
// width: 49%;
// .el-form-item__content {
// flex: 1 !important;
// .el-select {
// width: 100%;
// }
// .el-input__inner {
// width: 100% !important;
// }
// .el-date-editor {
// width: 100%;
// }
// }
// }
// }
::v-deep .form {
display: flex;
flex-wrap: wrap;
@@ -278,6 +394,7 @@ export default {
.el-form-item {
display: flex;
width: 24%;
margin-bottom: 18px !important;
.el-form-item__content {
flex: 1 !important;
.el-select {

View File

@@ -2,10 +2,10 @@
<div class="pa10">
<el-tabs type="border-card" style="height: calc(100vh - 20px)" v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="CVT台账" name="1">
<cvt></cvt>
<cvt v-if="activeName == '1'"></cvt>
</el-tab-pane>
<el-tab-pane label="数据绑定" name="2">
<bind></bind>
<el-tab-pane label="台账绑定" name="2">
<bind v-if="activeName == '2'"></bind>
</el-tab-pane>
</el-tabs>
</div>
@@ -25,7 +25,9 @@ export default {
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
}
},
mounted() {},

View File

@@ -335,7 +335,9 @@ export default {
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
}
this.getIndexType()
//this.time()
@@ -542,19 +544,8 @@ export default {
month = '0' + month
}
this.form.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.form.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.form.searchEndTime = str2[0] + '-' + month + '-30'
}
this.form.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.form.searchBeginTime = this.$refs.fff.timeValue[0]
this.form.searchEndTime = this.$refs.fff.timeValue[1]
@@ -938,7 +929,7 @@ export default {
myChart2.clear(option)
myChart2.setOption(option)
window.echartsArr.push(myChart2)
window.echartsArr.push(myChart2)
setTimeout(function () {
myChart2.resize()
}, 0)
@@ -976,19 +967,8 @@ window.echartsArr.push(myChart2)
month = '0' + month
}
this.form.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.form.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.form.searchEndTime = str2[0] + '-' + month + '-30'
}
this.form.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.form.searchBeginTime = this.$refs.fff.timeValue[0]
this.form.searchEndTime = this.$refs.fff.timeValue[1]
@@ -1320,7 +1300,7 @@ window.echartsArr.push(myChart2)
]
}
option && myChart2.setOption(option, true)
window.echartsArr.push(myChart2)
window.echartsArr.push(myChart2)
setTimeout(function () {
myChart2.resize()
}, 0)
@@ -1349,19 +1329,8 @@ window.echartsArr.push(myChart2)
month = '0' + month
}
this.form.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.form.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.form.searchEndTime = str2[0] + '-' + month + '-30'
}
this.form.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.form.searchBeginTime = this.$refs.fff.timeValue[0]
this.form.searchEndTime = this.$refs.fff.timeValue[1]
@@ -1545,7 +1514,7 @@ window.echartsArr.push(myChart2)
}
option && myChart2.setOption(option, true)
window.echartsArr.push(myChart2)
window.echartsArr.push(myChart2)
setTimeout(function () {
myChart2.resize()
}, 0)
@@ -1571,19 +1540,8 @@ window.echartsArr.push(myChart2)
month = '0' + month
}
this.form.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.form.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.form.searchEndTime = str2[0] + '-' + month + '-30'
}
this.form.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.form.searchBeginTime = this.$refs.fff.timeValue[0]
this.form.searchEndTime = this.$refs.fff.timeValue[1]
@@ -1768,7 +1726,7 @@ window.echartsArr.push(myChart2)
}
option && myChart2.setOption(option, true)
window.echartsArr.push(myChart2)
window.echartsArr.push(myChart2)
setTimeout(function () {
myChart2.resize()
}, 0)
@@ -1796,19 +1754,8 @@ window.echartsArr.push(myChart2)
month = '0' + month
}
this.form.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.form.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.form.searchEndTime = str2[0] + '-' + month + '-30'
}
this.form.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.form.searchBeginTime = this.$refs.fff.timeValue[0]
this.form.searchEndTime = this.$refs.fff.timeValue[1]
@@ -2030,7 +1977,7 @@ window.echartsArr.push(myChart2)
]
}
option && myChart2.setOption(option, true)
window.echartsArr.push(myChart2)
window.echartsArr.push(myChart2)
setTimeout(function () {
myChart2.resize()
}, 0)

File diff suppressed because it is too large Load Diff

View File

@@ -805,19 +805,9 @@ export default {
month = '0' + month
}
this.formData.searchBeginTime = str1[0] + '-' + month + '-' + str1[2]
if (
month == 1 ||
month == 3 ||
month == 5 ||
month == 7 ||
month == 8 ||
month == 10 ||
month == 12
) {
this.formData.searchEndTime = str2[0] + '-' + month + '-31'
} else {
this.formData.searchEndTime = str2[0] + '-' + month + '-30'
}
this.formData.searchEndTime = str2[0] + '-' + month + '-' + new Date(str2[0], month, 0).getDate()
} else {
this.formData.searchBeginTime = this.$refs.timelist.timeValue[0]
this.formData.searchEndTime = this.$refs.timelist.timeValue[1]

View File

@@ -31,7 +31,9 @@ export default {
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
}
},
mounted() {

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,73 +1,75 @@
<template>
<div class="pa10">
<el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" style="height:calc(100vh - 20px)">
<el-tab-pane label="监测点数据查询" name="first">
<onlineData ></onlineData>
</el-tab-pane>
<el-tab-pane label="监测点台账信息" name="second">
<devicemessage ></devicemessage>
</el-tab-pane>
<el-tab-pane label="终端台账信息" name="third">
<terminalmessage > </terminalmessage>
</el-tab-pane>
<el-tab-pane label="数据完整性统计" name="sen">
<integralitytable ></integralitytable>
</el-tab-pane>
</el-tabs>
</div>
<div class="pa10">
<el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" style="height: calc(100vh - 20px)">
<el-tab-pane label="监测点数据查询" name="first">
<onlineData></onlineData>
</el-tab-pane>
<el-tab-pane label="监测点台账信息" name="second">
<devicemessage></devicemessage>
</el-tab-pane>
<el-tab-pane label="终端台账信息" name="third">
<terminalmessage></terminalmessage>
</el-tab-pane>
<el-tab-pane label="数据完整性统计" name="sen">
<integralitytable></integralitytable>
</el-tab-pane>
</el-tabs>
</div>
</template>
<script>
import onlineData from "@/views/cgy-harmonic-boot/monitor/onlineData";
import terminalmessage from "@/views/cgy-harmonic-boot/runmange/terminalmessage";
import devicemessage from "@/views/cgy-harmonic-boot/runmange/devicemessage";
import integralitytable from "@/views/cgy-harmonic-boot/area/integralitytable";
import onlineData from '@/views/cgy-harmonic-boot/monitor/onlineData'
import terminalmessage from '@/views/cgy-harmonic-boot/runmange/terminalmessage'
import devicemessage from '@/views/cgy-harmonic-boot/runmange/devicemessage'
import integralitytable from '@/views/cgy-harmonic-boot/area/integralitytable'
import api1 from '@/api/pollution/pollution'
export default {
components: {
onlineData,
devicemessage,
terminalmessage,
integralitytable,
},
data() {
return {
activeName:'first',
vh:null
};
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
this.guanzhou()
}
},
mounted() {
this.vh = window.sessionStorage.getItem('appheight')-12+'px'
},
methods: {
guanzhou(){
var data ={
token:this.$route.query.token
}
api1.guanzhou(data).then(res=>{
if(res.code=='A0000'){
return
}else{
this.$router.push('/error/massege/403')
}
})
},
handleClick(tab, event) {
// console.log(tab, event);
this.activeName = tab.name
}
},
};
</script>
components: {
onlineData,
devicemessage,
terminalmessage,
integralitytable
},
data() {
return {
activeName: 'first',
vh: null
}
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
}
},
mounted() {
this.vh = window.sessionStorage.getItem('appheight') - 12 + 'px'
},
methods: {
guanzhou() {
var data = {
token: this.$route.query.token
}
api1.guanzhou(data).then(res => {
if (res.code == 'A0000') {
return
} else {
this.$router.push('/error/massege/403')
}
})
},
handleClick(tab, event) {
// console.log(tab, event);
this.activeName = tab.name
}
}
}
</script>
<style lang="less" scoped>
.pa10 {
padding: 10px;
padding: 10px;
}
::v-deep .el-tabs--border-card>.el-tabs__content {
::v-deep .el-tabs--border-card > .el-tabs__content {
padding: 10px;
}
</style>

View File

@@ -37,7 +37,10 @@ export default {
},
created() {
if (process.env.VUE_APP_MODE === 'cgyqr') {
this.guanzhou()
// this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
}
},
mounted() {},

File diff suppressed because it is too large Load Diff

View File

@@ -1,405 +1,423 @@
<template>
<div v-loading="loading"
element-loading-text="数据加载中">
<el-form :inline="true" :model="formInline" class="demo-form-inline">
<el-form-item label="类型:" style="display:none">
<el-select
v-model="formData.statisticalType"
@change="changeclasss"
placeholder="请选择统计类型"
style="width:100%"
>
<el-option
v-for="item in classificationData"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
name: item.name,
id: item.id,
code: item.code,
sort: item.sort,
}"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="区域:" >
<el-select
ref="selectTree1"
v-model="deptName"
placeholder="请选择所属部门区域"
style="width: 100%"
>
<el-option :value="deptIndex" style="height: auto">
<el-tree
ref="tree"
:data="treeData"
node-key="id"
accordion
:default-expanded-keys="idArr"
:props="defaultProps"
@node-click="handleNodeClick"
>
<span class="span-ellipsis" slot-scope="{ node, data }">
<span :title="data.name">{{ data.name }}</span>
</span>
</el-tree>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="厂家:" >
<el-select
v-model="formData.manufacturer"
multiple
collapse-tags
placeholder="请选择终端厂家"
style="width: 100%"
>
<el-option
v-for="item in terminaloption"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
code: item.code,
name: item.name,
id: item.id,
sort: item.sort,
}"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="干扰源:" style="display: none">
<el-select
v-model="formData.loadType"
multiple
collapse-tags
placeholder="请选择干扰源类型"
style="width: 100%"
>
<el-option
v-for="item in interfereoption"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
code: item.code,
name: item.name,
id: item.id,
sort: item.sort,
}"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="通讯状态:" >
<el-select
v-model="formData.comFlag"
multiple
collapse-tags
placeholder="请选择通讯状态"
style="width: 100%"
>
<el-option
v-for="item in communicationstatus"
:key="item.value"
:label="item.label"
:value="item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="终端状态:" >
<el-select
v-model="formData.runFlag"
multiple
collapse-tags
placeholder="请选择终端状态"
style="width: 100%"
>
<el-option
v-for="item in terminalstatus"
:key="item.value"
:label="item.label"
:value="item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item >
<el-button
type="primary"
size="small"
icon="el-icon-search"
@click="queryDataInfo"
>查询</el-button
>
</el-form-item>
<el-form-item style="float: right;">
<span>在线率60% <span style="color:red;font-weight: bold;">&ensp;&ensp;&ensp;</span> 60%在线率90% <span style="color:rgb(255, 174, 0);font-weight: bold;">&ensp;&ensp;&ensp;</span> 90%在线率 <span style="color:green;font-weight: bold;"></span> </span>
</el-form-item>
</el-form>
<el-row :gutter="20" style="margin-top: 0%">
<el-col :span="24">
<terminalmessagetable
:tableData="tableData"
:classvalue="classt"
></terminalmessagetable>
</el-col>
</el-row>
</div>
</template>
<script>
import { getappheight, getheight } from "@/assets/commjs/common";
import { guanzhou } from "@/assets/commjs/token";
import api1 from "@/api/pollution/pollution";
import timepicker from "@/views/cgy-components/TimePicker/index4";
import { dicData } from "../../../assets/commjs/dictypeData";
import api from "../../../api/integraliy/integraliy";
import Table from "../../components/teble/index";
import Pagination from "../../components/pagination/index";
import terminalmessagetable from "@/views/cgy-components/terminalmessagetable";
export default {
components: {
timepicker,
terminalmessagetable,
// onlinerateechart
},
watch: {},
computed: {},
data() {
return {
formInline: {},
loading: false,
classt: "Power_Network",
asideheight: undefined,
id: 1,
copent: 0,
title: "电网拓扑",
xdata: [
"江苏省",
"江西省",
"安徽省",
"湖北省",
"浙江省",
"湖南省",
"广东省",
"福建省",
"海南省",
"四川省",
"青海省",
"河北省",
],
ydata: [
92.6, 25.9, 39.0, 26.4, 28.7, 90.7, 75.6, 82.2, 48.7, 58.8, 16.0, 32.3,
],
classvalue: 0,
activeName: "tab1",
panindexOptions: [],
formData: {
//后面需要修改
serverName: "harmonic-boot",
searchBeginTime:'2023-04-01',
searchEndTime:'2023-04-11',
deptIndex: "",
monitorFlag: 2,
powerFlag: 2,
loadType: [],
manufacturer: [],
statisticalType: "",
scale: [],
comFlag: [0, 1],
runFlag: [0, 1, 2],
},
deptId: "",
deptName: "全国",
deptIndex: "",
treeData: [],
idArr: [],
defaultProps: {
children: "children",
label: "name",
},
//统计类型
classificationData: [],
//电压等级
voltageleveloption: [],
//终端厂家
terminaloption: [],
//干扰源类型
interfereoption: [],
//通讯状态
communicationstatus: [
{ value: 0, label: "中断" },
{ value: 1, label: "正常" },
],
//终端状态
terminalstatus: [
{ value: 0, label: "投运" },
{ value: 1, label: "热备用" },
{ value: 2, label: "停运" },
],
classt: "Power_Network",
tableData: [],
};
},
created() {
var info = window.sessionStorage.getItem("Info");
info = eval("(" + info + ")");
this.formData.deptIndex = info.deptId;
this.getAreaDept();
this.getclassificationData();
this.getVoltage();
this.getManufacturer();
this.getLoadType();
},
mounted() {
// this.asideheight = getappheight();
this.queryDataInfo();
},
methods: {
guanzhou() {
var data = {
token: this.$route.query.token,
};
api1.guanzhou(data).then((res) => {
if (res.code == "A0000") {
return;
} else {
this.$router.push("/error/massege/403");
}
});
},
//切换统计类型
changeclasss(val) {
this.classt = val.code;
},
//部门绑定区域触发区域树节点
handleNodeClick(data, node) {
this.deptName = data.name;
this.$refs.selectTree1.blur();
this.deptId = data.id;
this.formData.deptIndex = data.id;
},
//2次组件触发事件
querfromdata(data) {
this.timeValue = data;
// alert("父组件条件查询触发方法" + this.timeValue);
},
handleClick(tab, event) {
this.$nextTick(() => {
this.$refs.child.onlinerateechart();
});
},
changePageNum(data) {
this.pageData.pageNum = data;
// alert("父组件当前页" + this.pageData.pageNum);
},
changePageSize(data) {
this.pageData.pageSize = data;
//alert("父组件当前条数" + this.pageData.pageSize);
},
//查询触发方法
queryDataInfo() {
this.loading = true;
api.getRuntimeData(this.formData).then((res) => {
if (res.code == "A0000") {
if (res.data.length == 0) {
this.tableData = [];
this.loading = false;
} else {
this.tableData = res.data;
this.loading = false;
}
}
});
},
//获取区域
getAreaDept() {
api.getAreaDept().then((res) => {
if (res.code == "A0000") {
var data = res.data;
data.forEach((element) => {
this.idArr.push(element.id);
});
this.treeData = data;
}
});
},
//字典获取数据电压等级
getVoltage() {
var code = "Dev_Voltage_Stand";
this.voltageleveloption = dicData(code, []);
//this.formData.scale = this.voltageleveloption;
},
//字典获取数据终端厂家
getManufacturer() {
var code = "Dev_Manufacturers";
this.terminaloption = dicData(code, []);
this.formData.manufacturer = this.terminaloption;
},
//字典获取数据干扰源类型
getLoadType() {
var code = "Interference_Source";
this.interfereoption = dicData(code, []);
this.formData.loadType = this.interfereoption;
},
//获取统计类型
getclassificationData() {
var code = "Statistical_Type";
this.classificationData = dicData(code, [
"Report_Type",
"Voltage_Level",
"Load_Type",
"Manufacturer"
]);
this.formData.statisticalType = this.classificationData[0];
},
},
};
</script>
<style lang="scss" scoped>
@import url("../../../styles/common.less");
.main {
overflow: hidden;
}
::v-deep .el-main[data-v-2338f777] {
/* margin-top: 10px; */
padding: 10px 10px 10px 10px;
background-color: rgba(234, 235, 236, 0.996);
color: #333;
line-height: 0px;
}
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar {
// width: 8px; /*滚动条宽度*/
// height: 12px; /*滚动条高度*/
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-track {
// border-radius: 0px; /*滚动条的背景区域的圆角*/
// background-color: rgba(203, 208, 207, 0.286); /*滚动条的背景颜色*/
// cursor: pointer;
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-corner {
// background-color: rgba(202, 207, 206, 0.286);
// cursor: pointer;
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-thumb {
// border-radius: 4px; /*滚动条的圆角*/
// background-color: rgba(144, 148, 148, 0.979); /*滚动条的背景颜色*/
// }
::v-deep .el-select-dropdown__item,
.el-select-dropdown__item {
background-color: #fff;
padding: 0 5px !important;
}
</style>
<template>
<div v-loading="loading" element-loading-text="数据加载中">
<el-form :inline="true" :model="formInline" class="demo-form-inline">
<el-form-item label="类型:" style="display: none">
<el-select
v-model="formData.statisticalType"
@change="changeclasss"
placeholder="请选择统计类型"
style="width: 100%"
>
<el-option
v-for="item in classificationData"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
name: item.name,
id: item.id,
code: item.code,
sort: item.sort
}"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="区域:">
<el-select ref="selectTree1" v-model="deptName" placeholder="请选择所属部门区域" style="width: 100%">
<el-option :value="deptIndex" style="height: auto">
<el-tree
ref="tree"
:data="treeData"
node-key="id"
accordion
:default-expanded-keys="idArr"
:props="defaultProps"
@node-click="handleNodeClick"
>
<span class="span-ellipsis" slot-scope="{ node, data }">
<span :title="data.name">{{ data.name }}</span>
</span>
</el-tree>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="厂家:">
<el-select
v-model="formData.manufacturer"
multiple
collapse-tags
placeholder="请选择终端厂家"
style="width: 100%"
>
<el-option
v-for="item in terminaloption"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
code: item.code,
name: item.name,
id: item.id,
sort: item.sort
}"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="干扰源:" style="display: none">
<el-select
v-model="formData.loadType"
multiple
collapse-tags
placeholder="请选择干扰源类型"
style="width: 100%"
>
<el-option
v-for="item in interfereoption"
:key="item.id"
:label="item.name"
:value="{
label: item.name,
value: item.id,
code: item.code,
name: item.name,
id: item.id,
sort: item.sort
}"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="通讯状态:">
<el-select
v-model="formData.comFlag"
multiple
collapse-tags
placeholder="请选择通讯状态"
style="width: 100%"
>
<el-option
v-for="item in communicationstatus"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="终端状态:">
<el-select
v-model="formData.runFlag"
multiple
collapse-tags
placeholder="请选择终端状态"
style="width: 100%"
>
<el-option
v-for="item in terminalstatus"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" size="small" icon="el-icon-search" @click="queryDataInfo">查询</el-button>
</el-form-item>
<el-form-item style="float: right">
<span>
在线率60%
<span style="color: red; font-weight: bold">&ensp;&ensp;&ensp;</span>
60%在线率90%
<span style="color: rgb(255, 174, 0); font-weight: bold">&ensp;&ensp;&ensp;</span>
90%在线率
<span style="color: green; font-weight: bold"></span>
</span>
</el-form-item>
</el-form>
<el-row :gutter="20" style="margin-top: 0%">
<el-col :span="24">
<terminalmessagetable :tableData="tableData" :classvalue="classt"></terminalmessagetable>
</el-col>
</el-row>
</div>
</template>
<script>
import { getappheight, getheight } from '@/assets/commjs/common'
import { guanzhou } from '@/assets/commjs/token'
import api1 from '@/api/pollution/pollution'
import timepicker from '@/views/cgy-components/TimePicker/index4'
import { dicData } from '../../../assets/commjs/dictypeData'
import api from '../../../api/integraliy/integraliy'
import Table from '../../components/teble/index'
import Pagination from '../../components/pagination/index'
import terminalmessagetable from '@/views/cgy-components/terminalmessagetable'
export default {
components: {
timepicker,
terminalmessagetable
// onlinerateechart
},
watch: {},
computed: {},
data() {
return {
formInline: {},
loading: false,
classt: 'Power_Network',
asideheight: undefined,
id: 1,
copent: 0,
title: '电网拓扑',
xdata: [
'江苏省',
'江西省',
'安徽省',
'湖北省',
'浙江省',
'湖南省',
'广东省',
'福建省',
'海南省',
'四川省',
'青海省',
'河北省'
],
ydata: [92.6, 25.9, 39.0, 26.4, 28.7, 90.7, 75.6, 82.2, 48.7, 58.8, 16.0, 32.3],
classvalue: 0,
activeName: 'tab1',
panindexOptions: [],
formData: {
//后面需要修改
serverName: 'harmonic-boot',
searchBeginTime: '',
searchEndTime: '',
deptIndex: '',
monitorFlag: 2,
powerFlag: 2,
loadType: [],
manufacturer: [],
statisticalType: '',
scale: [],
comFlag: [0, 1],
runFlag: [0, 1, 2]
},
deptId: '',
deptName: '全国',
deptIndex: '',
treeData: [],
idArr: [],
defaultProps: {
children: 'children',
label: 'name'
},
//统计类型
classificationData: [],
//电压等级
voltageleveloption: [],
//终端厂家
terminaloption: [],
//干扰源类型
interfereoption: [],
//通讯状态
communicationstatus: [
{ value: 0, label: '中断' },
{ value: 1, label: '正常' }
],
//终端状态
terminalstatus: [
{ value: 0, label: '投运' },
{ value: 1, label: '热备用' },
{ value: 2, label: '停运' }
],
classt: 'Power_Network',
tableData: []
}
},
created() {
var info = window.sessionStorage.getItem('Info')
info = eval('(' + info + ')')
this.formData.deptIndex = info.deptId
this.getAreaDept()
this.getclassificationData()
this.getVoltage()
this.getManufacturer()
this.getLoadType()
},
mounted() {
// this.asideheight = getappheight();
this.queryDataInfo()
},
methods: {
guanzhou() {
var data = {
token: this.$route.query.token
}
api1.guanzhou(data).then(res => {
if (res.code == 'A0000') {
return
} else {
this.$router.push('/error/massege/403')
}
})
},
//切换统计类型
changeclasss(val) {
this.classt = val.code
},
//部门绑定区域触发区域树节点
handleNodeClick(data, node) {
this.deptName = data.name
this.$refs.selectTree1.blur()
this.deptId = data.id
this.formData.deptIndex = data.id
},
//2次组件触发事件
querfromdata(data) {
this.timeValue = data
// alert("父组件条件查询触发方法" + this.timeValue);
},
handleClick(tab, event) {
this.$nextTick(() => {
this.$refs.child.onlinerateechart()
})
},
changePageNum(data) {
this.pageData.pageNum = data
// alert("父组件当前页" + this.pageData.pageNum);
},
changePageSize(data) {
this.pageData.pageSize = data
//alert("父组件当前条数" + this.pageData.pageSize);
},
//查询触发方法
queryDataInfo() {
console.log(123, this.getSearchTimeRange())
this.formData.searchBeginTime = this.getSearchTimeRange().searchBeginTime
this.formData.searchEndTime = this.getSearchTimeRange().searchEndTime
this.loading = true
api.getRuntimeData(this.formData).then(res => {
if (res.code == 'A0000') {
if (res.data.length == 0) {
this.tableData = []
this.loading = false
} else {
this.tableData = res.data
this.loading = false
}
}
})
},
//获取区域
getAreaDept() {
api.getAreaDept().then(res => {
if (res.code == 'A0000') {
var data = res.data
data.forEach(element => {
this.idArr.push(element.id)
})
this.treeData = data
}
})
},
//字典获取数据电压等级
getVoltage() {
var code = 'Dev_Voltage_Stand'
this.voltageleveloption = dicData(code, [])
//this.formData.scale = this.voltageleveloption;
},
//字典获取数据终端厂家
getManufacturer() {
var code = 'Dev_Manufacturers'
this.terminaloption = dicData(code, [])
this.formData.manufacturer = this.terminaloption
},
//字典获取数据干扰源类型
getLoadType() {
var code = 'Interference_Source'
this.interfereoption = dicData(code, [])
this.formData.loadType = this.interfereoption
},
//获取统计类型
getclassificationData() {
var code = 'Statistical_Type'
this.classificationData = dicData(code, ['Report_Type', 'Voltage_Level', 'Load_Type', 'Manufacturer'])
this.formData.statisticalType = this.classificationData[0]
},
getSearchTimeRange() {
const now = new Date()
const currentYear = now.getFullYear()
const currentMonth = now.getMonth() // 0-11
const currentDate = now.getDate()
let searchBeginTime, searchEndTime
if (currentDate === 1) {
// 如果是1号返回上个月1号到上个月最后一天
// 上个月的第一天
const lastMonthFirstDay = new Date(currentYear, currentMonth - 1, 1)
searchBeginTime = this.formatDate(lastMonthFirstDay)
// 上个月的最后一天当前月的第0天就是上个月的最后一天
const lastMonthLastDay = new Date(currentYear, currentMonth, 0)
searchEndTime = this.formatDate(lastMonthLastDay)
} else {
// 如果不是1号返回当月1号到当前时间
const monthFirstDay = new Date(currentYear, currentMonth, 1)
searchBeginTime = this.formatDate(monthFirstDay)
searchEndTime = this.formatDate(now)
}
return {
searchBeginTime,
searchEndTime
}
},
// 辅助函数:格式化日期为 YYYY-MM-DD
formatDate(date) {
const year = date.getFullYear()
const month = String(date.getMonth() + 1).padStart(2, '0')
const day = String(date.getDate()).padStart(2, '0')
return `${year}-${month}-${day}`
}
}
}
</script>
<style lang="scss" scoped>
@import url('../../../styles/common.less');
.main {
overflow: hidden;
}
::v-deep .el-main[data-v-2338f777] {
/* margin-top: 10px; */
padding: 10px 10px 10px 10px;
background-color: rgba(234, 235, 236, 0.996);
color: #333;
line-height: 0px;
}
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar {
// width: 8px; /*滚动条宽度*/
// height: 12px; /*滚动条高度*/
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-track {
// border-radius: 0px; /*滚动条的背景区域的圆角*/
// background-color: rgba(203, 208, 207, 0.286); /*滚动条的背景颜色*/
// cursor: pointer;
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-corner {
// background-color: rgba(202, 207, 206, 0.286);
// cursor: pointer;
// }
// ::v-deep .el-table__body-wrapper::-webkit-scrollbar-thumb {
// border-radius: 4px; /*滚动条的圆角*/
// background-color: rgba(144, 148, 148, 0.979); /*滚动条的背景颜色*/
// }
::v-deep .el-select-dropdown__item,
.el-select-dropdown__item {
background-color: #fff;
padding: 0 5px !important;
}
</style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -264,7 +264,7 @@ export default {
//获取审核人列表
getAuditUser() {
let param = {roleType: 3}
let param = {roleType: 1}
getAuditUser(param).then(res => {
if (res && res.code === 'A0000') {
this.auditUserList = res.data

File diff suppressed because it is too large Load Diff

View File

@@ -51,7 +51,9 @@ export default {
};
},
created() {
this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
},
mounted() {

View File

@@ -69,7 +69,7 @@
</el-form-item>
<el-form-item style="float: right;margin-right: 50px">
<el-button :disabled="store.params.dataType === '01'" type="primary" @click="reCalUpload(activeName)">
<el-button :disabled="store.params.dataType === '01'" type="primary" @click="reCalUpload('1')">
{{ storeList[activeName].label + '重新计算' }}
</el-button>
</el-form-item>
@@ -605,7 +605,7 @@ export default {
let dateMonth = this.store.params.searchBeginTime.substring(0, 7)
//月
request
.get('/prepare-boot/dimGlobal/reCalMonthUploadAlgorithm?statisticDate=' + dateMonth + '&type=' + type)
.get('/prepare-boot/dimGlobal/reCalMonthUploadAlgorithm?statisticDate=' + dateMonth + '&type=1')
.then(res => {
if (res && res.code === 'A0000') {
this.$message({
@@ -617,7 +617,7 @@ export default {
})
} else {
request
.get('/prepare-boot/dimGlobal/reCalUploadAlgorithm?statisticDate=' + this.store.params.searchBeginTime + '&type=' + type)
.get('/prepare-boot/dimGlobal/reCalUploadAlgorithm?statisticDate=' + this.store.params.searchBeginTime + '&type=1')
.then(res => {
if (res && res.code === 'A0000') {
this.$message({

View File

@@ -48,7 +48,9 @@ export default {
}
},
created() {
this.guanzhou()
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
},
mounted() {
this.setHeight()

View File

@@ -75,7 +75,9 @@ export default {
};
},
created() {
this.guanzhou();
if (process.env.VUE_APP_KEY != 'scqr') {
this.guanzhou()
}
},
mounted() {},
methods: {

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -18,7 +18,7 @@ module.exports = {
// publicPath: 'https://fuphoenixes.github.io/example/dist/',
//publicPath: "./",
// publicPath: process.env.VUE_APP_PATH,
publicPath: process.env.NODE_ENV === 'development' ? './' : process.env.VUE_APP_MODE == 'jbqr' ? './' : '/',
publicPath: './', //process.env.NODE_ENV === 'development' ? './' : process.env.VUE_APP_MODE == 'jbqr' ? './' : '/',
outputDir: 'dist',
assetsDir: 'static',
// lintOnSave: process.env.NODE_ENV === 'development',
@@ -37,9 +37,9 @@ module.exports = {
'/api': {
// target: 'http://18028358809.gnway.cc', //hsw
// target: 'http://192.168.120.210:10215', //hsw
target: 'http://192.168.1.29:10215', //超高压
// target: 'http://192.168.1.28:10215', //超高压
// target: "'https://pqmcn.com:8092/api", //治理
// target: 'http://192.168.1.24:10215', // 河北
target: 'http://192.168.1.67:10215', // 河北
// target: "http://192.168.1.31:10215", // 海南
// target: "http://192.168.1.29:10215", // 冀北
changeOrigin: true,