This commit is contained in:
ghusermoon
2020-06-01 14:21:47 +08:00
parent 5cf6f581f6
commit 9c5d503b51
17 changed files with 2956 additions and 1715 deletions

View File

@@ -2,7 +2,8 @@ let math = require('mathjs')
// 定义一个计算类来计算数据
class computedFunc {
constructor (transBeforeData) {
this.transBeforeData = transBeforeData
this.transBeforeData = transBeforeData
console.log(transBeforeData,"class 6")
// 处理好的数据需要返回的值 ===========all
this.restur = {
// 表头数据
@@ -388,6 +389,7 @@ class computedFunc {
labelId: 'table_line0',
label: '时间'
})
console.log(this.transBeforeData)
this.transBeforeData.areaName.forEach((itemTime, indexTime) => {
this.restur.tableLine.push({
labelId: 'table_line' + (indexTime + 1),

File diff suppressed because it is too large Load Diff

View File

@@ -217,7 +217,7 @@ export default {
// 监听左侧菜单的数据变化
defaultDataRight: {
handler (val) {
console.log(val, '左侧数据变化chartsCut')
// console.log(val, '左侧数据变化chartsCut')
if (val) {
// 初始化公共数据
if (!this.$store.state.advancedSearchState) {
@@ -234,15 +234,15 @@ export default {
},
// 监听数据渲染变化
stateDataGetVal (newVal, oldVal) {
console.log(this.$store.state.transBefore, '啦啦啦')
// console.log(this.$store.state.transBefore, '啦啦啦')
if (!newVal) {
// this.showLabelArea()
}
},
labelAreaState (newVal, oldVal) {
console.log(newVal, 'kkkkkkkkkkkkkkkkkkkkkkk120')
// console.log(newVal, 'kkkkkkkkkkkkkkkkkkkkkkk120')
if (newVal && !this.$store.state.advancedSearchState) {
console.log('kkkkkkkkkkkkkkkkkkkkkkk120')
// console.log('kkkkkkkkkkkkkkkkkkkkkkk120')
// this.showLabelArea()
}
},
@@ -255,7 +255,7 @@ export default {
} else if (this.$store.state.SelecttDimension.row === 'sj' && this.$store.state.SelecttDimension.col === 'zb') {
this.$store.state.SelecttDimension.col = 'dq'
}
console.log(this.$store.state.transBefore, 'bbbbbbbbbbbbbbbbbbb')
// console.log(this.$store.state.transBefore, 'bbbbbbbbbbbbbbbbbbb')
this.$nextTick(() => {
this.$parent.tellChangeFan(false)
})
@@ -275,7 +275,7 @@ export default {
*
*/
areaDimensionDo (newVal) {
console.log('你你你你你你?')
// console.log('你你你你你你?')
if (newVal) {
if (this.$store.state.noSelecttDimension === 'sj') {
this.optionsDimension = this.$store.state.dataArealabelTime.timeArr.map((item, index) => {
@@ -300,14 +300,14 @@ export default {
})
}
this.valueDimension = this.$store.state.newSelectChangeData
console.log(this.valueDimension, 'this.valueDimension0')
// console.log(this.valueDimension, 'this.valueDimension0')
// 告诉父组件数据渲染完
this.$emit('emmitStateAd', false)
}
},
// 地区维度转换筛选
handleChangeDimension () {
console.log(this.valueDimension, 'this.valueDimension')
// console.log(this.valueDimension, 'this.valueDimension')
if (this.valueDimension) {
this.$parent.changeDimensionTrueChangeArea(this.valueDimension[0])
}
@@ -319,17 +319,17 @@ export default {
},
// 被选中时触发
choiceCallerArea (resu) {
console.log(resu[2], '5+656565')
// console.log(resu[2], '5+656565')
// this.$emit('statertfResu', resu[2])
},
// 被选中时触发
choiceCallerTime (resu) {
console.log(resu, '66666')
// console.log(resu, '66666')
// console.log(this.cityDefaultName)
// 改变选中值索引
if (this.$store.state.selectData !== undefined) {
console.log(this.$store.state.selectData, '被选中的值')
console.log(resu[2], '被选中的值2000')
// console.log(this.$store.state.selectData, '被选中的值')
// console.log(resu[2], '被选中的值2000')
this.$store.state.selectData = resu[2].indexID
this.showInputStu = false
@@ -340,12 +340,12 @@ export default {
// this.showInputStu = !this.showInputStu
},
changesInputStu () {
console.log(12569)
// console.log(12569)
this.showInputStu = !this.showInputStu
},
// 点击非下拉框内容时改变下拉状态(下拉怡然显示)
showKuangCat () {
console.log(1250)
// console.log(1250)
this.isHideProp = false
this.stateRTY = false
},
@@ -358,7 +358,7 @@ export default {
type: type
}
}).then(res => {
console.log(res, '下拉筛选条件')
// console.log(res, '下拉筛选条件')
// 请求接口完成 请求成功
if (res.data.code === 200) {
this.cityDataTime = Object.keys(res.data.data.list).map((item, index) => {
@@ -375,7 +375,7 @@ export default {
// 调用父组件的chuFachildChartCont方法渲染
}
}).catch((fail) => {
console.log(fail)
// console.log(fail)
})
},
stateInfor (val) {
@@ -387,7 +387,7 @@ export default {
},
// 指标地区数据渲染
showLabelArea () {
console.log(this.stateChangeSDF, this.$store.state.dataArealabelTime, '走走走')
// console.log(this.stateChangeSDF, this.$store.state.dataArealabelTime, '走走走')
if (this.$store.state.classifyIdDataState) {
if (!this.$store.state.advancedSearchState) { // 非高级查询
@@ -407,7 +407,7 @@ export default {
} else {
this.value = [this.options[1].value]
}
console.log(this.value, 'this.options')
// console.log(this.value, 'this.options')
// 告诉父组件已经完成任务
this.$emit('stateDFGHJ', true)
this.$emit('statertfResu', this.value[0])
@@ -427,18 +427,18 @@ export default {
} else {
this.value = [this.options[1].value]
}
console.log(this.value, 'this.options')
// console.log(this.value, 'this.options')
// 告诉父组件已经完成任务
this.$emit('stateDFGHJ', true)
this.$emit('statertfResu', this.value[0])
}
} else { // 高级查询
if (this.$route.query.type !== 'area') {
console.log('直接走1')
// console.log('直接走1')
this.$emit('stateDFGHJ', true)
} else {
if (this.stateChangeSDF) { // 指标
console.log(this.$store.state.yesNoClickZZ, 'this.$store.state.yesNoClickZZ')
// console.log(this.$store.state.yesNoClickZZ, 'this.$store.state.yesNoClickZZ')
if (this.$store.state.advancedSearchState && !this.yesNoClickXX) {
this.options = this.$store.state.advanceData.map((item, index) => {
return item.name
@@ -460,14 +460,14 @@ export default {
value: '序列',
label: '序列'
})
console.log(this.$store.state.defaultShowDataState, 'this.$store.state.defaultShowDataState10')
// console.log(this.$store.state.defaultShowDataState, 'this.$store.state.defaultShowDataState10')
if (this.$route.query.defaultLeftId === 'default' && this.$store.state.defaultShowDataState && this.$store.state.defaultShowLabelAreaState !== 'normal') {
this.value = [this.$store.state.newSelectLabelArea.sequenceCont]
} else {
console.log(this.options, 'this.optionsk102569')
// console.log(this.options, 'this.optionsk102569')
this.value = [this.options[1].value]
}
console.log(this.value, 'this.options')
// console.log(this.value, 'this.options')
// 告诉父组件已经完成任务
this.$emit('stateDFGHJ', true)
this.$emit('statertfResu', this.value[0])
@@ -493,13 +493,13 @@ export default {
value: '序列',
label: '序列'
})
console.log(this.$store.state.defaultShowDataState, 'this.$store.state.defaultShowDataState2')
// console.log(this.$store.state.defaultShowDataState, 'this.$store.state.defaultShowDataState2')
if (this.$route.query.defaultLeftId === 'default' && this.$store.state.defaultShowDataState && this.$store.state.defaultShowLabelAreaState !== 'normal') {
this.value = [this.$store.state.newSelectLabelArea.sequenceCont]
} else {
this.value = [this.options[1].value]
}
console.log(this.value, 'this.options')
// console.log(this.value, 'this.options')
// 告诉父组件已经完成任务
this.$emit('stateDFGHJ', true)
this.$emit('statertfResu', this.value[0])
@@ -511,7 +511,7 @@ export default {
sequenceCont: this.value[0],
sequenceState: this.stateChangeSDF ? 1 : 2// 1筛选指标 2筛选地区
}
console.log(this.options, 'this.option012')
// console.log(this.options, 'this.option012')
},
// 聚焦显示提示的搜索框
focusShow () {
@@ -523,7 +523,7 @@ export default {
switch (this.$route.query.type) {
case 'monthly':
if (!(this.timeUsrr.length === 6 || this.timeUsrr.length === 13)) {
console.log(this.timeUsrr.length, true)
// console.log(this.timeUsrr.length, true)
this.$alert('您查询的时间格式有误,请重新输入!', '温馨提示', {
confirmButtonText: '确定'
})
@@ -537,7 +537,7 @@ export default {
})
return
} else if (this.timeUsrr[this.timeUsrr.length - 2] === 1 && this.timeUsrr[this.timeUsrr.length - 1] > 2) {
console.log(9996)
// console.log(9996)
this.$alert('您查询的时间格式有误,请重新输入!', '温馨提示', {
confirmButtonText: '确定'
})
@@ -559,7 +559,7 @@ export default {
}
}
this.$store.state.selectData = this.timeUsrr
console.log(this.$store.state.selectData, '时间')
// console.log(this.$store.state.selectData, '时间')
// 调用父组件Dataweb中的changeBrother方法来调用ChartCont组件中的brotherFuncShowData方法
this.$parent.changeBrother()
this.timeUsrr = ''
@@ -629,7 +629,7 @@ export default {
case 'area':
let arrs = ['A', 'B', 'C', 'D']
if (!(this.timeUsrr.length === 4 || this.timeUsrr.length === 5 || this.timeUsrr.length === 6 || this.timeUsrr.length === 9 || this.timeUsrr.length === 11 || this.timeUsrr.length === 13)) {
console.log(this.timeUsrr.length, true)
// console.log(this.timeUsrr.length, true)
this.$alert('您查询的时间格式有误,请重新输入!', '温馨提示', {
confirmButtonText: '确定'
})
@@ -643,7 +643,7 @@ export default {
})
return
} else if (this.timeUsrr[this.timeUsrr.length - 2] === 1 && this.timeUsrr[this.timeUsrr.length - 1] > 2) {
console.log(9996)
// console.log(9996)
this.$alert('您查询的时间格式有误,请重新输入!', '温馨提示', {
confirmButtonText: '确定'
})
@@ -715,8 +715,8 @@ export default {
},
// 选中
handleChange (value) {
console.log(value)
console.log(this.value, 'this.value')
// console.log(value)
// console.log(this.value, 'this.value')
if (value[0] === '序列') {
this.yesNoClickXX = !this.yesNoClickXX
this.stateChangeSDF = !this.stateChangeSDF
@@ -745,20 +745,20 @@ export default {
let dataNer = JSON.parse(JSON.stringify(this.cityDataTime))
dataNer[3] = { name: this.$store.state.selectData, extendData: this.$store.state.selectData }
this.cityDataTime = dataNer
console.log(this.cityDataTime, 'this.cityDataTime')
// console.log(this.cityDataTime, 'this.cityDataTime')
// 默认选中最后一个
this.cityDefaultNameTime = { name: this.cityDataTime[3].name, activeIndex: 3 }
this.$store.state.selectData = this.cityDataTime[3].extendData
},
// 当前选中的时间列表
callBackVal (res) {
console.log(res.extendData, '开始')
// console.log(res.extendData, '开始')
// 调用父组件的chuFachildChartCont方法渲染
this.$store.state.selectData = res.extendData
this.$parent.chuFachildChartCont()
if (this.$store.state.selectData !== undefined) {
console.log(this.$store.state.selectData, '被选中的值')
console.log(res, '被选中的值2')
// console.log(this.$store.state.selectData, '被选中的值')
// console.log(res, '被选中的值2')
this.$store.state.selectData = res.extendData
this.$store.state.newSelectTime = {
name: res.name,
@@ -769,12 +769,12 @@ export default {
},
callBackValOpen (res) { // 展开回调
this.$store.state.defaultShowLabelAreaState = 'normal'
console.log(res, '展开')
console.log(this.$store.state.SelecttDimension, 'this.$store.state.advancedSearchState0000000000000000000000')
// console.log(res, '展开')
// console.log(this.$store.state.SelecttDimension, 'this.$store.state.advancedSearchState0000000000000000000000')
this.changesInputStu()
},
callBackValClose (res) { // 关闭回调
console.log(res, '关闭')
// console.log(res, '关闭')
this.changesInputStu()
},
// 高级查询指标地区序列化

View File

@@ -77,7 +77,7 @@ export default {
},
methods: {
changeTabel (stateSD, strd) {
console.log(stateSD, strd, 'stateSD, strd')
// console.log(stateSD, strd, 'stateSD, strd')
if (strd === 'row') {
this.rowVal = stateSD
} else if (strd === 'col') {
@@ -86,7 +86,7 @@ export default {
},
// 维度转换默认
change3D () {
console.log(this.$store.state.SelecttDimension, '3d56')
// console.log(this.$store.state.SelecttDimension, '3d56')
this.rowVal = this.arrValueZd[this.$store.state.SelecttDimension.col]
this.colVal = this.arrValueZd[this.$store.state.SelecttDimension.row]
},
@@ -103,12 +103,12 @@ export default {
},
trueChangeArea (dataState) {
this.$store.newSelectChangeData = null
console.log(dataState, 'dataState')
console.log(this.$store.state.noChangeData.areaName, 'this.$store.state.noChangeData.areaName')
// console.log(dataState, 'dataState')
// console.log(this.$store.state.noChangeData.areaName, 'this.$store.state.noChangeData.areaName')
/* eslint-disable*/
console.log(this.arrValue[this.colVal], 'this.$store.state.noChangeDatathis.$store.state.noChangeDatathis.$store.state.noChangeData')
console.log(this.arrValue[this.rowVal], 'this.$store.state.noChangeDatathis.$store.state.noChangeDatathis.$store.state.noChangeData')
console.log(this.$store.state.noChangeData)
// console.log(this.arrValue[this.colVal], 'this.$store.state.noChangeDatathis.$store.state.noChangeDatathis.$store.state.noChangeData')
// console.log(this.arrValue[this.rowVal], 'this.$store.state.noChangeDatathis.$store.state.noChangeDatathis.$store.state.noChangeData')
// console.log(this.$store.state.noChangeData)
let paramsd = {}
if ((this.arrValue[this.colVal] === 'sj' && this.arrValue[this.rowVal] === 'zb') || (this.arrValue[this.colVal] === 'zb' && this.arrValue[this.rowVal] === 'sj')) {
this.$store.state.noSelecttDimension = 'dq'
@@ -158,14 +158,14 @@ export default {
}
this.$store.state.SelecttDimension.row = this.arrValue[this.colVal]
this.$store.state.SelecttDimension.col = this.arrValue[this.rowVal]
console.log(this.$store.state.SelecttDimension, 'this.$store.state.SelecttDimension0236')
// console.log(this.$store.state.SelecttDimension, 'this.$store.state.SelecttDimension0236')
this.$axios({
method: 'POST',
url: 'data/data/wd-trans',
data: paramsd
}).then(res => {
console.log(this.$store.state.transBefore, '维度转换全局数据')
console.log(res, '获取数据展示数据')
// console.log(this.$store.state.transBefore, '维度转换全局数据')
// console.log(res, '获取数据展示数据')
// 请求接口完成 请求成功
if (res.data.code === 200) {
// if (res.data.data.areaName.length !== 0) {
@@ -206,7 +206,7 @@ export default {
// transBefore.transBeforeAreaData = res.data.data.transBeforeAreaData[0]
// }
transBefore.transBeforeAreaData = res.data.data.transBeforeAreaData[0]
console.log(transBefore, '000')
// console.log(transBefore, '000')
this.$store.state.transdtr = true
// 全局总数据
this.$store.state.AreaAllCountData = JSON.parse(JSON.stringify(res.data.data))
@@ -240,13 +240,13 @@ export default {
}
this.$store.state.yesNoClickChange = true
}).catch((fail) => {
console.log(fail, 2369)
// console.log(fail, 2369)
})
}
},
mounted() {
this.change3D()
console.log(1003)
// console.log(1003)
}
}
</script>

View File

@@ -1,25 +1,51 @@
<template>
<div class="mapData">
<div class="mapDataLeft" v-if="leftDafrt">
<div class="mapDataLeft"
v-if="leftDafrt">
<div v-if="leftDafrt.length!==0">指标名称</div>
<!-- 指标名称 -->
<div
v-for="(item,index) in leftDafrt"
:key="index"
:class="{bgcolor:item.state}"
@click="trickChange(index)"
>{{item.name}}</div>
<div style="margin:0 auto;color:#8fa3ae;font-size:1.375rem;" v-if="leftDafrt.length===0">暂无指标名</div>
<div v-for="(item,index) in leftDafrt"
:key="index"
:class="{bgcolor:item.state}"
@click="trickChange(index)">{{item.name}}</div>
<div style="margin:0 auto;color:#8fa3ae;font-size:1.375rem;"
v-if="leftDafrt.length===0">暂无指标名</div>
</div>
<div class="mapDataRight">
<div class="maptopSty">
<!-- -->
<div class="yearD">
<el-cascader v-model="value" :options="options" @change="handleChange"></el-cascader>
</div>
<!-- <div class="yearD">
<el-cascader v-model="value"
:options="options"
@change="handleChange"></el-cascader>
</div> -->
<!-- -->
<!-- -->
<!-- <div style="margin:0 auto;color:#8fa3ae;font-size:1.375rem;">该指标下暂无数据</div> -->
<ul class="year">
<li class="prev">
<span :class="{'disable': !isReduceYear}"
@click="reduceYear"></span>
</li>
<li v-for="(year, index) in mapYearList.slice(yearStart,yearEnd)"
:key="index"
:class="{'selected': selectYear == year}"
@click="selectYear=year">
{{ year }}<span v-if="selectYear == year"></span>
</li>
<li class="next">
<span :class="{'disable': !isAddYear}"
@click="addYear"></span>
</li>
</ul>
<ul class="quarter">
<li v-for="(item, index) in quarterList"
:key="index"
:class="{'selected': selectQuarter == index}"
@click="selectQuarter=index">
{{ item }}<span v-if="selectQuarter == index"></span>
</li>
</ul>
</div>
<div ref="mapRefs"></div>
</div>
@@ -37,6 +63,14 @@ export default {
name: 'mapData',
data () {
return {
yearStart: '',
yearEnd: '',
isReduceYear: true,
isAddYear: false,
selectYear: '',
selectQuarter: 0,
mapYearList: [],
quarterList: ['第一季度', '第二季度', '第三季度', '第四季度'],
// 控制下拉框显示隐藏
isHideProp: true,
// 左侧当前默认
@@ -55,16 +89,26 @@ export default {
},
legend: {
orient: 'vertical',
x: 'left',
data: ['iphone3']
x: 'left'
// data: ['iphone3']
},
dataRange: {
min: 0,
max: 2500,
// min: 0,
// max: 2500,
show: true,
x: 'left',
y: 'bottom',
text: ['高', '低'], // 文本,默认为数值文本
calculable: true
// text: ['高', '低'], // 文本,默认为数值文本
// calculable: true,
splitList: [],
color: [
'#298ADC',
'#479AE1',
'#78B5E9',
'#9FCAEF',
'#C3DEF5',
'#E2EFFA'
]
},
// toolbox: {
// show: true,
@@ -87,7 +131,7 @@ export default {
// },
series: [
{
name: 'iphone3',
// name: 'iphone3',
type: 'map',
mapType: 'china',
roam: false,
@@ -148,10 +192,34 @@ export default {
],
// 栏目数据 结构不可变
cityDataTime: [
{ 'id': '110000', 'name': '1985年', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '1986年', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '1987年', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '2019年', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' }
{
id: '110000',
name: '1985年',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '1986年',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '1987年',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '2019年',
parentId: '100000',
shortName: '北京',
cityCode: ''
}
],
// 默认选中月
monthData: '1月',
@@ -164,10 +232,34 @@ export default {
],
// 月 结构不可变
monthDatas: [
{ 'id': '110000', 'name': '1月', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '2月', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '3月', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' },
{ 'id': '110000', 'name': '4月', 'parentId': '100000', 'shortName': '北京', 'cityCode': '' }
{
id: '110000',
name: '1月',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '2月',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '3月',
parentId: '100000',
shortName: '北京',
cityCode: ''
},
{
id: '110000',
name: '4月',
parentId: '100000',
shortName: '北京',
cityCode: ''
}
],
// 左侧数据
leftDafrt: null,
@@ -192,16 +284,18 @@ export default {
type: this.$route.query.type === 'area' ? 2 : 1,
f: this.$store.state.selectDataLeft.f
}
}).then(res => {
console.log(res, '左侧菜单')
// 请求接口完成 请求成功
if (res.data.code === 200) {
this.leftCateData = res.data.data.list
this.defaultSelectLie()
}
}).catch((fail) => {
console.log(fail)
})
.then(res => {
// console.log(res, '左侧菜单')
// 请求接口完成 请求成功
if (res.data.code === 200) {
this.leftCateData = res.data.data.list
this.defaultSelectLie()
}
})
.catch(fail => {
// console.log(fail)
})
},
// 默认选中的列
defaultSelectLie () {
@@ -216,15 +310,37 @@ export default {
if (item2.children) {
item2.children.forEach((item3, index3) => {
if (index3 === 0) {
stateStatic.push('' + index1 + '-' + index2 + '-' + index3)
stateStatic.push(
'' + index1 + '-' + index2 + '-' + index3
)
if (item3.children) {
item3.children.forEach((item4, index4) => {
if (index4 === 0) {
stateStatic.push('' + index1 + '-' + index2 + '-' + index3 + '-' + index4)
stateStatic.push(
'' +
index1 +
'-' +
index2 +
'-' +
index3 +
'-' +
index4
)
if (item4.children) {
item4.children.forEach((item5, index5) => {
if (index5 === 0) {
stateStatic.push('' + index1 + '-' + index2 + '-' + index3 + '-' + index4 + '-' + index5)
stateStatic.push(
'' +
index1 +
'-' +
index2 +
'-' +
index3 +
'-' +
index4 +
'-' +
index5
)
}
})
}
@@ -246,7 +362,9 @@ export default {
console.log(this.leftCateData[0].children[0], '数据0')
JSON.parse(JSON.stringify(stateStatic)).forEach((item, index) => {
console.log(index)
index === 0 ? (dataDome = this.leftCateData[index]) : (dataDome = dataDome.children[0])
index === 0
? (dataDome = this.leftCateData[index])
: (dataDome = dataDome.children[0])
})
this.defaultDataRight = dataDome
console.log(this.defaultDataRight, '1250')
@@ -263,6 +381,7 @@ export default {
},
// 渲染数据地图
showMapData () {
console.log(this.option)
this.myEchartsObj = echarts.init(this.$refs.mapRefs, 'shine')
// 绘制图表
this.myEchartsObj.setOption(this.option, true)
@@ -275,111 +394,224 @@ export default {
// this.showMapData()
},
changesInputStu () {
console.log(12569)
// console.log(12569)
},
monthDataState (resu) {
console.log(resu)
console.log(this.cityDefaultName)
// console.log(resu)
// console.log(this.cityDefaultName)
},
monthDataChange () {
console.log(12569)
// console.log(12569)
},
// 地图左侧指标名称显示
searchDataMap () {
console.log(this.$store.state.selectDataLeft, '10111110')
// console.log(this.$store.state.selectDataLeft, '10111110')
this.$axios({
method: 'GET',
url: 'data/data/quota',
params: {
id: this.$store.state.selectDataLeft.id
}
}).then(res => {
console.log(res, '地图左侧指标名称显示')
// 请求接口完成 请求成功
if (res.data.code === 200) {
this.leftDafrt = res.data.data.list.map((item, index) => {
let brrO = {}
if (index === 0) {
brrO = {
id: item.id,
name: item.name,
state: true
}
} else {
brrO = {
id: item.id,
name: item.name,
state: false
}
}
return brrO
})
console.log(this.leftDafrt, 'this.leftDafrt')
this.getLabelDatart()
}
}).catch((fail) => {
console.log(fail)
})
.then(res => {
// console.log(res, '地图左侧指标名称显示')
// 请求接口完成 请求成功
if (res.data.code === 200) {
this.leftDafrt = res.data.data.list.map((item, index) => {
let brrO = {}
if (index === 0) {
brrO = {
id: item.id,
name: item.name,
state: true
}
} else {
brrO = {
id: item.id,
name: item.name,
state: false
}
}
return brrO
})
console.log(this.leftDafrt, 'this.leftDafrt')
this.getLabelDatart()
}
})
.catch(fail => {
console.log(fail)
})
},
// 获取每个指标的数据
getLabelDatart () {
console.log(this.leftDafrt, 1010110)
// console.log(this.leftDafrt, 1010110)
this.$axios({
method: 'GET',
url: 'data/data/map-data',
params: {
id: this.$store.state.selectDataLeft.id,
quota_id: this.leftDafrt.find((item, index) => { return item.state === true }).id
quota_id: this.leftDafrt.find((item, index) => {
return item.state === true
}).id
}
}).then(res => {
console.log(res, '数据地图数据')
// 请求接口完成 请求成功
if (res.data.code === 200) {
console.log(res.data.data.list, 'Object.values(res.data.data.list)')
this.option.legend.data = [this.leftDafrt.find((item, index) => { return item.state === true }).name]
this.option.series[0].name = [this.leftDafrt.find((item, index) => { return item.state === true }).name]
this.AllMapCount = res.data.data.list
this.cityDataTime = this.monthDatas
// 筛选的数据
this.cityDataTime = Object.keys(res.data.data.list).map((item, index) => {
return { 'id': '110000', 'name': item, 'parentId': '100000', 'shortName': '北京', 'cityCode': '' }
})
this.cityDefaultNameTime = this.cityDataTime[0].name
this.selectpatternTime[0].placeholder = this.cityDataTime[0].name
console.log(this.cityDataTime)
this.options = Object.keys(res.data.data.list).map((item, index) => {
return {
value: item,
label: item
}
})
this.value = [this.options[0].value]
this.option.series[0].data = this.AllMapCount[this.options[0].value]
this.showMapData()
// this.option.series[0].data = Object.values(res.data.data.list)
// this.showMapData()
}
}).catch((fail) => {
console.log(fail)
})
.then(res => {
console.log(res, '数据地图数据')
// 请求接口完成 请求成功
if (res.data.code === 200) {
console.log(
res.data.data.list,
'Object.values(res.data.data.list)'
)
// 设置地图数值区间
this.option.dataRange.splitList = this.setMapLabel(
res.data.data.list
)
this.option.legend.data = [
this.leftDafrt.find((item, index) => {
return item.state === true
}).name
]
this.option.series[0].name = [
this.leftDafrt.find((item, index) => {
return item.state === true
}).name
]
this.AllMapCount = res.data.data.list
this.cityDataTime = this.monthDatas
// 筛选的数据
this.cityDataTime = Object.keys(res.data.data.list).map(
(item, index) => {
return {
id: '110000',
name: item,
parentId: '100000',
shortName: '北京',
cityCode: ''
}
}
)
this.cityDefaultNameTime = this.cityDataTime[0].name
this.selectpatternTime[0].placeholder = this.cityDataTime[0].name
console.log(this.cityDataTime)
this.options = Object.keys(res.data.data.list).map(
(item, index) => {
return {
value: item,
label: item
}
}
)
this.value = [this.options[0].value]
this.option.series[0].data = this.AllMapCount[this.options[0].value]
this.showMapData()
// this.option.series[0].data = Object.values(res.data.data.list)
// this.showMapData()
}
})
.catch(fail => {
// console.log(fail)
})
},
// 根据地图数值设置数值区间
setMapLabel (data) {
// 数据地图显示的是当年的数据他把每年的数据分为6个阶段每个阶段都增加一个固定的值这个值的计算方式为当年各地区的最大数据减去最小数据 然后除以6 这个是每个阶段的增加的固定值,第一个区间是:最小值---最小值+固定值 第二区间为: 最小值+固定值----最小值+固定值+固定值,以此类推,最后一个为:最小值+固定值*5----最大值
let max = 0
let min = 0
for (let key in data) {
min = Number(data[key][0].value)
}
for (let key in data) {
data[key].forEach((item, index) => {
// console.log(item.value)
if (item.value) {
max = item.value > max ? parseFloat(item.value) : max
min = item.value < min ? parseFloat(item.value) : min
}
})
}
console.log('最大值:' + max, '最小值:' + min)
let list = [{ start: 0, end: 1 }]
let temp = parseFloat(((max - min) / 6).toFixed(4))
console.log(temp, '固定值')
for (let i = 0; i < 6; i++) {
i === 0
? (list[i] = {
start: parseFloat((min + temp * (5 - i)).toFixed(2)),
end: parseFloat(Math.ceil(max).toFixed(2))
})
: (list[i] = {
start: parseFloat((min + temp * (5 - i)).toFixed(2)),
end: parseFloat((min + temp * (6 - i)).toFixed(2))
})
}
console.log(list, '区间列表')
return list
},
// 点击改变指标名称
trickChange (ind) {
this.leftDafrt.forEach((item, index) => {
index === ind ? item.state = true : item.state = false
index === ind ? (item.state = true) : (item.state = false)
})
this.getLabelDatart()
// this.showMapData()
},
// 选中
handleChange (value) {
console.log(value)
console.log(this.value, 'this.value')
console.log(value, 'map')
// console.log(this.value, 'this.value')
this.option.series[0].data = this.AllMapCount[value[0]]
this.showMapData()
},
initYearList () {
const year = 2000
let arrYear = []
let thisYear = new Date().getFullYear()
var section = thisYear - year
for (let i = 0; i <= section; i++) {
arrYear.push(thisYear--)
}
this.yearEnd = arrYear.length
this.yearStart = arrYear.length - 10
this.selectYear = arrYear[0]
this.mapYearList = arrYear.reverse()
console.log(this.selectYear)
console.log(this.mapYearList)
},
reduceYear () {
// console.log(this.yearStart + '-' + this.yearEnd)
if (this.yearEnd - 10 > 0) {
this.yearEnd -= 1
this.yearStart = this.yearEnd - 10
if (this.yearEnd - 10 < 1) {
this.isReduceYear = false
}
if (this.yearEnd < this.mapYearList.length) {
this.isAddYear = true
}
} else {
this.isReduceYear = false
}
},
addYear () {
// console.log(this.yearStart + '-' + this.yearEnd)
if (this.yearEnd < this.mapYearList.length) {
this.yearEnd += 1
this.yearStart = this.yearEnd - 10
if (this.yearEnd === this.mapYearList.length) {
this.isAddYear = false
}
if (this.yearEnd - 10 > 0) {
this.isReduceYear = true
}
} else {
this.isAddYear = false
}
}
},
mounted () {
// 初始化年份列表
this.initYearList()
// 查询左侧数据
this.searchDataMap()
// 获取菜单信息
@@ -393,12 +625,12 @@ export default {
}
</script>
<style lang="scss" scoped>
/deep/ .el-col-24{
/deep/ .el-col-24 {
min-width: 100%;
width:auto;
width: auto;
}
/deep/ .el-menu{
border:none;
/deep/ .el-menu {
border: none;
}
/deep/ .el-submenu__title {
display: flex;
@@ -431,7 +663,7 @@ export default {
& > .mapDataLeft {
width: 26rem;
// margin-right: 2rem;
min-height: 54.875rem;
min-height: 56.875rem;
overflow: auto;
background-color: #ffffff;
box-shadow: 0rem 0.1875rem 1rem 0rem rgba(172, 172, 172, 1);
@@ -469,16 +701,117 @@ export default {
}
& > .maptopSty {
width: 100%;
height: 4rem;
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
& > .yearD {
margin: 0 2rem;
height: 6rem;
// display: flex;
// flex-direction: row;
// justify-content: flex-start;
// align-items: center;
// & > .yearD {
// margin: 0 2rem;
// }
// & > .monthD {
// margin: 0 2rem;
// }
> ul {
list-style: none;
overflow: hidden;
background: #f8f8f8;
display: flex;
align-items: center;
}
& > .monthD {
margin: 0 2rem;
.year {
> li {
text-align: center;
background-color: gray;
// width: 59px;
flex: 1;
height: 3rem;
line-height: 3rem;
position: relative;
cursor: pointer;
background: url(../../../static/data/icon_back.jpg) no-repeat center
bottom;
}
.selected {
> span {
background: url(../../../static/data/up.jpg) no-repeat center bottom;
position: absolute;
width: 15px;
height: 11px;
bottom: -3px;
left: 50%;
transform: translate(-50%, 0);
// right: 77px;
}
}
.prev {
> span {
background: url(../../../static/data/left.jpg) no-repeat left center;
position: absolute;
width: 13px;
height: 11px;
bottom: 9px;
right: 23px;
cursor: pointer;
}
.disable {
background: url(../../../static/data/left-disable.jpg) no-repeat
right center;
position: absolute;
width: 13px;
height: 11px;
bottom: 9px;
right: 23px;
cursor: pointer;
}
}
.next {
> span {
background: url(../../../static/data/right.jpg) no-repeat right
center;
position: absolute;
width: 13px;
height: 11px;
bottom: 9px;
right: 23px;
cursor: pointer;
}
.disable {
background: url(../../../static/data/right-disable.jpg) no-repeat
right center;
position: absolute;
width: 13px;
height: 11px;
bottom: 9px;
right: 23px;
cursor: pointer;
}
}
}
.quarter {
> li {
flex: 1;
text-align: center;
background-color: gray;
height: 3rem;
line-height: 3rem;
position: relative;
background: url(../../../static/data/icon_back.jpg) no-repeat center
bottom;
cursor: pointer;
}
.selected {
> span {
background: url(../../../static/data/up.jpg) no-repeat center bottom;
position: absolute;
width: 15px;
height: 11px;
bottom: -3px;
left: 50%;
transform: translate(-50%, 0);
// right: 77px;
}
}
}
}
}

View File

@@ -1,19 +1,20 @@
<template>
<div class="nav">
<div class="navCont">
<img :src="imageUrl.logo" alt srcset />
<div
v-for="(item,index) in navCont"
:key="index"
@click="navClick(index,item.url)"
@mouseenter="navMouseClick(index,item.url,true)"
@mouseleave="navMouseClick(index,item.url,false)"
:class="{fontSty:index==1&&colorD}"
>
<img :src="imageUrl.logo"
alt
srcset />
<div v-for="(item,index) in navCont"
:key="index"
@click="navClick(index,item.url)"
@mouseenter="navMouseClick(index,item.url,true)"
@mouseleave="navMouseClick(index,item.url,false)"
:class="{fontSty:index==1&&colorD}">
<div style="position:relative;">
{{item.text}}
<!-- 数据二级导航 -->
<div class="dataTwo" v-if="twonav&&index===1">
<div class="dataTwo"
v-if="twonav&&index===1">
<div @click="jumpData('monthly')">月度数据</div>
<div @click="jumpData('quarter')">季度数据</div>
<div @click="jumpData('year')">年度数据</div>
@@ -24,22 +25,21 @@
<div class="dsearch">
<!-- <img :src="imageUrl.search" alt srcset /> -->
<!-- 未登录 -->
<div
class="div1"
v-if="!$store.state.ipLogin&&!$store.state.normalLogin"
@click="loginWindow()"
>登录</div>
<div class="div1"
v-if="!$store.state.ipLogin&&!$store.state.normalLogin"
@click="loginWindow()">登录</div>
<!-- 登陆成功后显示 -->
<div
:class="{loginAfter:true,loginAfters:fontsF}"
v-if="$store.state.ipLogin||$store.state.normalLogin"
@mouseenter="userLoginC()"
@mouseleave="userLoginC()"
>
<img :src="userPic" alt srcset />
<div :class="{loginAfter:true,loginAfters:fontsF}"
v-if="$store.state.ipLogin||$store.state.normalLogin"
@mouseenter="userLoginC()"
@mouseleave="userLoginC()">
<img :src="userPic"
alt
srcset />
{{userName}}
<!-- 个人信息二级导航 -->
<div class="dataTwos" v-if="personalInfo">
<div class="dataTwos"
v-if="personalInfo">
<div @click="perspnalCenter">个人中心</div>
<div @click="quit">退出</div>
</div>
@@ -47,24 +47,36 @@
</div>
</div>
<!-- 登陆窗口 -->
<section class="loginSty" v-if="showWinStatic">
<section class="loginSty"
v-if="showWinStatic">
<div class="loginSty_wcont">
<div class="wcont_header">
<div>登录</div>
<img :src="imageUrl.deleteimg" alt @click="closeLoginWind(false)" />
<img :src="imageUrl.deleteimg"
alt
@click="closeLoginWind(false)" />
</div>
<div class="wcont_content">
<div>
<img :src="imageUrl.usernames" alt />
<input type="text" placeholder="请输入用户名" v-model="username" />
<img :src="imageUrl.usernames"
alt />
<input type="text"
placeholder="请输入用户名"
v-model="username" />
</div>
<div>
<img :src="imageUrl.userpwds" alt />
<input type="password" placeholder="请输入密码" v-model="userpwd" />
<img :src="imageUrl.userpwds"
alt />
<input type="password"
placeholder="请输入密码"
v-model="userpwd" />
</div>
<div>
<input type="text" placeholder="请输入验证码" v-model="useryzm" />
<canvas ref="identifyDom" @click="get_identity()"></canvas>
<input type="text"
placeholder="请输入验证码"
v-model="useryzm" />
<canvas ref="identifyDom"
@click="get_identity()"></canvas>
</div>
<div @click="closeLoginWind(true)">确认</div>
<div>
@@ -112,7 +124,8 @@ export default {
// 验证码
useryzm: '',
// 图片中的验证码
imgIdentify: null
imgIdentify: null,
isEnter: true
}
},
watch: {
@@ -163,27 +176,37 @@ export default {
// 关闭登录窗口
closeLoginWind (status) {
if (status) {
// 防止多次回车
this.isEnter = false
// 调接口上传,成功后关闭窗口
if (this.username === '') {
// alert('用户名不能为空!')
this.$alert('用户名不能为空!', '温馨提示', {
confirmButtonText: '确定'
})
alert('用户名不能为空!')
// this.$alert('用户名不能为空!', '温馨提示', {
// confirmButtonText: '确定'
// })
this.isEnter = true
return false
} else if (this.userpwd === '') {
// alert('密码不能为空!')
this.$alert('密码不能为空!', '温馨提示', {
confirmButtonText: '确定'
})
alert('密码不能为空!')
// this.$alert('密码不能为空!', '温馨提示', {
// confirmButtonText: '确定'
// })
this.isEnter = true
return false
} else if (this.useryzm === '') {
// alert('验证码不能为空!')
this.$alert('验证码不能为空!', '温馨提示', {
confirmButtonText: '确定'
})
alert('验证码不能为空!')
// this.$alert('验证码不能为空!', '温馨提示', {
// confirmButtonText: '确定'
// })
this.isEnter = true
return false
} else if (this.useryzm.toLocaleLowerCase() !== this.imgIdentify) {
this.$alert('验证码输入不正确请重新输入!', '温馨提示', {
confirmButtonText: '确定'
})
// alert('验证码输入不正确请重新输入!')
// this.$alert('验证码输入不正确请重新输入!', '温馨提示', {
// confirmButtonText: '确定'
// })
this.isEnter = true
alert('验证码输入不正确请重新输入!')
return false
} else {
let that = this
// 调接口判断密码是否输入正确,改变登录状态
@@ -194,46 +217,54 @@ export default {
username: this.username,
password_hash: this.userpwd
}
}).then(res => {
console.log(res)
// 请求接口完成注册 请求成功
if (res.data.code === 200) {
this.showWinStatic = !this.showWinStatic
this.$auth.auth = this.showWinStatic
// 用户信息存本地
sessionStorage.setItem('username', res.data.data.username)
sessionStorage.setItem('pic', res.data.data.pic)
sessionStorage.setItem('userPwd', this.userpwd)
sessionStorage.setItem('token', 'Bearer ' + res.data.data.token)
sessionStorage.setItem('tokenB', res.data.data.token)
this.$alert(res.data.message, '温馨提示', {
confirmButtonText: '确定',
callback: res => {
console.log(10000)
that.userLogin = sessionStorage.getItem('userLogin')
that.userName = sessionStorage.getItem('username')
that.userPic = sessionStorage.getItem('pic')
// 登录状态
sessionStorage.setItem('userLogin', true)
// 普通登陆状态
this.$store.state.normalLogin = true
if (this.$route.path !== '/') {
this.$router.push({ path: '/' })
}
window.setTimeout(() => {
sessionStorage.clear()
this.$router.go(0)
}, 7200000)
}
})
} else {
this.$alert(res.data.message, '温馨提示', {
confirmButtonText: '确定'
})
}
}).catch((fail) => {
console.log(fail)
})
.then(res => {
// console.log(res)
// 请求接口完成注册 请求成功
if (res.data.code === 200) {
this.showWinStatic = !this.showWinStatic
this.$auth.auth = this.showWinStatic
// 用户信息存本地
sessionStorage.setItem('username', res.data.data.username)
sessionStorage.setItem('pic', res.data.data.pic)
sessionStorage.setItem('userPwd', this.userpwd)
sessionStorage.setItem(
'token',
'Bearer ' + res.data.data.token
)
sessionStorage.setItem('tokenB', res.data.data.token)
this.$alert(res.data.message, '温馨提示', {
confirmButtonText: '确定',
callback: res => {
console.log(10000)
that.userLogin = sessionStorage.getItem('userLogin')
that.userName = sessionStorage.getItem('username')
that.userPic = sessionStorage.getItem('pic')
// 登录状态
sessionStorage.setItem('userLogin', true)
// 普通登陆状态
this.$store.state.normalLogin = true
if (this.$route.path !== '/') {
this.$router.push({ path: '/' })
}
window.setTimeout(() => {
sessionStorage.clear()
this.$router.go(0)
}, 7200000)
}
})
} else {
alert(res.data.message)
// this.$alert(res.data.message, '温馨提示', {
// confirmButtonText: '确定'
// })
}
this.isEnter = true
})
.catch(fail => {
// console.log(fail)
this.isEnter = true
})
}
} else {
console.log(!this.showWinStatic, 'this.showWinStatic')
@@ -260,29 +291,25 @@ export default {
// 跳到数据页面
jumpData (staData) {
if (this.$route.path !== '/datasweb') {
this.$router.push(
{
path: '/datasweb',
query: {
type: staData,
defaultLeftId: 'default'
}
this.$router.push({
path: '/datasweb',
query: {
type: staData,
defaultLeftId: 'default'
}
)
})
} else {
this.twonav = false
this.$router.push({
path: '/'
})
this.$router.push(
{
path: '/datasweb',
query: {
type: staData,
defaultLeftId: 'default'
}
this.$router.push({
path: '/datasweb',
query: {
type: staData,
defaultLeftId: 'default'
}
)
})
this.$router.go(0)
}
},
@@ -295,26 +322,28 @@ export default {
params: {
'access-token': sessionStorage.getItem('tokenB')
}
}).then(res => {
console.log(res)
this.$alert(res.data.message, '温馨提示', {
confirmButtonText: '确定'
})
// alert(res.data.message)
// 请求接口完成注册 请求成功
if (res.data.code === 200) {
console.log(this.$route.path, 'this.$router.path')
if (this.$route.path !== '/') {
this.$router.push({
path: '/'
})
}
sessionStorage.clear()
this.$router.go(0)
}
}).catch((fail) => {
console.log(fail)
})
.then(res => {
console.log(res)
this.$alert(res.data.message, '温馨提示', {
confirmButtonText: '确定'
})
// alert(res.data.message)
// 请求接口完成注册 请求成功
if (res.data.code === 200) {
console.log(this.$route.path, 'this.$router.path')
if (this.$route.path !== '/') {
this.$router.push({
path: '/'
})
}
sessionStorage.clear()
this.$router.go(0)
}
})
.catch(fail => {
console.log(fail)
})
},
perspnalCenter () {
if (this.$route.path !== '/personalCenter') {
@@ -322,11 +351,22 @@ export default {
} else {
this.$router.go(0)
}
},
keyDown (e) {
// 如果是回车则执行登录方法
if (
this.showWinStatic === true && this.isEnter &&
(e.code === 'Enter' || e.code === 'enter')
) {
// 验证在登录界面和按得键是回车键enter
// console.log('执行登录监听是否按下回车键')
this.closeLoginWind(true) // 登录函数
}
}
},
computed: {
},
computed: {},
mounted () {
window.addEventListener('keydown', this.keyDown)
// IP端
this.$axios({
method: 'GET',
@@ -367,14 +407,14 @@ export default {
let that = this
// 监听对象的变化
/* eslint-disable */
Object.defineProperty(this.$auth, 'auth', {
set: function (newVal) {
console.log(newVal, 'newValnewValnewVal')
that.showWinStatic = newVal
that.get_identity()
}
})
}
Object.defineProperty(this.$auth, 'auth', {
set: function (newVal) {
console.log(newVal, 'newValnewValnewVal')
that.showWinStatic = newVal
that.get_identity()
}
})
},
}
</script>
<style lang="scss" scoped>
@@ -484,6 +524,9 @@ export default {
-moz-box-align: center;
-ms-flex-align: center;
align-items: center;
input {
outline: none;
}
& > div:nth-last-child(n + 2) {
width: 100%;
height: 3.25rem;

View File

@@ -119,7 +119,7 @@ export default {
// 点击其他地方关闭窗口
document.addEventListener('click', function (e) {
/* eslint-disable */
console.log(that, '12569')
// console.log(that, '12569')
if (e.target.className !== 'city-picker') {
if (!that.pullDownlistShowState) {
that.pullDownlistShowState = true

View File

@@ -259,8 +259,11 @@ export default {
},
// 添加筛选条件
insertData () {
console.log(this.dataList.find(item => item.state === true))
if (this.dataList.find(item => item.state === true) !== undefined && this.nums !== '' && /^[0-9]+$/.test(this.nums)) {
// console.log(this.dataList.find(item => item.state === true))
// let reg1 = /^[0-9]+\.?[0-9]+?$/
// let reg2 = /^[0-9]+$/
let reg = /^\d+(\.\d+)?$/
if (this.dataList.find(item => item.state === true) !== undefined && this.nums !== '' && (reg.test(this.nums))) {
let fuh = ''
switch (this.selectChange) {
case '大于(>)':
@@ -291,7 +294,7 @@ export default {
deleteData () {
if (this.selectDatas.find(item => item.state === true) !== undefined) {
this.selectDatas = this.selectDatas.filter((item, index) => {
console.log(item.state)
// console.log(item.state)
return item.state === false
})
} else {
@@ -315,7 +318,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -342,7 +345,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -358,7 +361,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -370,7 +373,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
@@ -384,10 +387,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '1')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'zb') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeTermsData))
@@ -397,12 +400,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -421,7 +424,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -445,7 +448,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -463,7 +466,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
@@ -478,10 +481,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.transBefore.termsName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '1')
}
} else {
// 筛选条件
@@ -491,7 +494,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -518,7 +521,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -534,7 +537,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -546,7 +549,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
@@ -560,17 +563,17 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'zb') {
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -597,7 +600,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -613,7 +616,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -625,7 +628,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return brre.indexOf(index) !== -1
@@ -639,10 +642,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'dq' && this.$store.state.SelecttDimension.row === 'sj') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -650,7 +653,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.areaName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -677,7 +680,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -693,7 +696,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -705,7 +708,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
@@ -713,10 +716,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.noChangeData.areaName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'dq') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -724,7 +727,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -751,7 +754,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -767,7 +770,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -779,7 +782,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return brre.indexOf(index) !== -1
@@ -787,10 +790,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.noChangeData.areaName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'zb' && this.$store.state.SelecttDimension.row === 'dq') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -798,7 +801,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -825,7 +828,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -841,7 +844,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -853,7 +856,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.areaName = this.$store.state.noChangeData.areaName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
@@ -867,10 +870,10 @@ export default {
this.$store.state.transBefore.dataSource = this.$store.state.noChangeData.dataSource.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'dq' && this.$store.state.SelecttDimension.row === 'zb') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -878,7 +881,7 @@ export default {
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.areaName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -905,7 +908,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -921,7 +924,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -933,7 +936,7 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeAreaData = waiBrr
this.$store.state.transBefore.areaName = this.$store.state.noChangeData.areaName.filter((item, index) => {
return brre.indexOf(index) !== -1
@@ -947,10 +950,10 @@ export default {
this.$store.state.transBefore.dataSource = this.$store.state.noChangeData.dataSource.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
}
}
} else if (this.selectAudio === 'lie') {
@@ -964,98 +967,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
text: list.text.split('#')[1],
way: list.text.split('#')[2]
}
})
// 第一次过滤出来的数据
let firstData = newDataBefore.filter((item, index) => {
return brre.indexOf(index) !== -1
}).map((item, index) => {
return item.map((list, key) => {
return {
index: key,
value: list
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
firstData.forEach((item, index) => {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
// console.log(eval(list.value + brreWay[index].way))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
})
// console.log(DataTwo, '第二次过滤')
// 第三次过滤
// 定义一个数组用来存储全集的下标
let AllLabelIndex = []
let threeData = DataTwo.forEach((item, index) => {
let itemDAta = item.map((list, key) => {
return Object.values(list)[0]
})
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
// console.log(list)
return list.value
})
}).map((item, index) => {
return item.filter((list, key) => {
return AllLabelIndex.indexOf(key) !== -1
})
})
// 转置回来
waiBrr = waiBrr[0].map(function (col, index) {
return waiBrr.map((row, key) => {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return brre.indexOf(index) !== -1
})
this.$store.state.transBefore.termsExplain = this.$store.state.transBefore.termsExplain.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
this.$store.state.transBefore.dataSource = this.$store.state.transBefore.dataSource.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
this.$store.state.transBefore.termsName = this.$store.state.transBefore.termsName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'zb') {
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeTermsData))
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1082,7 +999,7 @@ export default {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
// console.log(eval(list.value + brreWay[index].way))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
@@ -1098,7 +1015,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1110,7 +1027,93 @@ export default {
return AllLabelIndex.indexOf(key) !== -1
})
})
console.log(waiBrr, '处理后的数据')
// 转置回来
waiBrr = waiBrr[0].map(function (col, index) {
return waiBrr.map((row, key) => {
return row[index]
})
})
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return brre.indexOf(index) !== -1
})
this.$store.state.transBefore.termsExplain = this.$store.state.transBefore.termsExplain.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
this.$store.state.transBefore.dataSource = this.$store.state.transBefore.dataSource.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
this.$store.state.transBefore.termsName = this.$store.state.transBefore.termsName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'zb') {
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeTermsData))
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
text: list.text.split('#')[1],
way: list.text.split('#')[2]
}
})
// 第一次过滤出来的数据
let firstData = newDataBefore.filter((item, index) => {
return brre.indexOf(index) !== -1
}).map((item, index) => {
return item.map((list, key) => {
return {
index: key,
value: list
}
})
})
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
firstData.forEach((item, index) => {
DataTwo.push(
item.filter((list, key) => {
/* eslint-disable */
// console.log((eval((list.value === '' ? '0' : list.value) + brreWay[index].way)))
return eval((list.value === '' ? '0' : list.value) + brreWay[index].way) === true
})
)
})
// console.log(DataTwo, '第二次过滤')
// 第三次过滤
// 定义一个数组用来存储全集的下标
let AllLabelIndex = []
let threeData = DataTwo.forEach((item, index) => {
let itemDAta = item.map((list, key) => {
return Object.values(list)[0]
})
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
// console.log(list)
return list.value
})
}).map((item, index) => {
return item.filter((list, key) => {
return AllLabelIndex.indexOf(key) !== -1
})
})
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
@@ -1124,10 +1127,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
}
} else {//地区列数据
if (this.$store.state.SelecttDimension.col === 'zb' && this.$store.state.SelecttDimension.row === 'sj') {
@@ -1139,12 +1142,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1163,7 +1166,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1187,7 +1190,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1205,7 +1208,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
@@ -1220,10 +1223,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.transBefore.termsName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'zb') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -1233,12 +1236,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1257,7 +1260,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1281,7 +1284,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1299,7 +1302,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
@@ -1314,10 +1317,10 @@ export default {
this.$store.state.transBefore.termsName = this.$store.state.transBefore.termsName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'dq' && this.$store.state.SelecttDimension.row === 'sj') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -1327,12 +1330,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.timeArr.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1351,7 +1354,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1375,7 +1378,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1393,7 +1396,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
@@ -1402,10 +1405,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.transBefore.areaName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'sj' && this.$store.state.SelecttDimension.row === 'dq') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -1415,12 +1418,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.areaName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1439,7 +1442,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1463,7 +1466,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1481,7 +1484,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.timeArr = this.$store.state.noChangeData.timeArr.filter((item, index) => {
@@ -1490,10 +1493,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.transBefore.areaName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'zb' && this.$store.state.SelecttDimension.row === 'dq') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -1503,12 +1506,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.termsName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1527,7 +1530,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1551,7 +1554,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1569,7 +1572,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
@@ -1584,10 +1587,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.transBefore.areaName.filter((item, index) => {
return AllLabelIndex.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
} else if (this.$store.state.SelecttDimension.col === 'dq' && this.$store.state.SelecttDimension.row === 'zb') {
// 筛选条件
let newDataBefore = JSON.parse(JSON.stringify(this.$store.state.noChangeData.transBeforeAreaData))
@@ -1597,12 +1600,12 @@ export default {
return row[index]
})
})
console.log(newDataBefore, '转置')
// console.log(newDataBefore, '转置')
// 返回下标
let brre = this.selectDatas.map((list, key) => {
return this.$store.state.noChangeData.areaName.indexOf(list.text.split('#')[1])
})
console.log(brre, 'brre')
// console.log(brre, 'brre')
// 返回表达式
let brreWay = this.selectDatas.map((list, key) => {
return {
@@ -1621,7 +1624,7 @@ export default {
}
})
})
console.log(firstData, 'newDataBefore')
// console.log(firstData, 'newDataBefore')
// console.log(brreWay, 'brreWay')
// 第二次过滤
let DataTwo = []
@@ -1645,7 +1648,7 @@ export default {
// console.log(itemDAta)
AllLabelIndex = this.concat(AllLabelIndex, itemDAta)
})
console.log(AllLabelIndex, '连接数组')
// console.log(AllLabelIndex, '连接数组')
// 第三次过滤并且复制
let waiBrr = firstData.map((item, index) => {
return item.map((list, key) => {
@@ -1663,7 +1666,7 @@ export default {
return row[index]
})
})
console.log(waiBrr, '处理后的数据')
// console.log(waiBrr, '处理后的数据')
this.$store.state.transBefore.transBeforeTermsData = waiBrr
// console.log(AllLabelIndex,'AllLabelIndex')
this.$store.state.transBefore.termsName = this.$store.state.noChangeData.termsName.filter((item, index) => {
@@ -1678,10 +1681,10 @@ export default {
this.$store.state.transBefore.areaName = this.$store.state.transBefore.areaName.filter((item, index) => {
return brre.indexOf(index) !== -1
})
console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// console.log(this.$store.state.transBefore, 'this.$store.state.transBefore')
// 关闭窗口
this.$store.state.selcettWindowState = false
this.$emit('emitState', true)
this.$emit('emitState', true, '2')
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -541,6 +541,9 @@ export default {
flex-direction: column;
justify-content: space-evenly;
align-items: center;
input {
outline: none;
}
& > div:nth-last-child(n + 2) {
width: 100%;
height: 3.25rem;

View File

@@ -185,7 +185,7 @@ export default {
// 被选中时触发
choiceCaller (resu) {
console.log(resu, '触发')
console.log(resu[1], 'resu[1]')
// console.log(resu[1], 'resu[1]')
/* eslint-disable */
resu[0] === '-全部-' ? (this.selectLMType = '', this.selectLMId = '') : (this.selectLMType = resu[2].type, this.selectLMId = resu[2].id)
console.log(this.selectLMType, this.selectLMId)

BIN
static/data/icon_back.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 811 B

BIN
static/data/left.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 802 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 797 B

BIN
static/data/right.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 793 B

BIN
static/data/up.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 731 B