<template>
    <div class="box">
        <div class="searchBar">
            <el-card class="box-card">
                <el-form :inline="true" :model="formInline" class="demo-form-inline">
            <el-row :gutter="1">
                <el-form-item label="查询条件">
                </el-form-item>
                <el-form-item label="风场：">
                <el-select v-model="value"  placeholder="请选择" @change="projectData">
                <el-option
                    v-for="item in options"
                    :key="item.name"
                    :label="item.name"
                    :value="item.id">
                </el-option>
                </el-select>
                </el-form-item>
                <el-form-item label="年份：">
                        <el-date-picker
                        value-format="yyyy"
                        v-model="year"
                        type="year"
                        placeholder="选择年"
                        format="yyyy"
                        >
                        </el-date-picker>
                    </el-form-item>
                    <el-form-item label="月份：">
                        <el-date-picker
                        value-format="yyyy-MM"
                        v-model="month"
                        type="month"
                        placeholder="选择月"
                        format="yyyy-MM">
                        </el-date-picker>
                    </el-form-item>
                <el-form-item>
                <el-button type="primary" @click="queryApData" :plain="true"
                    >计算</el-button
                >
                </el-form-item>
                <el-form-item>
                <el-button type="primary" @click="toExcel()">导出</el-button>
                </el-form-item>
            </el-row>
            </el-form>
            </el-card>
            <div style="font-size:30px;text-align:center;margin-top:1%">{{title}}</div>
            <el-table
            id="callthepolicetable"
            :data="gridData"
            :row-style="{ height: '10px' }" 
            :cell-style="{ textAlign: 'center'}" 
            :header-cell-style="{ textAlign:'center',background:'#F5F7FA'}"
            @sort-change="changeTableSort"
            @row-click="tableDatawindturbineName"
            border
            style="width:100%;margin-top:1%;cursor: pointer;">
            <el-table-column
              type="index"
              width="40">
            </el-table-column>
            <el-table-column
              prop="windturbineName"
              label="机组编号"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="fdl"
              label="实际发电量(万千瓦时)"
              width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="llfdl"
              label="理论发电量(万千瓦时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="sbklyl"
              label="设备利用小时数(小时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="sbklyl"
              label="设备可利用率(%)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="dxklyxs"
              label="等效可用系数(%)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="fs"
              label="平均风速(m/s)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="xfqr"
              label="小风切入风速(m/s)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="yxxs"
              label="有效风时数(小时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="gzss"
              label="故障损失电量(万千瓦时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="xdss"
              label="调度限电损失电量(万千瓦时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="jxss"
              label="计划检修损失电量(万千瓦时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="xnss"
              label="性能未达标损失电量(万千瓦时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="gzxs"
              label="故障停用时间(小时)"
               width="250">
            </el-table-column>
            <el-table-column
            :sortable="'custom'"
              prop="glyzxxs"
              label="机组功率一致性系数(%)"
               width="250">
            </el-table-column>
            <!-- <el-table-column
            :sortable="'custom'"
              prop="jfpl"
              label="静风频率"
               width="100">
            </el-table-column>         -->
       </el-table>
       </div>
    </div>
</template>
<script>
    import singleMachineAnalysis from "@assets/js/performanceAnalysis/singleMachineAnalysis";
    export default singleMachineAnalysis;
</script>
<style lang="scss" scoped>
    @import "@assets/css/performanceAnalysis/singleMachineAnalysis.scss";
</style>