Merge branch 'master-dev' of http://git.hivekion.com:3000/xiaoguangbin/AnalysisSystemForRadionuclide_vue into master-dev
This commit is contained in:
commit
f17ce2b03b
|
@ -4,20 +4,20 @@
|
||||||
* data中url定义 list为查询列表 delete为删除单条记录 deleteBatch为批量删除
|
* data中url定义 list为查询列表 delete为删除单条记录 deleteBatch为批量删除
|
||||||
*/
|
*/
|
||||||
import { filterObj } from '@/utils/util';
|
import { filterObj } from '@/utils/util';
|
||||||
import { deleteAction, getAction,downFile,getFileAccessHttpUrl } from '@/api/manage'
|
import { deleteAction, getAction, downFile, getFileAccessHttpUrl } from '@/api/manage'
|
||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import { ACCESS_TOKEN, TENANT_ID } from "@/store/mutation-types"
|
import { ACCESS_TOKEN, TENANT_ID } from "@/store/mutation-types"
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
|
|
||||||
export const JeecgListMixin = {
|
export const JeecgListMixin = {
|
||||||
data(){
|
data() {
|
||||||
return {
|
return {
|
||||||
/* 查询条件-请不要在queryParam中声明非字符串值的属性 */
|
/* 查询条件-请不要在queryParam中声明非字符串值的属性 */
|
||||||
queryParam: {},
|
queryParam: {},
|
||||||
/* 数据源 */
|
/* 数据源 */
|
||||||
dataSource:[],
|
dataSource: [],
|
||||||
/* 分页参数 */
|
/* 分页参数 */
|
||||||
ipagination:{
|
ipagination: {
|
||||||
current: 1,
|
current: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
pageSizeOptions: ['10', '20', '30'],
|
pageSizeOptions: ['10', '20', '30'],
|
||||||
|
@ -30,22 +30,22 @@ export const JeecgListMixin = {
|
||||||
total: 0
|
total: 0
|
||||||
},
|
},
|
||||||
/* 排序参数 */
|
/* 排序参数 */
|
||||||
isorter:{
|
isorter: {
|
||||||
column: 'createTime',
|
column: 'createTime',
|
||||||
order: 'desc',
|
order: 'desc',
|
||||||
},
|
},
|
||||||
/* 筛选参数 */
|
/* 筛选参数 */
|
||||||
filters: {},
|
filters: {},
|
||||||
/* table加载状态 */
|
/* table加载状态 */
|
||||||
loading:false,
|
loading: false,
|
||||||
/* table选中keys*/
|
/* table选中keys*/
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
/* table选中records*/
|
/* table选中records*/
|
||||||
selectionRows: [],
|
selectionRows: [],
|
||||||
/* 查询折叠 */
|
/* 查询折叠 */
|
||||||
toggleSearchStatus:false,
|
toggleSearchStatus: false,
|
||||||
/* 高级查询条件生效状态 */
|
/* 高级查询条件生效状态 */
|
||||||
superQueryFlag:false,
|
superQueryFlag: false,
|
||||||
/* 高级查询条件 */
|
/* 高级查询条件 */
|
||||||
superQueryParams: '',
|
superQueryParams: '',
|
||||||
/** 高级查询拼接方式 */
|
/** 高级查询拼接方式 */
|
||||||
|
@ -53,7 +53,7 @@ export const JeecgListMixin = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
if(!this.disableMixinCreated&&!this.isImmediate){
|
if (!this.disableMixinCreated) {
|
||||||
console.log(' -- mixin created -- ')
|
console.log(' -- mixin created -- ')
|
||||||
this.loadData();
|
this.loadData();
|
||||||
//初始化字典配置 在自己页面定义
|
//初始化字典配置 在自己页面定义
|
||||||
|
@ -62,18 +62,18 @@ export const JeecgListMixin = {
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
//token header
|
//token header
|
||||||
tokenHeader(){
|
tokenHeader() {
|
||||||
let head = {'X-Access-Token': Vue.ls.get(ACCESS_TOKEN)}
|
let head = { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) }
|
||||||
let tenantid = Vue.ls.get(TENANT_ID)
|
let tenantid = Vue.ls.get(TENANT_ID)
|
||||||
if(tenantid){
|
if (tenantid) {
|
||||||
head['tenant-id'] = tenantid
|
head['tenant-id'] = tenantid
|
||||||
}
|
}
|
||||||
return head;
|
return head;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods:{
|
methods: {
|
||||||
loadData(arg) {
|
loadData(arg) {
|
||||||
if(!this.url.list){
|
if (!this.url.list) {
|
||||||
this.$message.error("请设置url.list属性!")
|
this.$message.error("请设置url.list属性!")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -87,46 +87,46 @@ export const JeecgListMixin = {
|
||||||
getAction(this.url.list, params).then((res) => {
|
getAction(this.url.list, params).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
//update-begin---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
//update-begin---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
||||||
this.dataSource = res.result.records||res.result;
|
this.dataSource = res.result.records || res.result;
|
||||||
if(res.result.total)
|
if (res.result.total) {
|
||||||
{
|
|
||||||
this.ipagination.total = res.result.total;
|
this.ipagination.total = res.result.total;
|
||||||
}else{
|
} else {
|
||||||
this.ipagination.total = 0;
|
this.ipagination.total = 0;
|
||||||
}
|
}
|
||||||
//update-end---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
//update-end---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
||||||
}else{
|
} else {
|
||||||
this.$message.warning(res.message)
|
this.$message.warning(res.message)
|
||||||
}
|
}
|
||||||
}).finally(() => {
|
}).finally(() => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
initDictConfig(){
|
initDictConfig() {
|
||||||
console.log("--这是一个假的方法!")
|
console.log("--这是一个假的方法!")
|
||||||
},
|
},
|
||||||
handleSuperQuery(params, matchType) {
|
handleSuperQuery(params, matchType) {
|
||||||
//高级查询方法
|
//高级查询方法
|
||||||
if(!params){
|
if (!params) {
|
||||||
this.superQueryParams=''
|
this.superQueryParams = ''
|
||||||
this.superQueryFlag = false
|
this.superQueryFlag = false
|
||||||
}else{
|
} else {
|
||||||
this.superQueryFlag = true
|
this.superQueryFlag = true
|
||||||
this.superQueryParams=JSON.stringify(params)
|
this.superQueryParams = JSON.stringify(params)
|
||||||
this.superQueryMatchType = matchType
|
this.superQueryMatchType = matchType
|
||||||
}
|
}
|
||||||
this.loadData(1)
|
this.loadData(1)
|
||||||
},
|
},
|
||||||
getQueryParams() {
|
getQueryParams() {
|
||||||
//获取查询条件
|
//获取查询条件
|
||||||
console.log("this.queryParamthis.queryParam",this.queryParam);
|
console.log("this.queryParamthis.queryParam", this.queryParam);
|
||||||
let sqp = {}
|
let sqp = {}
|
||||||
if(this.superQueryParams){
|
if (this.superQueryParams) {
|
||||||
sqp['superQueryParams']=encodeURI(this.superQueryParams)
|
sqp['superQueryParams'] = encodeURI(this.superQueryParams)
|
||||||
sqp['superQueryMatchType'] = this.superQueryMatchType
|
sqp['superQueryMatchType'] = this.superQueryMatchType
|
||||||
}
|
}
|
||||||
var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters);
|
var param = Object.assign(sqp, this.queryParam, this.isorter, this.filters);
|
||||||
param.field = this.getQueryField();
|
// param.field = this.getQueryField();
|
||||||
|
param.field = this.isorter.column;
|
||||||
param.pageNo = this.ipagination.current;
|
param.pageNo = this.ipagination.current;
|
||||||
param.pageSize = this.ipagination.pageSize;
|
param.pageSize = this.ipagination.pageSize;
|
||||||
return filterObj(param);
|
return filterObj(param);
|
||||||
|
@ -163,7 +163,7 @@ export const JeecgListMixin = {
|
||||||
this.loadData(1);
|
this.loadData(1);
|
||||||
},
|
},
|
||||||
batchDel: function () {
|
batchDel: function () {
|
||||||
if(!this.url.deleteBatch){
|
if (!this.url.deleteBatch) {
|
||||||
this.$message.error("请设置url.deleteBatch属性!")
|
this.$message.error("请设置url.deleteBatch属性!")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -181,7 +181,7 @@ export const JeecgListMixin = {
|
||||||
content: "Do You Want To Delete This Item?",
|
content: "Do You Want To Delete This Item?",
|
||||||
onOk: function () {
|
onOk: function () {
|
||||||
that.loading = true;
|
that.loading = true;
|
||||||
deleteAction(that.url.deleteBatch, {ids: ids}).then((res) => {
|
deleteAction(that.url.deleteBatch, { ids: ids }).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
//重新计算分页问题
|
//重新计算分页问题
|
||||||
that.reCalculatePage(that.selectedRowKeys.length)
|
that.reCalculatePage(that.selectedRowKeys.length)
|
||||||
|
@ -199,12 +199,12 @@ export const JeecgListMixin = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleDelete: function (id, propertyName) {
|
handleDelete: function (id, propertyName) {
|
||||||
if(!this.url.delete){
|
if (!this.url.delete) {
|
||||||
this.$message.error("请设置url.delete属性!")
|
this.$message.error("请设置url.delete属性!")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
var that = this;
|
var that = this;
|
||||||
deleteAction(that.url.delete, {[propertyName || 'id']: id}).then((res) => {
|
deleteAction(that.url.delete, { [propertyName || 'id']: id }).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
//重新计算分页问题
|
//重新计算分页问题
|
||||||
that.reCalculatePage(1)
|
that.reCalculatePage(1)
|
||||||
|
@ -215,16 +215,16 @@ export const JeecgListMixin = {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
reCalculatePage(count){
|
reCalculatePage(count) {
|
||||||
//总数量-count
|
//总数量-count
|
||||||
let total=this.ipagination.total-count;
|
let total = this.ipagination.total - count;
|
||||||
//获取删除后的分页数
|
//获取删除后的分页数
|
||||||
let currentIndex=Math.ceil(total/this.ipagination.pageSize);
|
let currentIndex = Math.ceil(total / this.ipagination.pageSize);
|
||||||
//删除后的分页数<所在当前页
|
//删除后的分页数<所在当前页
|
||||||
if(currentIndex<this.ipagination.current){
|
if (currentIndex < this.ipagination.current) {
|
||||||
this.ipagination.current=currentIndex;
|
this.ipagination.current = currentIndex;
|
||||||
}
|
}
|
||||||
console.log('currentIndex',currentIndex)
|
console.log('currentIndex', currentIndex)
|
||||||
},
|
},
|
||||||
handleEdit: function (record) {
|
handleEdit: function (record) {
|
||||||
this.$refs.modalForm.edit(record);
|
this.$refs.modalForm.edit(record);
|
||||||
|
@ -237,6 +237,7 @@ export const JeecgListMixin = {
|
||||||
this.$refs.modalForm.disableSubmit = false;
|
this.$refs.modalForm.disableSubmit = false;
|
||||||
},
|
},
|
||||||
handleTableChange(pagination, filters, sorter) {
|
handleTableChange(pagination, filters, sorter) {
|
||||||
|
console.log("sortersorter", sorter);
|
||||||
//分页、排序、筛选变化时触发
|
//分页、排序、筛选变化时触发
|
||||||
//TODO 筛选
|
//TODO 筛选
|
||||||
console.log(pagination)
|
console.log(pagination)
|
||||||
|
@ -247,11 +248,11 @@ export const JeecgListMixin = {
|
||||||
this.ipagination = pagination;
|
this.ipagination = pagination;
|
||||||
this.loadData();
|
this.loadData();
|
||||||
},
|
},
|
||||||
handleToggleSearch(){
|
handleToggleSearch() {
|
||||||
this.toggleSearchStatus = !this.toggleSearchStatus;
|
this.toggleSearchStatus = !this.toggleSearchStatus;
|
||||||
},
|
},
|
||||||
// 给popup查询使用(查询区域不支持回填多个字段,限制只返回一个字段)
|
// 给popup查询使用(查询区域不支持回填多个字段,限制只返回一个字段)
|
||||||
getPopupField(fields){
|
getPopupField(fields) {
|
||||||
return fields.split(',')[0]
|
return fields.split(',')[0]
|
||||||
},
|
},
|
||||||
modalFormOk() {
|
modalFormOk() {
|
||||||
|
@ -260,39 +261,39 @@ export const JeecgListMixin = {
|
||||||
//清空列表选中
|
//清空列表选中
|
||||||
this.onClearSelected()
|
this.onClearSelected()
|
||||||
},
|
},
|
||||||
handleDetail:function(record){
|
handleDetail: function (record) {
|
||||||
this.$refs.modalForm.edit(record);
|
this.$refs.modalForm.edit(record);
|
||||||
this.$refs.modalForm.title="Detail";
|
this.$refs.modalForm.title = "Detail";
|
||||||
this.$refs.modalForm.disableSubmit = true;
|
this.$refs.modalForm.disableSubmit = true;
|
||||||
},
|
},
|
||||||
/* 导出 */
|
/* 导出 */
|
||||||
handleExportXls2(){
|
handleExportXls2() {
|
||||||
let paramsStr = encodeURI(JSON.stringify(this.getQueryParams()));
|
let paramsStr = encodeURI(JSON.stringify(this.getQueryParams()));
|
||||||
let url = `${window._CONFIG['domianURL']}/${this.url.exportXlsUrl}?paramsStr=${paramsStr}`;
|
let url = `${window._CONFIG['domianURL']}/${this.url.exportXlsUrl}?paramsStr=${paramsStr}`;
|
||||||
window.location.href = url;
|
window.location.href = url;
|
||||||
},
|
},
|
||||||
handleExportXls(fileName){
|
handleExportXls(fileName) {
|
||||||
if(!fileName || typeof fileName != "string"){
|
if (!fileName || typeof fileName != "string") {
|
||||||
fileName = "导出文件"
|
fileName = "导出文件"
|
||||||
}
|
}
|
||||||
let param = this.getQueryParams();
|
let param = this.getQueryParams();
|
||||||
if(this.selectedRowKeys && this.selectedRowKeys.length>0){
|
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
|
||||||
param['selections'] = this.selectedRowKeys.join(",")
|
param['selections'] = this.selectedRowKeys.join(",")
|
||||||
}
|
}
|
||||||
console.log("导出参数",param)
|
console.log("导出参数", param)
|
||||||
downFile(this.url.exportXlsUrl,param).then((data)=>{
|
downFile(this.url.exportXlsUrl, param).then((data) => {
|
||||||
if (!data) {
|
if (!data) {
|
||||||
this.$message.warning("文件下载失败")
|
this.$message.warning("文件下载失败")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (typeof window.navigator.msSaveBlob !== 'undefined') {
|
if (typeof window.navigator.msSaveBlob !== 'undefined') {
|
||||||
window.navigator.msSaveBlob(new Blob([data],{type: 'application/vnd.ms-excel'}), fileName+'.xls')
|
window.navigator.msSaveBlob(new Blob([data], { type: 'application/vnd.ms-excel' }), fileName + '.xls')
|
||||||
}else{
|
} else {
|
||||||
let url = window.URL.createObjectURL(new Blob([data],{type: 'application/vnd.ms-excel'}))
|
let url = window.URL.createObjectURL(new Blob([data], { type: 'application/vnd.ms-excel' }))
|
||||||
let link = document.createElement('a')
|
let link = document.createElement('a')
|
||||||
link.style.display = 'none'
|
link.style.display = 'none'
|
||||||
link.href = url
|
link.href = url
|
||||||
link.setAttribute('download', fileName+'.xls')
|
link.setAttribute('download', fileName + '.xls')
|
||||||
document.body.appendChild(link)
|
document.body.appendChild(link)
|
||||||
link.click()
|
link.click()
|
||||||
document.body.removeChild(link); //下载完成移除元素
|
document.body.removeChild(link); //下载完成移除元素
|
||||||
|
@ -301,7 +302,7 @@ export const JeecgListMixin = {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/* 导入 */
|
/* 导入 */
|
||||||
handleImportExcel(info){
|
handleImportExcel(info) {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
if (info.file.status !== 'uploading') {
|
if (info.file.status !== 'uploading') {
|
||||||
console.log(info.file, info.fileList);
|
console.log(info.file, info.fileList);
|
||||||
|
@ -316,7 +317,7 @@ export const JeecgListMixin = {
|
||||||
this.$warning({
|
this.$warning({
|
||||||
title: message,
|
title: message,
|
||||||
content: (<div>
|
content: (<div>
|
||||||
<span>{msg}</span><br/>
|
<span>{msg}</span><br />
|
||||||
<span>具体详情请 <a href={href} target="_blank" download={fileName}>点击下载</a> </span>
|
<span>具体详情请 <a href={href} target="_blank" download={fileName}>点击下载</a> </span>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
@ -353,21 +354,21 @@ export const JeecgListMixin = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
/* 图片预览 */
|
/* 图片预览 */
|
||||||
getImgView(text){
|
getImgView(text) {
|
||||||
if(text && text.indexOf(",")>0){
|
if (text && text.indexOf(",") > 0) {
|
||||||
text = text.substring(0,text.indexOf(","))
|
text = text.substring(0, text.indexOf(","))
|
||||||
}
|
}
|
||||||
return getFileAccessHttpUrl(text)
|
return getFileAccessHttpUrl(text)
|
||||||
},
|
},
|
||||||
/* 文件下载 */
|
/* 文件下载 */
|
||||||
// update--autor:lvdandan-----date:20200630------for:修改下载文件方法名uploadFile改为downloadFile------
|
// update--autor:lvdandan-----date:20200630------for:修改下载文件方法名uploadFile改为downloadFile------
|
||||||
downloadFile(text){
|
downloadFile(text) {
|
||||||
if(!text){
|
if (!text) {
|
||||||
this.$message.warning("未知的文件")
|
this.$message.warning("未知的文件")
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(text.indexOf(",")>0){
|
if (text.indexOf(",") > 0) {
|
||||||
text = text.substring(0,text.indexOf(","))
|
text = text.substring(0, text.indexOf(","))
|
||||||
}
|
}
|
||||||
let url = getFileAccessHttpUrl(text)
|
let url = getFileAccessHttpUrl(text)
|
||||||
window.open(url);
|
window.open(url);
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
<template>
|
<template>
|
||||||
<a-card :bordered="false" style="height: 100%;">
|
<a-card :bordered="false" style="height: 100%">
|
||||||
<a-layout id="components-layout-demo-custom-trigger" style="height: 100%">
|
<a-layout id="components-layout-demo-custom-trigger" style="height: 100%">
|
||||||
<a-layout-sider theme="light" v-model="collapsed" :trigger="null" collapsible width="350px">
|
<a-layout-sider theme="light" v-model="collapsed" :trigger="null" collapsible width="350px">
|
||||||
<div style="height:100%">
|
<div style="height: 100%">
|
||||||
<a-menu
|
<a-menu
|
||||||
id="dddddd"
|
id="dddddd"
|
||||||
:defaultOpenKeys="defaultOpenKeys"
|
:defaultOpenKeys="defaultOpenKeys"
|
||||||
|
@ -97,13 +97,13 @@ export default {
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
var permissionList = this.$store.getters.permissionList
|
var permissionList = this.$store.getters.permissionList
|
||||||
console.log("permissionList",permissionList);
|
console.log('permissionList', permissionList)
|
||||||
permissionList.forEach((f) => {
|
permissionList.forEach((f) => {
|
||||||
if (f.name === "abnormal-alarm") {
|
if (f.name === 'abnormal-alarm') {
|
||||||
this.menus = f.children
|
this.menus = f.children
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
console.log("路由信息",this.menus);
|
console.log('路由信息', this.menus)
|
||||||
// this.initDefaultKeys(this.menus[0])
|
// this.initDefaultKeys(this.menus[0])
|
||||||
// 将从缓存中取出openKeys
|
// 将从缓存中取出openKeys
|
||||||
// const openKeys = window.sessionStorage.getItem('openKeys')
|
// const openKeys = window.sessionStorage.getItem('openKeys')
|
||||||
|
@ -113,10 +113,9 @@ export default {
|
||||||
// this.defaultSelectedKeys.push(selectedKeys)
|
// this.defaultSelectedKeys.push(selectedKeys)
|
||||||
this.currSlecteKey.push(selectedKeys)
|
this.currSlecteKey.push(selectedKeys)
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
this.initDefaultKeys(this.menus[0])
|
this.initDefaultKeys(this.menus[0])
|
||||||
}
|
}
|
||||||
this.openKeys =this.defaultOpenKeys= this.menus.map(item => {
|
this.openKeys = this.defaultOpenKeys = this.menus.map((item) => {
|
||||||
return item.path
|
return item.path
|
||||||
})
|
})
|
||||||
// if (openKeys) {
|
// if (openKeys) {
|
||||||
|
@ -128,22 +127,23 @@ export default {
|
||||||
// this.openKeys = JSON.parse(openKeys)
|
// this.openKeys = JSON.parse(openKeys)
|
||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
// watch: {
|
watch: {
|
||||||
// "$route": {
|
$route: {
|
||||||
// handler: function (val, oldVal) {
|
handler: function (val, oldVal) {
|
||||||
// this.currSlecteKey=[]
|
this.currSlecteKey = []
|
||||||
// console.log(val);
|
console.log(val)
|
||||||
// this.currSlecteKey.push(val.path)
|
this.currSlecteKey.push(val.path)
|
||||||
// window.sessionStorage.setItem('currMenu', val.path)
|
window.sessionStorage.setItem('currMenu_alarm', val.path)
|
||||||
// },
|
},
|
||||||
// deep:true,
|
deep: true,
|
||||||
// immediate:true
|
immediate: true,
|
||||||
// }
|
},
|
||||||
// },
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 点击菜单,路由跳转,注意的是当点击MenuItem才会触发此函数
|
// 点击菜单,路由跳转,注意的是当点击MenuItem才会触发此函数
|
||||||
menuClick({ item, key, keyPath }) {
|
menuClick({ item, key, keyPath }) {
|
||||||
this.currSlecteKey =[]
|
console.log(item, key, keyPath)
|
||||||
|
this.currSlecteKey = []
|
||||||
window.sessionStorage.setItem('currMenu_alarm', key)
|
window.sessionStorage.setItem('currMenu_alarm', key)
|
||||||
// var parentPath = item._props.parentMenu._props.eventKey;
|
// var parentPath = item._props.parentMenu._props.eventKey;
|
||||||
// var parentTitle = parentPath.substring(parentPath.lastIndexOf("/") + 1, parentPath.length)
|
// var parentTitle = parentPath.substring(parentPath.lastIndexOf("/") + 1, parentPath.length)
|
||||||
|
@ -155,8 +155,8 @@ export default {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
initDefaultKeys(data) {
|
initDefaultKeys(data) {
|
||||||
this.currSlecteKey=[]
|
this.currSlecteKey = []
|
||||||
console.log("datadefaultOpenKeys",data);
|
console.log('datadefaultOpenKeys', data)
|
||||||
this.defaultOpenKeys.push(data.path)
|
this.defaultOpenKeys.push(data.path)
|
||||||
data.children.some((f) => {
|
data.children.some((f) => {
|
||||||
if (f.children) {
|
if (f.children) {
|
||||||
|
@ -192,7 +192,7 @@ export default {
|
||||||
background: none;
|
background: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
::v-deep .ant-card-body{
|
::v-deep .ant-card-body {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.ant-menu {
|
.ant-menu {
|
||||||
|
|
|
@ -448,6 +448,8 @@ export default {
|
||||||
max: 0,
|
max: 0,
|
||||||
min: 0,
|
min: 0,
|
||||||
avg: 0,
|
avg: 0,
|
||||||
|
xData: [],
|
||||||
|
yData: [],
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -622,7 +624,6 @@ export default {
|
||||||
getCpuUtilizationData() {
|
getCpuUtilizationData() {
|
||||||
let params = {
|
let params = {
|
||||||
itemId: this.currItemId,
|
itemId: this.currItemId,
|
||||||
// itemId: '37550',
|
|
||||||
itemType: 0,
|
itemType: 0,
|
||||||
start: `${dateFormat(new Date(), 'yyyy-MM-dd')} 00:00:00`,
|
start: `${dateFormat(new Date(), 'yyyy-MM-dd')} 00:00:00`,
|
||||||
end: dateFormat(new Date(), 'yyyy-MM-dd hh:mm:ss'),
|
end: dateFormat(new Date(), 'yyyy-MM-dd hh:mm:ss'),
|
||||||
|
@ -646,7 +647,6 @@ export default {
|
||||||
getTimeLineData() {
|
getTimeLineData() {
|
||||||
let params = {
|
let params = {
|
||||||
itemId: this.currItemId,
|
itemId: this.currItemId,
|
||||||
// itemId: '37550',
|
|
||||||
itemType: 0,
|
itemType: 0,
|
||||||
start: `${dateFormat(new Date(), 'yyyy-MM-dd')} 00:00:00`,
|
start: `${dateFormat(new Date(), 'yyyy-MM-dd')} 00:00:00`,
|
||||||
end: dateFormat(new Date(), 'yyyy-MM-dd hh:mm:ss'),
|
end: dateFormat(new Date(), 'yyyy-MM-dd hh:mm:ss'),
|
||||||
|
@ -728,6 +728,16 @@ export default {
|
||||||
this.currIndex = i
|
this.currIndex = i
|
||||||
this.currItemId = item.cpuUsedItemId
|
this.currItemId = item.cpuUsedItemId
|
||||||
this.currSourceId = item.sourceId
|
this.currSourceId = item.sourceId
|
||||||
|
this.detailInfo = {}
|
||||||
|
this.cpuData = {
|
||||||
|
max: 0,
|
||||||
|
min: 0,
|
||||||
|
avg: 0,
|
||||||
|
xData: [],
|
||||||
|
yData: [],
|
||||||
|
}
|
||||||
|
startTime = null
|
||||||
|
data1 = []
|
||||||
this.getBasiclnfo(item.hostId)
|
this.getBasiclnfo(item.hostId)
|
||||||
this.getCpuUtilizationData()
|
this.getCpuUtilizationData()
|
||||||
this.getTimeLineData()
|
this.getTimeLineData()
|
||||||
|
@ -735,8 +745,7 @@ export default {
|
||||||
getDetailsAlarmInfo(callBack) {
|
getDetailsAlarmInfo(callBack) {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
let params = {
|
let params = {
|
||||||
// sourceId:this.currSourceId,
|
sourceId: this.currSourceId,
|
||||||
sourceId: 'e2',
|
|
||||||
pageNo: this.ipagination_alarm_info.current,
|
pageNo: this.ipagination_alarm_info.current,
|
||||||
pageSize: this.ipagination_alarm_info.pageSize,
|
pageSize: this.ipagination_alarm_info.pageSize,
|
||||||
}
|
}
|
||||||
|
|
|
@ -128,9 +128,9 @@
|
||||||
<span>C to E : </span>
|
<span>C to E : </span>
|
||||||
<span>
|
<span>
|
||||||
E =
|
E =
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramA" /> +
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramA" @change="newCalibrationFuncModelChange"/> +
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramB" /> *C +
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramB" @change="newCalibrationFuncModelChange"/> *C +
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramC" /> *C <sup>2</sup>
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramC" @change="newCalibrationFuncModelChange" /> *C <sup>2</sup>
|
||||||
</span>
|
</span>
|
||||||
</p>
|
</p>
|
||||||
<div class="func">
|
<div class="func">
|
||||||
|
@ -785,6 +785,11 @@ export default {
|
||||||
energy,
|
energy,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// add之后 需要清空chart黄色的线 20231028:Xiao
|
||||||
|
if(this.figureChartOption.series[1].data) {
|
||||||
|
this.figureChartOption.series[1].data = []
|
||||||
|
}
|
||||||
|
|
||||||
this.figureChartOption.series[1].markPoint.data.push({ xAxis: channel, yAxis: energy })
|
this.figureChartOption.series[1].markPoint.data.push({ xAxis: channel, yAxis: energy })
|
||||||
|
|
||||||
const { min, max } = this.getFigureChartMaxAndMin()
|
const { min, max } = this.getFigureChartMaxAndMin()
|
||||||
|
@ -808,6 +813,19 @@ export default {
|
||||||
this.isInverse = true
|
this.isInverse = true
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// 输入框发生变化
|
||||||
|
newCalibrationFuncModelChange() {
|
||||||
|
// 输入内容的时候 需要清空table数据 20231028:Xiao
|
||||||
|
this.list = []
|
||||||
|
// 需要清空chart黄色的线 20231028:Xiao
|
||||||
|
if(this.figureChartOption.series[1].data) {
|
||||||
|
this.figureChartOption.series[1].data = []
|
||||||
|
}
|
||||||
|
if(this.figureChartOption.series[1].markPoint.data) {
|
||||||
|
this.figureChartOption.series[1].markPoint.data = []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
// 删除表格里的单项
|
// 删除表格里的单项
|
||||||
handleDel(index) {
|
handleDel(index) {
|
||||||
const willDelItem = this.list.splice(index, 1)[0]
|
const willDelItem = this.list.splice(index, 1)[0]
|
||||||
|
@ -857,15 +875,19 @@ export default {
|
||||||
// 点击Fitting按钮执行重新计算
|
// 点击Fitting按钮执行重新计算
|
||||||
async handleFitting() {
|
async handleFitting() {
|
||||||
const hasEmpty = Object.entries(this.newCalibrationFuncModel).some(([_, v]) => !v)
|
const hasEmpty = Object.entries(this.newCalibrationFuncModel).some(([_, v]) => !v)
|
||||||
if (hasEmpty) {
|
if (hasEmpty && this.list.length < 3) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
const { success, result, message } = await postAction('/spectrumAnalysis/fitting', {
|
const { success, result, message } = await postAction('/spectrumAnalysis/fitting', {
|
||||||
...this.newCalibrationFuncModel,
|
...this.newCalibrationFuncModel,
|
||||||
tempPoints: this.isFirstFitting
|
// 修改逻辑,如果列表中有数据 以列表的数据优先进行分析 20231028:Xiao
|
||||||
? this.oldScatterSeries
|
tempPoints: this.list.length > 0
|
||||||
: this.list.map((item) => ({ x: item.channel, y: item.energy })),
|
? this.list.map((item) => ({ x: item.channel, y: item.energy }))
|
||||||
|
: this.oldScatterSeries,
|
||||||
|
// tempPoints: this.isFirstFitting
|
||||||
|
// ? this.oldScatterSeries
|
||||||
|
// : this.list.map((item) => ({ x: item.channel, y: item.energy })),
|
||||||
count: this.isFirstFitting || !this.isInverse ? undefined : this.count,
|
count: this.isFirstFitting || !this.isInverse ? undefined : this.count,
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
|
|
|
@ -95,9 +95,9 @@
|
||||||
<span>C to E : </span>
|
<span>C to E : </span>
|
||||||
<span>
|
<span>
|
||||||
E =
|
E =
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramA" /> +
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramA" @change="newCalibrationFuncModelChange()"/> +
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramB" /> *C +
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramB" @change="newCalibrationFuncModelChange()"/> *C +
|
||||||
<a-input-number size="small" v-model="newCalibrationFuncModel.paramC" /> *C <sup>2</sup>
|
<a-input-number size="small" v-model="newCalibrationFuncModel.paramC" @change="newCalibrationFuncModelChange()"/> *C <sup>2</sup>
|
||||||
</span>
|
</span>
|
||||||
</p>
|
</p>
|
||||||
<div class="func">
|
<div class="func">
|
||||||
|
@ -154,6 +154,7 @@ import { exportEchartImg, getXAxisAndYAxisByPosition, splitAxis } from '@/utils/
|
||||||
import { cloneDeep } from 'lodash'
|
import { cloneDeep } from 'lodash'
|
||||||
import { isNullOrUndefined } from '@/utils/util'
|
import { isNullOrUndefined } from '@/utils/util'
|
||||||
import SampleDataMixin from '@/views/spectrumAnalysis/SampleDataMixin'
|
import SampleDataMixin from '@/views/spectrumAnalysis/SampleDataMixin'
|
||||||
|
import { f } from 'vue-area-linkage'
|
||||||
|
|
||||||
const initialGammaSpectrumChartOption = {
|
const initialGammaSpectrumChartOption = {
|
||||||
grid: {
|
grid: {
|
||||||
|
@ -571,6 +572,11 @@ export default {
|
||||||
energy,
|
energy,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// add之后 需要清空chart黄色的线 20231028:Xiao
|
||||||
|
if(this.figureChartOption.series[1].data) {
|
||||||
|
this.figureChartOption.series[1].data = []
|
||||||
|
}
|
||||||
|
|
||||||
this.figureChartOption.series[1].markPoint.data.push({ xAxis: channel, yAxis: energy })
|
this.figureChartOption.series[1].markPoint.data.push({ xAxis: channel, yAxis: energy })
|
||||||
|
|
||||||
const { min, max } = this.getFigureChartMaxAndMin()
|
const { min, max } = this.getFigureChartMaxAndMin()
|
||||||
|
@ -593,6 +599,18 @@ export default {
|
||||||
|
|
||||||
this.isInverse = true
|
this.isInverse = true
|
||||||
},
|
},
|
||||||
|
// 输入框发生变化
|
||||||
|
newCalibrationFuncModelChange(val,a) {
|
||||||
|
// 输入内容的时候 需要清空table数据 20231028:Xiao
|
||||||
|
this.list = []
|
||||||
|
// 需要清空chart黄色的线 20231028:Xiao
|
||||||
|
if(this.figureChartOption.series[1].data) {
|
||||||
|
this.figureChartOption.series[1].data = []
|
||||||
|
}
|
||||||
|
if(this.figureChartOption.series[1].markPoint.data) {
|
||||||
|
this.figureChartOption.series[1].markPoint.data = []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
// 删除表格里的单项
|
// 删除表格里的单项
|
||||||
handleDel(index) {
|
handleDel(index) {
|
||||||
|
@ -634,15 +652,20 @@ export default {
|
||||||
// 点击Fitting按钮执行重新计算
|
// 点击Fitting按钮执行重新计算
|
||||||
async handleFitting() {
|
async handleFitting() {
|
||||||
const hasEmpty = Object.entries(this.newCalibrationFuncModel).some(([_, v]) => !v)
|
const hasEmpty = Object.entries(this.newCalibrationFuncModel).some(([_, v]) => !v)
|
||||||
if (hasEmpty) {
|
if (hasEmpty && this.list.length < 3) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
const { success, result, message } = await postAction('/spectrumAnalysis/fitting', {
|
const { success, result, message } = await postAction('/spectrumAnalysis/fitting', {
|
||||||
...this.newCalibrationFuncModel,
|
...this.newCalibrationFuncModel,
|
||||||
tempPoints: this.isFirstFitting
|
// 修改逻辑,如果列表中有数据 以列表的数据优先进行分析 20231028:Xiao
|
||||||
? this.oldScatterSeries
|
tempPoints: this.list.length > 0
|
||||||
: this.list.map((item) => ({ x: item.channel, y: item.energy })),
|
? this.list.map((item) => ({ x: item.channel, y: item.energy }))
|
||||||
|
: this.oldScatterSeries,
|
||||||
|
|
||||||
|
// tempPoints: this.isFirstFitting
|
||||||
|
// ? this.oldScatterSeries
|
||||||
|
// : this.list.map((item) => ({ x: item.channel, y: item.energy })),
|
||||||
count: this.isFirstFitting || !this.isInverse ? undefined : this.count,
|
count: this.isFirstFitting || !this.isInverse ? undefined : this.count,
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
|
|
|
@ -37,28 +37,35 @@ export default {
|
||||||
detBg: [],
|
detBg: [],
|
||||||
gasBg: [],
|
gasBg: [],
|
||||||
qc: [],
|
qc: [],
|
||||||
sample: []
|
sample: [],
|
||||||
},
|
},
|
||||||
isLoading: true,
|
isLoading: true,
|
||||||
fileName: '',
|
fileName: '',
|
||||||
currTab: 1
|
currTab: 1,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async getContent() {
|
async getContent() {
|
||||||
try {
|
try {
|
||||||
this.isLoading = true
|
this.isLoading = true
|
||||||
const { sampleId, dbName, sampleFileName, gasFileName, detFileName, qcFileName } = this.newSampleData
|
const {
|
||||||
|
sampleId,
|
||||||
|
dbName,
|
||||||
|
inputFileName: sampleFileName,
|
||||||
|
gasFileName,
|
||||||
|
detFileName,
|
||||||
|
qcFileName,
|
||||||
|
} = this.newSampleData
|
||||||
const { success, result, message } = await getAction('/spectrumAnalysis/viewSpectrum', {
|
const { success, result, message } = await getAction('/spectrumAnalysis/viewSpectrum', {
|
||||||
sampleId,
|
sampleId,
|
||||||
dbName,
|
dbName,
|
||||||
sampleFileName,
|
sampleFileName,
|
||||||
gasFileName,
|
gasFileName,
|
||||||
detFileName,
|
detFileName,
|
||||||
qcFileName
|
qcFileName,
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
if(result) {
|
if (result) {
|
||||||
this.content = result
|
this.content = result
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -78,42 +85,42 @@ export default {
|
||||||
this.currTab = key
|
this.currTab = key
|
||||||
},
|
},
|
||||||
handleOk() {
|
handleOk() {
|
||||||
this.fileName=""
|
this.fileName = ''
|
||||||
let text = ""
|
let text = ''
|
||||||
if (this.currTab == 1) {
|
if (this.currTab == 1) {
|
||||||
text=this.content.sample.join('\n')
|
text = this.content.sample.join('\n')
|
||||||
} else if (this.currTab == 2) {
|
} else if (this.currTab == 2) {
|
||||||
text=this.content.gasBg.join('\n')
|
text = this.content.gasBg.join('\n')
|
||||||
}else if (this.currTab == 3) {
|
} else if (this.currTab == 3) {
|
||||||
text=this.content.detBg.join('\n')
|
text = this.content.detBg.join('\n')
|
||||||
}else if (this.currTab == 4) {
|
} else if (this.currTab == 4) {
|
||||||
text=this.content.qc.join('\n')
|
text = this.content.qc.join('\n')
|
||||||
}
|
}
|
||||||
if (text) {
|
if (text) {
|
||||||
let strData = new Blob([text], { type: 'text/plain;charset=utf-8' });
|
let strData = new Blob([text], { type: 'text/plain;charset=utf-8' })
|
||||||
// saveAs(strData, `GammaViewer Log.txt`)
|
// saveAs(strData, `GammaViewer Log.txt`)
|
||||||
let _this = this
|
let _this = this
|
||||||
this.$confirm({
|
this.$confirm({
|
||||||
title: 'Please enter file name',
|
title: 'Please enter file name',
|
||||||
content: h => <a-input v-model={_this.fileName} />,
|
content: (h) => <a-input v-model={_this.fileName} />,
|
||||||
okText: 'Cancle',
|
okText: 'Cancle',
|
||||||
cancelText: 'Save',
|
cancelText: 'Save',
|
||||||
okButtonProps: {style: {backgroundColor: "#b98326", color: "#fff", borderColor: "transparent"}},
|
okButtonProps: { style: { backgroundColor: '#b98326', color: '#fff', borderColor: 'transparent' } },
|
||||||
cancelButtonProps: {style: {color: "#fff", backgroundColor: "#31aab0", borderColor: "transparent"}},
|
cancelButtonProps: { style: { color: '#fff', backgroundColor: '#31aab0', borderColor: 'transparent' } },
|
||||||
onOk() {
|
onOk() {
|
||||||
console.log('Cancel');
|
console.log('Cancel')
|
||||||
},
|
},
|
||||||
onCancel() {
|
onCancel() {
|
||||||
if (_this.fileName) {
|
if (_this.fileName) {
|
||||||
saveAs(strData, `${_this.fileName}.txt`)
|
saveAs(strData, `${_this.fileName}.txt`)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
});
|
})
|
||||||
} else {
|
} else {
|
||||||
this.$message.warning("No data can be saved!")
|
this.$message.warning('No data can be saved!')
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
@ -75,6 +75,7 @@ const columns = [
|
||||||
title: 'Col.Stop',
|
title: 'Col.Stop',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
dataIndex: 'collectStop',
|
dataIndex: 'collectStop',
|
||||||
|
sorter: true,
|
||||||
width: 170,
|
width: 170,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -434,7 +435,7 @@ export default {
|
||||||
allowClear: true,
|
allowClear: true,
|
||||||
},
|
},
|
||||||
style: {
|
style: {
|
||||||
width: '264px',
|
width: '207px',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -465,7 +466,7 @@ export default {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
style: {
|
style: {
|
||||||
width: '19%',
|
width: '16%',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -481,8 +482,43 @@ export default {
|
||||||
},
|
},
|
||||||
style: {
|
style: {
|
||||||
paddingRight: 0,
|
paddingRight: 0,
|
||||||
marginRight: '22px',
|
marginRight: '8px',
|
||||||
width: '19%',
|
width: '13%',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: 'Status',
|
||||||
|
type: 'custom-select',
|
||||||
|
name: 'status',
|
||||||
|
props: {
|
||||||
|
options: [
|
||||||
|
{
|
||||||
|
label: 'U',
|
||||||
|
value: 'U',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: 'A',
|
||||||
|
value: 'A',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: 'P',
|
||||||
|
value: 'P',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: 'R',
|
||||||
|
value: 'R',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: 'F',
|
||||||
|
value: 'F',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
allowClear: true,
|
||||||
|
},
|
||||||
|
style: {
|
||||||
|
width: '14%',
|
||||||
|
|
||||||
|
marginRight: '10px',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
|
@ -46,9 +46,7 @@
|
||||||
<!-- 站点操作 -->
|
<!-- 站点操作 -->
|
||||||
<div class="station-operation" v-show="active == 1">
|
<div class="station-operation" v-show="active == 1">
|
||||||
<div class="station-operation-stations">
|
<div class="station-operation-stations">
|
||||||
<div class="map-pane-content-header">
|
<div class="map-pane-content-header">Stations</div>
|
||||||
Stations
|
|
||||||
</div>
|
|
||||||
<div class="map-pane-content-main">
|
<div class="map-pane-content-main">
|
||||||
<div class="station-operation-stations-selection">
|
<div class="station-operation-stations-selection">
|
||||||
<a-space>
|
<a-space>
|
||||||
|
@ -58,7 +56,7 @@
|
||||||
>
|
>
|
||||||
</a-space>
|
</a-space>
|
||||||
</div>
|
</div>
|
||||||
<a-divider style="background-color: #0a544e; margin: 10px 0 0;"></a-divider>
|
<a-divider style="background-color: #0a544e; margin: 10px 0 0"></a-divider>
|
||||||
|
|
||||||
<!-- 站点选择树 -->
|
<!-- 站点选择树 -->
|
||||||
<div class="station-list-tree">
|
<div class="station-list-tree">
|
||||||
|
@ -72,17 +70,13 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="station-operation-infomation">
|
<div class="station-operation-infomation">
|
||||||
<div class="map-pane-content-header">
|
<div class="map-pane-content-header">Infomation</div>
|
||||||
Infomation
|
|
||||||
</div>
|
|
||||||
<div class="map-pane-content-main">
|
<div class="map-pane-content-main">
|
||||||
<div class="station-operation-infomation-content">
|
<div class="station-operation-infomation-content">
|
||||||
<p class="radius-title">Radius</p>
|
<p class="radius-title">Radius</p>
|
||||||
<div class="radius-search">
|
<div class="radius-search">
|
||||||
<a-input suffix="KM" v-model="radius" type="number"></a-input>
|
<a-input suffix="KM" v-model="radius" type="number"></a-input>
|
||||||
<a-button type="primary" @click="handleSearchByRadius">
|
<a-button type="primary" @click="handleSearchByRadius"> Search </a-button>
|
||||||
Search
|
|
||||||
</a-button>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="radius-table">
|
<div class="radius-table">
|
||||||
<a-table
|
<a-table
|
||||||
|
@ -102,9 +96,7 @@
|
||||||
|
|
||||||
<!-- 站点筛选 -->
|
<!-- 站点筛选 -->
|
||||||
<div class="station-filter" v-show="active == 2">
|
<div class="station-filter" v-show="active == 2">
|
||||||
<div class="map-pane-content-header">
|
<div class="map-pane-content-header">Filter</div>
|
||||||
Filter
|
|
||||||
</div>
|
|
||||||
<div class="map-pane-content-main">
|
<div class="map-pane-content-main">
|
||||||
<div class="station-filter-list">
|
<div class="station-filter-list">
|
||||||
<div
|
<div
|
||||||
|
@ -122,7 +114,7 @@
|
||||||
<a-checkbox v-model="filterItem.checked"></a-checkbox>
|
<a-checkbox v-model="filterItem.checked"></a-checkbox>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<a-divider style="background-color: #0a544e; margin: 10px 0 0;"></a-divider>
|
<a-divider style="background-color: #0a544e; margin: 10px 0 0"></a-divider>
|
||||||
<!-- 数据质量类型 -->
|
<!-- 数据质量类型 -->
|
||||||
<div class="station-data-quality-list">
|
<div class="station-data-quality-list">
|
||||||
<div
|
<div
|
||||||
|
@ -162,9 +154,7 @@
|
||||||
<div class="data-receive-status-list-container">
|
<div class="data-receive-status-list-container">
|
||||||
<div class="data-receive-status-list-item">
|
<div class="data-receive-status-list-item">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
<span>
|
<span> Station </span>
|
||||||
Particulate Station
|
|
||||||
</span>
|
|
||||||
<img src="@/assets/images/station-operation/toggle.png" @click="leftPaneShow = !leftPaneShow" />
|
<img src="@/assets/images/station-operation/toggle.png" @click="leftPaneShow = !leftPaneShow" />
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
|
@ -177,9 +167,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="data-receive-status-list-item">
|
<div class="data-receive-status-list-item">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
<span>
|
<span> Attribute Configuration </span>
|
||||||
Attribute Configuration
|
|
||||||
</span>
|
|
||||||
<img src="@/assets/images/station-operation/toggle.png" @click="leftPaneShow = !leftPaneShow" />
|
<img src="@/assets/images/station-operation/toggle.png" @click="leftPaneShow = !leftPaneShow" />
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
|
@ -233,10 +221,26 @@
|
||||||
<!-- 右侧图表展示栏 -->
|
<!-- 右侧图表展示栏 -->
|
||||||
<div class="data-receive-status-chart" :class="{ 'on-screen': !leftPaneShow }">
|
<div class="data-receive-status-chart" :class="{ 'on-screen': !leftPaneShow }">
|
||||||
<template v-if="showChart">
|
<template v-if="showChart">
|
||||||
<RealTimeDataChart ref="realtimeChartRef" :spinning="spinLoading" :list="statusList" :scale-settings="initialDataRecieveSettings" />
|
<RealTimeDataChart
|
||||||
|
ref="realtimeChartRef"
|
||||||
|
:spinning="spinLoading"
|
||||||
|
:list="statusList"
|
||||||
|
:scale-settings="initialDataRecieveSettings"
|
||||||
|
/>
|
||||||
<resize-observer @notify="handleResize" />
|
<resize-observer @notify="handleResize" />
|
||||||
</template>
|
</template>
|
||||||
<div v-show="maskVisi" style="z-index: 1;position: absolute;top: 0;left: 0;width:100%;height: 100%;background: rgba(0, 0, 0, .45);"></div>
|
<div
|
||||||
|
v-show="maskVisi"
|
||||||
|
style="
|
||||||
|
z-index: 1;
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background: rgba(0, 0, 0, 0.45);
|
||||||
|
"
|
||||||
|
></div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 右侧图表展示栏结束 -->
|
<!-- 右侧图表展示栏结束 -->
|
||||||
</div>
|
</div>
|
||||||
|
@ -265,44 +269,44 @@ const filterList = [
|
||||||
title: 'IMS RN Station(P)',
|
title: 'IMS RN Station(P)',
|
||||||
type: MarkerType.ImsRnStationP,
|
type: MarkerType.ImsRnStationP,
|
||||||
icon: FilterIcon[MarkerType.ImsRnStationP],
|
icon: FilterIcon[MarkerType.ImsRnStationP],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'IMS RN Station(G)',
|
title: 'IMS RN Station(G)',
|
||||||
type: MarkerType.ImsRnStationG,
|
type: MarkerType.ImsRnStationG,
|
||||||
icon: FilterIcon[MarkerType.ImsRnStationG],
|
icon: FilterIcon[MarkerType.ImsRnStationG],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'NRL',
|
title: 'NRL',
|
||||||
type: MarkerType.NRL,
|
type: MarkerType.NRL,
|
||||||
icon: FilterIcon[MarkerType.NRL],
|
icon: FilterIcon[MarkerType.NRL],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Nuclear Facilities',
|
title: 'Nuclear Facilities',
|
||||||
type: MarkerType.NuclearFacility,
|
type: MarkerType.NuclearFacility,
|
||||||
icon: FilterIcon[MarkerType.NuclearFacility],
|
icon: FilterIcon[MarkerType.NuclearFacility],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Groud monitoring station',
|
title: 'Groud monitoring station',
|
||||||
type: MarkerType.GroudMonitoringStation,
|
type: MarkerType.GroudMonitoringStation,
|
||||||
icon: FilterIcon[MarkerType.GroudMonitoringStation],
|
icon: FilterIcon[MarkerType.GroudMonitoringStation],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'car',
|
title: 'car',
|
||||||
type: MarkerType.Car,
|
type: MarkerType.Car,
|
||||||
icon: FilterIcon[MarkerType.Car],
|
icon: FilterIcon[MarkerType.Car],
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'ship',
|
title: 'ship',
|
||||||
type: MarkerType.Ship,
|
type: MarkerType.Ship,
|
||||||
icon: FilterIcon[MarkerType.Ship],
|
icon: FilterIcon[MarkerType.Ship],
|
||||||
checked: true
|
checked: true,
|
||||||
}
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
// Filter中的数据质量列表
|
// Filter中的数据质量列表
|
||||||
|
@ -310,23 +314,23 @@ const dataQualityList = [
|
||||||
{
|
{
|
||||||
title: 'Excellent data quality',
|
title: 'Excellent data quality',
|
||||||
icon: FilterIcon.State1,
|
icon: FilterIcon.State1,
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Good data quality',
|
title: 'Good data quality',
|
||||||
icon: FilterIcon.State2,
|
icon: FilterIcon.State2,
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Poor data quality',
|
title: 'Poor data quality',
|
||||||
icon: FilterIcon.State3,
|
icon: FilterIcon.State3,
|
||||||
checked: true
|
checked: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Signal interruption',
|
title: 'Signal interruption',
|
||||||
icon: FilterIcon.State4,
|
icon: FilterIcon.State4,
|
||||||
checked: true
|
checked: true,
|
||||||
}
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
// infomation-radius 表格列
|
// infomation-radius 表格列
|
||||||
|
@ -335,57 +339,57 @@ const columns = [
|
||||||
title: 'nuclearfaclity',
|
title: 'nuclearfaclity',
|
||||||
dataIndex: 'nuclearFacilityName',
|
dataIndex: 'nuclearFacilityName',
|
||||||
width: 100,
|
width: 100,
|
||||||
ellipsis: true
|
ellipsis: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'station',
|
title: 'station',
|
||||||
dataIndex: 'stationName',
|
dataIndex: 'stationName',
|
||||||
width: 70,
|
width: 70,
|
||||||
ellipsis: true
|
ellipsis: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'distance',
|
title: 'distance',
|
||||||
dataIndex: 'radius',
|
dataIndex: 'radius',
|
||||||
width: 80,
|
width: 80,
|
||||||
ellipsis: true
|
ellipsis: true,
|
||||||
}
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
// Attribute Configuration 检验规则(自定义,非a-form校验)
|
// Attribute Configuration 检验规则(自定义,非a-form校验)
|
||||||
const rules = {
|
const rules = {
|
||||||
cacheTime: {
|
cacheTime: {
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please Input Cache Time'
|
message: 'Please Input Cache Time',
|
||||||
},
|
},
|
||||||
scaleInterval: {
|
scaleInterval: {
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please Input Scale Interval'
|
message: 'Please Input Scale Interval',
|
||||||
},
|
},
|
||||||
timelineLength: {
|
timelineLength: {
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please Input Timeline Length'
|
message: 'Please Input Timeline Length',
|
||||||
},
|
},
|
||||||
updateIntervalTime: {
|
updateIntervalTime: {
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please Input Update Interval'
|
message: 'Please Input Update Interval',
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
panMovePix: {
|
panMovePix: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default: 500
|
default: 500,
|
||||||
},
|
},
|
||||||
|
|
||||||
treeData: {
|
treeData: {
|
||||||
type: Array
|
type: Array,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
CustomModal,
|
CustomModal,
|
||||||
CustomTree,
|
CustomTree,
|
||||||
RealTimeDataChart
|
RealTimeDataChart,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
this.columns = columns
|
this.columns = columns
|
||||||
|
@ -409,7 +413,7 @@ export default {
|
||||||
cacheTime: 15,
|
cacheTime: 15,
|
||||||
scaleInterval: 120,
|
scaleInterval: 120,
|
||||||
timelineLength: 1440,
|
timelineLength: 1440,
|
||||||
updateIntervalTime: 5
|
updateIntervalTime: 5,
|
||||||
}, // 数据接收状态配置
|
}, // 数据接收状态配置
|
||||||
isSavingDataRecieveSettings: false,
|
isSavingDataRecieveSettings: false,
|
||||||
|
|
||||||
|
@ -425,7 +429,7 @@ export default {
|
||||||
spinLoading: false,
|
spinLoading: false,
|
||||||
maskVisi: false,
|
maskVisi: false,
|
||||||
|
|
||||||
stationInfo: undefined
|
stationInfo: undefined,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -448,9 +452,9 @@ export default {
|
||||||
this.map = map
|
this.map = map
|
||||||
this.circleLayer = new VectorLayer({
|
this.circleLayer = new VectorLayer({
|
||||||
source: new VectorSource({
|
source: new VectorSource({
|
||||||
features: []
|
features: [],
|
||||||
}),
|
}),
|
||||||
properties: { name: 'eventCircle' }
|
properties: { name: 'eventCircle' },
|
||||||
})
|
})
|
||||||
this.map.addLayer(this.circleLayer)
|
this.map.addLayer(this.circleLayer)
|
||||||
},
|
},
|
||||||
|
@ -498,12 +502,12 @@ export default {
|
||||||
|
|
||||||
// 根据 Filter 筛选Marker
|
// 根据 Filter 筛选Marker
|
||||||
emitFilter() {
|
emitFilter() {
|
||||||
const filterType = this.filterList.filter(item => item.checked).map(item => item.type)
|
const filterType = this.filterList.filter((item) => item.checked).map((item) => item.type)
|
||||||
const filterDataQuality = this.dataQualityList.filter(item => item.checked).map(item => item.title)
|
const filterDataQuality = this.dataQualityList.filter((item) => item.checked).map((item) => item.title)
|
||||||
|
|
||||||
this.$emit('filterMarker', {
|
this.$emit('filterMarker', {
|
||||||
filterType,
|
filterType,
|
||||||
filterDataQuality
|
filterDataQuality,
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -516,7 +520,7 @@ export default {
|
||||||
handleSelectAll() {
|
handleSelectAll() {
|
||||||
this.checkedKeys = this.treeData.reduce((prev, curr) => {
|
this.checkedKeys = this.treeData.reduce((prev, curr) => {
|
||||||
prev.push(curr.stationId)
|
prev.push(curr.stationId)
|
||||||
prev.push(...curr.children.map(child => child.stationId))
|
prev.push(...curr.children.map((child) => child.stationId))
|
||||||
return prev
|
return prev
|
||||||
}, [])
|
}, [])
|
||||||
},
|
},
|
||||||
|
@ -549,16 +553,16 @@ export default {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
const stationIds = this.checkedKeys.filter(key => -1 == key.toString().indexOf('root_'))
|
const stationIds = this.checkedKeys.filter((key) => -1 == key.toString().indexOf('root_'))
|
||||||
try {
|
try {
|
||||||
this.isGettingInfomationList = true
|
this.isGettingInfomationList = true
|
||||||
const {
|
const {
|
||||||
success,
|
success,
|
||||||
result: { GIS: markerList, table },
|
result: { GIS: markerList, table },
|
||||||
message
|
message,
|
||||||
} = await postAction('/jeecg-station-operation/stationOperation/getHitEquList', {
|
} = await postAction('/jeecg-station-operation/stationOperation/getHitEquList', {
|
||||||
radius: this.radius,
|
radius: this.radius,
|
||||||
stationIds
|
stationIds,
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
const source = this.circleLayer.getSource()
|
const source = this.circleLayer.getSource()
|
||||||
|
@ -573,7 +577,7 @@ export default {
|
||||||
this.dataSource = data // 设置Infomation表格内容
|
this.dataSource = data // 设置Infomation表格内容
|
||||||
|
|
||||||
this.stationList = [] // 台站列表
|
this.stationList = [] // 台站列表
|
||||||
markerList.forEach(markerItem => {
|
markerList.forEach((markerItem) => {
|
||||||
// 返回的数据类型不符合要求,根据stationId判断是否是台站,增加台站类型和转换字段,以便进行marker的绘制
|
// 返回的数据类型不符合要求,根据stationId判断是否是台站,增加台站类型和转换字段,以便进行marker的绘制
|
||||||
if (markerItem.stationId) {
|
if (markerItem.stationId) {
|
||||||
// 是台站
|
// 是台站
|
||||||
|
@ -656,13 +660,13 @@ export default {
|
||||||
try {
|
try {
|
||||||
await this.validateForm(this.dataRecieveStatusModel, rules)
|
await this.validateForm(this.dataRecieveStatusModel, rules)
|
||||||
try {
|
try {
|
||||||
const stationIds = this.dataStatusCheckedKeys.filter(key => -1 == key.toString().indexOf('root_'))
|
const stationIds = this.dataStatusCheckedKeys.filter((key) => -1 == key.toString().indexOf('root_'))
|
||||||
this.isSavingDataRecieveSettings = true
|
this.isSavingDataRecieveSettings = true
|
||||||
const { success, message } = await postAction(
|
const { success, message } = await postAction(
|
||||||
'/jeecg-station-operation/sysUserFocusStation/saveUserFocusByUserId',
|
'/jeecg-station-operation/sysUserFocusStation/saveUserFocusByUserId',
|
||||||
{
|
{
|
||||||
stationIds,
|
stationIds,
|
||||||
...this.dataRecieveStatusModel
|
...this.dataRecieveStatusModel,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
if (success) {
|
if (success) {
|
||||||
|
@ -704,7 +708,7 @@ export default {
|
||||||
const { success, result, message } = await getAction(
|
const { success, result, message } = await getAction(
|
||||||
'/jeecg-station-operation/sysUserFocusStation/findUserFocusByUserId',
|
'/jeecg-station-operation/sysUserFocusStation/findUserFocusByUserId',
|
||||||
{
|
{
|
||||||
userId: this.$store.getters.userInfo.id
|
userId: this.$store.getters.userInfo.id,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
if (success) {
|
if (success) {
|
||||||
|
@ -740,24 +744,25 @@ export default {
|
||||||
const { success, result, message } = await getAction(
|
const { success, result, message } = await getAction(
|
||||||
'/jeecg-station-operation/stationOperation/getDataReceivingStatus',
|
'/jeecg-station-operation/stationOperation/getDataReceivingStatus',
|
||||||
{
|
{
|
||||||
userId: this.$store.getters.userInfo.id
|
userId: this.$store.getters.userInfo.id,
|
||||||
|
oneStationId: (this.stationInfo && this.stationInfo.stationId) || '',
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
this.maskVisi = false
|
this.maskVisi = false
|
||||||
this.spinLoading = false
|
this.spinLoading = false
|
||||||
if (success) {
|
if (success) {
|
||||||
// 如果从地图的Marker上点开,且点开的为已关注的台站,则把这个台站放到前面
|
// 如果从地图的Marker上点开,且点开的为已关注的台站,则把这个台站放到前面
|
||||||
if(this.stationInfo) {
|
if (this.stationInfo) {
|
||||||
result.sort(({ stationId }) => stationId == this.stationInfo.stationId? -1: 1) // chrome 和 firefox下表现不同,但都能将目标值排到第一个
|
result.sort(({ stationId }) => (stationId == this.stationInfo.stationId ? -1 : 1)) // chrome 和 firefox下表现不同,但都能将目标值排到第一个
|
||||||
}
|
}
|
||||||
const statusList = []
|
const statusList = []
|
||||||
result.forEach(item => {
|
result.forEach((item) => {
|
||||||
const detectorArr = item.detectors[item.stationId]
|
const detectorArr = item.detectors[item.stationId]
|
||||||
detectorArr.forEach(detector => {
|
detectorArr.forEach((detector) => {
|
||||||
Object.values(detector).forEach(value => {
|
Object.values(detector).forEach((value) => {
|
||||||
statusList.push({
|
statusList.push({
|
||||||
title: `${item.stationCode} ${value.detectorId}`,
|
title: `${item.stationCode} ${value.detectorId}`,
|
||||||
dataList: value.dataList
|
dataList: value.dataList,
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
@ -777,27 +782,27 @@ export default {
|
||||||
|
|
||||||
handleResize() {
|
handleResize() {
|
||||||
this.$refs.realtimeChartRef.resize()
|
this.$refs.realtimeChartRef.resize()
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
dataStatusModalVisible(val) {
|
dataStatusModalVisible(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
this.dataStatusCheckedKeys = this.initialDataRecieveSettings.sysUserFocusStations.map(item =>
|
this.dataStatusCheckedKeys = this.initialDataRecieveSettings.sysUserFocusStations.map((item) =>
|
||||||
parseInt(item.stationId)
|
parseInt(item.stationId)
|
||||||
)
|
)
|
||||||
this.dataRecieveStatusModel = {
|
this.dataRecieveStatusModel = {
|
||||||
cacheTime: this.initialDataRecieveSettings.cacheTime,
|
cacheTime: this.initialDataRecieveSettings.cacheTime,
|
||||||
scaleInterval: this.initialDataRecieveSettings.scaleInterval,
|
scaleInterval: this.initialDataRecieveSettings.scaleInterval,
|
||||||
timelineLength: this.initialDataRecieveSettings.timelineLength,
|
timelineLength: this.initialDataRecieveSettings.timelineLength,
|
||||||
updateIntervalTime: this.initialDataRecieveSettings.updateIntervalTime
|
updateIntervalTime: this.initialDataRecieveSettings.updateIntervalTime,
|
||||||
}
|
}
|
||||||
|
|
||||||
this.startGetDataReceiveStatusList()
|
this.startGetDataReceiveStatusList()
|
||||||
} else {
|
} else {
|
||||||
clearInterval(this.timer)
|
clearInterval(this.timer)
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
@ -821,7 +826,7 @@ export default {
|
||||||
// 操作栏
|
// 操作栏
|
||||||
&-operators {
|
&-operators {
|
||||||
user-select: none;
|
user-select: none;
|
||||||
pointer-events:all;
|
pointer-events: all;
|
||||||
height: 200px;
|
height: 200px;
|
||||||
|
|
||||||
img {
|
img {
|
||||||
|
|
|
@ -228,6 +228,7 @@ export default {
|
||||||
timer: null,
|
timer: null,
|
||||||
updataFilterType: [],
|
updataFilterType: [],
|
||||||
updataFilterDataQuality: [],
|
updataFilterDataQuality: [],
|
||||||
|
httpNum: 0,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -268,6 +269,7 @@ export default {
|
||||||
|
|
||||||
// 查询台站数据提供率及有效率
|
// 查询台站数据提供率及有效率
|
||||||
async getDataProvisionEfficiency(arr, str) {
|
async getDataProvisionEfficiency(arr, str) {
|
||||||
|
this.httpNum++
|
||||||
if (str && this.$route.path == '/station-operation') {
|
if (str && this.$route.path == '/station-operation') {
|
||||||
this.$message.loading({ content: 'Loading station data, please wait...', key, duration: 0 })
|
this.$message.loading({ content: 'Loading station data, please wait...', key, duration: 0 })
|
||||||
}
|
}
|
||||||
|
@ -279,6 +281,7 @@ export default {
|
||||||
this.$message.success({ content: 'Loaded!', key, duration: 2 })
|
this.$message.success({ content: 'Loaded!', key, duration: 2 })
|
||||||
}
|
}
|
||||||
res.result.forEach((item) => {
|
res.result.forEach((item) => {
|
||||||
|
if (Object.prototype.toString.call(item) == '[object Object]') {
|
||||||
arr.forEach((el) => {
|
arr.forEach((el) => {
|
||||||
if (
|
if (
|
||||||
parseInt(item.id) == el.stationId &&
|
parseInt(item.id) == el.stationId &&
|
||||||
|
@ -289,6 +292,7 @@ export default {
|
||||||
item.stationId = el.stationId
|
item.stationId = el.stationId
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.orgStationList = res.result
|
this.orgStationList = res.result
|
||||||
let arrA = []
|
let arrA = []
|
||||||
|
@ -325,10 +329,15 @@ export default {
|
||||||
} else if (arrA.length == 0 || arrB.length == 0 || arrC.length == 0) {
|
} else if (arrA.length == 0 || arrB.length == 0 || arrC.length == 0) {
|
||||||
this.upDateStationList = []
|
this.upDateStationList = []
|
||||||
}
|
}
|
||||||
setTimeout(() => {
|
this.timer = setTimeout(() => {
|
||||||
this.getDataProvisionEfficiency(this.markerList_clone)
|
this.getDataProvisionEfficiency(this.markerList_clone)
|
||||||
}, 10000)
|
}, 10000)
|
||||||
} else {
|
} else {
|
||||||
|
if (this.httpNum <= 5) {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.getDataProvisionEfficiency(this.markerList_clone)
|
||||||
|
}, 5000)
|
||||||
|
}
|
||||||
this.$message.warning('This operation fails. Contact your system administrator')
|
this.$message.warning('This operation fails. Contact your system administrator')
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue
Block a user