123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291 |
- <template>
- <el-card shadow="always" class="box-card">
- <div class="box-header">
- <h4>分析介绍:</h4>
- <div class="box-header-min">
- <div>
- {{ fieldInfo.fieldName }}位于{{ fieldInfo.provinceName
- }}{{ fieldInfo.cityName }}
- ,海拔高度为
- <span class="headerMessage"> {{ fieldInfo.elevationHeight }} </span>
- ,所在经纬度为经度
- <span class="headerMessage"> {{ fieldInfo.longitude }} </span>
- ,纬度
- <span class="headerMessage">{{ fieldInfo.latitude }} </span>。
- </div>
- <div>
- 该风电场由大唐研究院管理,风场总容量为
- <span class="headerMessage"
- >{{ fieldInfo.ratedCapacityNumber }} MW
- </span>
- ,共安装
- <span class="headerMessage">{{ fieldInfo.engineCount }} 台</span>
- 风机,使用的机型为
- <span class="headerMessage">
- {{
- fieldInfo.engineMillTypes && fieldInfo.engineMillTypes.join(",")
- }}
- </span>
- 。
- </div>
- <div>
- 分析数据时间跨度为2025年1月20日至2025年2月20日,分析完成时间为2025年1月20日10:10:10。数据分析人
- <span class="headerMessage"> {{ analysisInfo.updateByName }}</span
- >。
- </div>
- </div>
- </div>
- <div class="content">
- <div class="left">
- <div class="box-content-min">
- <h4>完成分析类型:</h4>
- <template
- v-if="analysisInfo && analysisInfo.analysisTypes?.length > 0"
- >
- <div class="completeAssetssType">
- <el-tag
- v-for="analysis in analysisInfo.analysisTypes"
- :key="analysis.analysisTypeName"
- type="warning"
- >{{ analysis.analysisTypeName }}
- </el-tag>
- </div>
- </template>
- <el-empty v-else description="暂无完成分析类型"></el-empty>
- </div>
- <div class="box-content-min">
- <h4>分析完成机组:</h4>
- <div
- class="analysisCompletionUnit"
- v-if="analysisInfo && analysisInfo.windEngineGroups?.length > 0"
- >
- <div
- class="itemAnalysisCompletionUnit"
- v-for="itemData in analysisInfo.windEngineGroups"
- :key="itemData.engineCode"
- >
- <SvgIcons
- name="WindPower3"
- class="WindPower3"
- width="40px"
- height="42px"
- color="#222"
- ></SvgIcons>
- <span>{{ itemData.engineName }}#机组</span>
- </div>
- </div>
- <el-empty v-else description="暂无分析完成机组"></el-empty>
- </div>
- </div>
- <div class="right">
- <Map :batchCode="initBatchCode" :fieldCode="fieldInfo.fieldCode"></Map>
- </div>
- </div>
- </el-card>
- </template>
- <script>
- import Map from "../map/index.vue";
- import { getFieldInfo } from "@/api/overview";
- import { getWindEngineGroup } from "@/api/ledger";
- export default {
- name: "AnalysisInformation",
- components: {
- Map,
- },
- props: {
- initBatchCode: {
- default: "",
- type: String,
- },
- },
- data() {
- return {
- fieldInfo: {
- fieldCode: "",
- }, //风场信息
- fieldCode: "", //风场编号
- analysisInfo: {}, //分析类型编号
- activeNames: ["1", "2", "3"],
- data: [
- 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
- ],
- };
- },
- watch: {
- initBatchCode(newVal, oldVal) {
- console.log(newVal, oldVal, "分析信息内容更新");
- this.getFieldInfoMess();
- },
- },
- mounted() {
- if (this.$route.query.batchCode) {
- this.initBatchCode = this.$route.query.batchCode;
- }
- if (this.$route.query.fieldCode) {
- this.fieldInfo.fieldCode = this.$route.query.fieldCode;
- }
- },
- created() {
- this.getFieldInfoMess();
- },
- methods: {
- async getWindEngList() {
- this.loading = true;
- try {
- const res = await getWindEngineGroup({
- engineCode: this.engineCode,
- });
- this.loading = false;
- this.windDetail = res.data;
- } catch (error) {
- this.loading = false;
- console.error(error);
- }
- },
- //获取分析信息
- async getFieldInfoMess() {
- //分析详情
- try {
- const res = await getFieldInfo({ batchCode: this.initBatchCode });
- if (res.code === 200) {
- this.fieldInfo = res.data.fieldInfo; //风场信息
- this.analysisInfo = res.data.analysisInfo; //分析类型编号
- }
- } catch (err) {}
- },
- handleChange(val) {
- console.log(val);
- },
- },
- };
- </script>
- <style scoped lang="scss">
- .completeAssetssType {
- display: flex;
- flex-wrap: wrap;
- .el-tag {
- margin-right: 10px;
- margin-bottom: 10px;
- }
- ::v-deep .el-tag--warning {
- background-color: #fdf6ec !important;
- border-color: #faecd8 !important;
- color: #e6a23c !important;
- }
- }
- .el-card__body {
- width: 100%;
- height: 100%;
- // margin-bottom: 20px !important;
- }
- .content {
- width: 100%;
- display: flex;
- justify-content: space-between;
- align-items: flex-start;
- /* 上对齐 */
- height: 100%;
- /* 确保内容区域有高度 */
- }
- .left {
- width: 60%;
- // flex: 1;
- .box-content-min {
- padding: 10px;
- border-bottom: 1px solid #ebeef5;
- color: #303133;
- h4 {
- color: #303133;
- // border-bottom: 1px solid #ebeef5;
- font-size: 13px;
- font-weight: 500;
- margin-bottom: 10px;
- }
- }
- .analysisCompletionUnit {
- display: flex;
- flex-wrap: wrap;
- margin: 20px 0;
- .itemAnalysisCompletionUnit {
- text-align: center;
- margin-bottom: 10px;
- border: #eaeef6 solid 1px;
- margin-right: 10px;
- border-radius: 10px;
- padding: 10px 5px;
- .WindPower3 {
- padding: 10px 5px;
- text-align: center;
- }
- }
- }
- }
- .right {
- width: 40%;
- height: 100%;
- /* 确保容器高度为100% */
- // flex: 1;
- display: flex;
- justify-content: center;
- align-items: center;
- }
- .right .map-ditu {
- width: 100%;
- /* 设置地图的宽度 */
- height: 60vh;
- border-radius: 90px;
- /* 设置地图的高度 */
- }
- .box-card {
- width: 100%;
- height: 100%;
- overflow-y: scroll;
- .box-header {
- padding: 10px;
- border-bottom: 1px solid #ebeef5;
- color: #303133;
- h4 {
- color: #303133;
- font-size: 13px;
- font-weight: 500;
- margin-bottom: 10px;
- }
- }
- .box-header-min {
- padding: 10px;
- font-size: 14px;
- color: #606266;
- line-height: 40px;
- .headerMessage {
- font-size: 16px;
- }
- }
- }
- </style>
|