|
@@ -18,11 +18,13 @@
|
|
|
<el-tabs v-model="activeTab">
|
|
|
<el-tab-pane label="图表展示" name="1">
|
|
|
</el-tab-pane>
|
|
|
- <el-tab-pane label="表格数据" name="2">
|
|
|
+ <el-tab-pane label="桨距角风速曲线" name="2">
|
|
|
</el-tab-pane>
|
|
|
- <div v-if="activeTab === '2'" :style="{ height: tableHeight }">
|
|
|
+ <el-tab-pane label="表格数据" name="3">
|
|
|
+ </el-tab-pane>
|
|
|
+ <div v-if="activeTab === '3'" :style="{ height: tableHeight }">
|
|
|
<table-cop class="" :data="tableData" :column="tableColumn" :theme="theme"
|
|
|
- :height="tableHeight" tableId="1" tableName="浆距角分析"></table-cop>
|
|
|
+ :height="tableHeight" tableId="1" :tableName="tableName" :rowstyle="true"></table-cop>
|
|
|
</div>
|
|
|
<div v-if="activeTab === '1'" :style="{ height: tableHeight }">
|
|
|
<!-- :height="`calc( ${tableHeight})`" -->
|
|
@@ -33,6 +35,11 @@
|
|
|
:dataSet="dataSet" :theme="theme" :echartsTheme="echartsTheme"
|
|
|
@getSelected="funChartSelect" />
|
|
|
</div>
|
|
|
+ <div v-if="activeTab === '2'" :style="{ height: tableHeight }">
|
|
|
+ <!-- <div id="speedLine" style="width:100%;height:100%"></div> -->
|
|
|
+ <bar-chart-cop width="100%" height="100%" :theme="theme" :echartsTheme="echartsTheme"
|
|
|
+ :xAxis="linexAxis" :yAxis="lineyAxis" :series="lineSeries"></bar-chart-cop>
|
|
|
+ </div>
|
|
|
</el-tabs>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -43,12 +50,15 @@
|
|
|
import excelCop from '@/components/generatingCapacityComponent/excel.vue'
|
|
|
import treeCop from '@/components/generatingCapacityComponent/tree.vue'
|
|
|
import tableCop from '@/components/generatingCapacityComponent/table.vue'
|
|
|
+ import barChartCop from '../spaceAnalysis/components/barChart.vue'
|
|
|
+ import * as echarts from 'echarts'
|
|
|
import {
|
|
|
ElMessage
|
|
|
} from 'element-plus';
|
|
|
import {
|
|
|
onMounted,
|
|
|
ref,
|
|
|
+ reactive,
|
|
|
onActivated,
|
|
|
watch
|
|
|
} from 'vue'
|
|
@@ -63,10 +73,18 @@
|
|
|
const excelHeight = ref(window.innerHeight - 120 + 'px') //excel高度
|
|
|
/**excel 开始 */
|
|
|
const excelList = ref([])
|
|
|
+ const speedParams = ref({})
|
|
|
const funExcelChange = async (obj) => { //点击excel项时
|
|
|
funSubmit({
|
|
|
ids: obj.id
|
|
|
})
|
|
|
+ tableName.value = obj.name
|
|
|
+ getSpeedLine({
|
|
|
+ ids: obj.id
|
|
|
+ })
|
|
|
+ speedParams.value = {
|
|
|
+ ids: obj.id
|
|
|
+ }
|
|
|
}
|
|
|
/**tree 开始 */
|
|
|
const treeData = ref([])
|
|
@@ -184,12 +202,14 @@
|
|
|
let exTime = []
|
|
|
let yp1 = [],
|
|
|
yp2 = [],
|
|
|
- yp3 = []
|
|
|
+ yp3 = [],
|
|
|
+ speed = []
|
|
|
res.data.bw.forEach(it => {
|
|
|
exTime.push(it.time)
|
|
|
yp1.push(it.yp1)
|
|
|
yp2.push(it.yp2)
|
|
|
yp3.push(it.yp3)
|
|
|
+ speed.push(it.speed)
|
|
|
})
|
|
|
tableData.value = res.data.bw
|
|
|
seriesAllData.value = res.data.bw
|
|
@@ -234,9 +254,61 @@
|
|
|
smooth: false, //这个是把线变成曲线
|
|
|
data: yp3,
|
|
|
xAxisIndex: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: "风速",
|
|
|
+ type: "line",
|
|
|
+ yAxisIndex: 1,
|
|
|
+ symbol: "line", //设定为实心点
|
|
|
+ symbolSize: 0, //设定实心点的大小
|
|
|
+ smooth: false, //这个是把线变成曲线
|
|
|
+ data: speed,
|
|
|
+ xAxisIndex: 0,
|
|
|
}
|
|
|
]
|
|
|
}
|
|
|
+ const linexAxis = reactive({
|
|
|
+ type: 'category',
|
|
|
+ name: '风速',
|
|
|
+ data: []
|
|
|
+ })
|
|
|
+ const lineyAxis = reactive({
|
|
|
+ type: 'value',
|
|
|
+ name: '度',
|
|
|
+ splitLine: {
|
|
|
+ show: false
|
|
|
+ },
|
|
|
+ axisTick: {
|
|
|
+ show: true
|
|
|
+ },
|
|
|
+ axisLine: {
|
|
|
+ onZero: false
|
|
|
+ }
|
|
|
+ })
|
|
|
+ const lineSeries = reactive([{
|
|
|
+ name: "桨距角风速曲线",
|
|
|
+ type: "line",
|
|
|
+ data: [],
|
|
|
+ symbol: "line", //设定为实心点
|
|
|
+ symbolSize: 0, //设定实心点的大小
|
|
|
+ }])
|
|
|
+ const getSpeedLine = async (params) => {
|
|
|
+ const speedRes = await httpRequest.get('/blade/curve', {
|
|
|
+ params: params
|
|
|
+ })
|
|
|
+ if (speedRes.code === 200) {
|
|
|
+ if (speedRes.data) {
|
|
|
+ let xAsis = []
|
|
|
+ let series = []
|
|
|
+ for (const item in speedRes.data) {
|
|
|
+ xAsis.push(item)
|
|
|
+ series.push(speedRes.data[item])
|
|
|
+ }
|
|
|
+ linexAxis.data = xAsis
|
|
|
+ lineSeries[0].data = series
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
/**created */
|
|
|
// funGetTree()
|
|
|
const theme = ref(null)
|