|
@@ -0,0 +1,340 @@
|
|
|
+<template>
|
|
|
+ <div class="draught-fan-list">
|
|
|
+ <div class="query mg-b-8">
|
|
|
+ <div class="query-items">
|
|
|
+ <div class="query-item">
|
|
|
+ <div class="lable">场站:</div>
|
|
|
+ <div class="search-input">
|
|
|
+ <el-select v-model="wpId" clearable placeholder="请选择" popper-class="select" @change="(wpId) => { getProject(); }">
|
|
|
+ <el-option v-for="item in wpArray" :key="item.id" :value="item.id" :label="item.name" />
|
|
|
+ </el-select>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="query-item">
|
|
|
+ <div class="lable">日期:</div>
|
|
|
+ <div class="search-input">
|
|
|
+ <el-date-picker v-model="recorddate" type="date"
|
|
|
+ value-format="YYYY-MM-DD" placeholder="选择日期" popper-class="date-select">
|
|
|
+ </el-date-picker>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="query-actions">
|
|
|
+ <button class="btn green" @click="search">查询</button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div>
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'日最大风速'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{rzdfsStr}}</span>
|
|
|
+ </div>
|
|
|
+ <radar-chart :width="'100%'" :height="'350px'" :value="rzdfsData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'月最大风速'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{yzdfsStr}}</span>
|
|
|
+ </div>
|
|
|
+ <radar-chart :width="'100%'" :height="'350px'" :value="yzdfsData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'年最大风速'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{nzdfsStr}}</span>
|
|
|
+ </div>
|
|
|
+ <radar-chart :width="'100%'" :height="'350px'" :value="nzdfsData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'日风向频率'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{rfxplStr}}</span>
|
|
|
+ </div>
|
|
|
+ <radar-chart :width="'100%'" :height="'350px'" :value="rfxplData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'月风向频率'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{yfxplStr}}</span>
|
|
|
+ </div>
|
|
|
+ <radar-chart :width="'100%'" :height="'350px'" :value="yfxplData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ <panel :title="'年风向频率'" class="radar-panel" :icon="'svg-wind-site'">
|
|
|
+ <div class="wind-info">
|
|
|
+ <div class="legend mg-r-16">
|
|
|
+ <span class="dot"></span>
|
|
|
+ <span>{{nfxplStr}}</span>
|
|
|
+ </div>
|
|
|
+ <direction-radar-chart :width="'100%'" :height="'350px'" :value="nfxplData" />
|
|
|
+ </div>
|
|
|
+ </panel>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import DirectionRadarChart from "../../components/chart/radar/direction-radar-chart.vue";
|
|
|
+import panel from "../../components/coms/panel/panel.vue";
|
|
|
+import RadarChart from "../../components/chart/radar/radar-chart.vue";
|
|
|
+export default {
|
|
|
+ // 名称
|
|
|
+ name: "cutAnalyse",
|
|
|
+
|
|
|
+ // 使用组件
|
|
|
+ components: { panel,RadarChart, DirectionRadarChart },
|
|
|
+
|
|
|
+ // 数据
|
|
|
+ data () {
|
|
|
+ return {
|
|
|
+ isAsc: "asc",
|
|
|
+ wpArray: [],
|
|
|
+ projectArray: [],
|
|
|
+ wpId: "",
|
|
|
+ projectId:"",
|
|
|
+ wtId: "MG01_01",
|
|
|
+ rzdfsStr: "",
|
|
|
+ rzdfsData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+
|
|
|
+ yzdfsStr: "",
|
|
|
+ yzdfsData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+
|
|
|
+ nzdfsStr: "",
|
|
|
+ nzdfsData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+
|
|
|
+ rfxplStr: "",
|
|
|
+ rfxplData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+
|
|
|
+ yfxplStr: "",
|
|
|
+ yfxplData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+
|
|
|
+ nfxplStr: "",
|
|
|
+ nfxplData: {
|
|
|
+ indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
|
|
|
+ data: [{
|
|
|
+ value: [44200, 14200, 20000, 35000, 50000, 38000],
|
|
|
+ name: ""
|
|
|
+ }]
|
|
|
+ },
|
|
|
+ recorddate:new Date((new Date().getTime() - 3600 * 1000 * 24)).formatDate("yyyy-MM-dd"),
|
|
|
+ chartData: [{
|
|
|
+ title: "风资源分析",
|
|
|
+ value: []
|
|
|
+ }]
|
|
|
+ };
|
|
|
+ },
|
|
|
+
|
|
|
+ // 函数
|
|
|
+ methods: {
|
|
|
+ // 获取风场
|
|
|
+ getWp (reGetWp) {
|
|
|
+ let that = this;
|
|
|
+ that.API.requestData({
|
|
|
+ method: "GET",
|
|
|
+ subUrl: "powercompare/windfarmAjax",
|
|
|
+ success (res) {
|
|
|
+ that.wpArray = res.data;
|
|
|
+ that.wpId = res.data[0].id;
|
|
|
+ that.getProject();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+ // 获取期数
|
|
|
+ getProject(){
|
|
|
+ let that = this;
|
|
|
+ that.API.requestData({
|
|
|
+ method: "GET",
|
|
|
+ subUrl: "powercompare/projectAjax",
|
|
|
+ data:{
|
|
|
+ wpIds: that.wpId
|
|
|
+ },
|
|
|
+ success (res) {
|
|
|
+ that.projectArray = res.data;
|
|
|
+ that.projectId = res.data[0].id;
|
|
|
+ that.getChartData();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+ // tab3,tab4 - 获取玫瑰图
|
|
|
+ getMgt (subUrl, data, dataKey) {
|
|
|
+ let that = this;
|
|
|
+ that.API.requestData({
|
|
|
+ method: "POST",
|
|
|
+ subUrl,
|
|
|
+ data,
|
|
|
+ success (res) {
|
|
|
+ console.log(res.data);
|
|
|
+ that[dataKey.split("Data")[0] + "Str"] = res.data.jfpl || "";
|
|
|
+
|
|
|
+ let mgtData = {
|
|
|
+ indicator: [],
|
|
|
+ data: [{
|
|
|
+ name: "",
|
|
|
+ value: []
|
|
|
+ }]
|
|
|
+ };
|
|
|
+
|
|
|
+ if (res.data.data) {
|
|
|
+ res.data.data.forEach((ele) => {
|
|
|
+ mgtData.indicator.push(ele.name);
|
|
|
+ mgtData.data[0].value.push(ele.data1);
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ that[dataKey] = mgtData;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ // 获取图表数据
|
|
|
+ getChartData () {
|
|
|
+ let that = this;
|
|
|
+ that.API.requestData({
|
|
|
+ method: "POST",
|
|
|
+ subUrl: "scatter/scatterAjax",
|
|
|
+ data: {
|
|
|
+ wpId: "",
|
|
|
+ pjId: that.projectId,
|
|
|
+ lnId: "",
|
|
|
+ year: (that.recorddate ? new Date(that.recorddate).getFullYear() : ""),
|
|
|
+ month: (that.recorddate ? (new Date(that.recorddate).getMonth() + 1) : ""),
|
|
|
+ },
|
|
|
+ success (res) {
|
|
|
+ let chartData = [{
|
|
|
+ title: "风资源分析",
|
|
|
+ value: (res.data || [])
|
|
|
+ }];
|
|
|
+ that.$nextTick(()=>{
|
|
|
+ that.chartData = chartData;
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+ search () {
|
|
|
+ if (!this.wpId || !this.projectId) {
|
|
|
+ this.BASE.showMsg({
|
|
|
+ msg: '场站与项目为必选项'
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ const xhrParam = { wpId: this.wpId, recorddate: this.recorddate };
|
|
|
+ this.getMgt("goodness/wprzdfs", xhrParam, "rzdfsData");
|
|
|
+ this.getMgt("goodness/wpyzdfs", xhrParam, "yzdfsData");
|
|
|
+ this.getMgt("goodness/wpnzdfs", xhrParam, "nzdfsData");
|
|
|
+ this.getMgt("goodness/wprfxpl", xhrParam, "rfxplData");
|
|
|
+ this.getMgt("goodness/wpyfxpl", xhrParam, "yfxplData");
|
|
|
+ this.getMgt("goodness/wpnfxpl", xhrParam, "nfxplData");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ created () {
|
|
|
+ this.getWp();
|
|
|
+ },
|
|
|
+
|
|
|
+ mounted () { },
|
|
|
+
|
|
|
+ unmounted () { },
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="less" scoped>
|
|
|
+.draught-fan-list {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+
|
|
|
+ .btn-group-tabs {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: row;
|
|
|
+
|
|
|
+ .photovoltaic {
|
|
|
+ margin-left: 1.481vh;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .df-table {
|
|
|
+ border: 0.093vh solid fade(@darkgray, 50%);
|
|
|
+ position: relative;
|
|
|
+ overflow: auto;
|
|
|
+ flex-grow: 1;
|
|
|
+ margin-top: 1.481vh;
|
|
|
+ height: 30vh;
|
|
|
+
|
|
|
+ &:before {
|
|
|
+ content: '';
|
|
|
+ width: 0.37vh;
|
|
|
+ height: 0.37vh;
|
|
|
+ background: @write;
|
|
|
+ position: absolute;
|
|
|
+ left: 0.278vh;
|
|
|
+ top: 0.278vh;
|
|
|
+ }
|
|
|
+
|
|
|
+ tbody {
|
|
|
+ height: calc(100vh - 166px);
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|