zy %!s(int64=2) %!d(string=hai) anos
pai
achega
a3964edb64

+ 66 - 0
neim-biz/src/main/java/com/jiayue/biz/controller/FengJiInfoController.java

@@ -0,0 +1,66 @@
+package com.jiayue.biz.controller;
+
+import com.jiayue.biz.domain.ProjectInfo;
+import com.jiayue.biz.domain.StationInfo;
+import com.jiayue.biz.service.*;
+
+import com.jiayue.common.core.controller.BaseController;
+import com.jiayue.common.core.domain.AjaxResult;
+import lombok.RequiredArgsConstructor;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 人工录入Controller
+ *
+ * @date 2023-05-9
+ */
+@RequiredArgsConstructor(onConstructor_ = @Autowired)
+@RestController
+@RequestMapping("/dataQuery/fengjiInfo")
+public class FengJiInfoController extends BaseController {
+    private final FengJiInfoService fengJiInfoService;
+    private final ProjectInfoService projectInfoService;
+    private final StationInfoService stationInfoService;
+    /**
+     * 项目进展获取项目名称+id
+     */
+    @GetMapping("/getProjectInfo")
+    public AjaxResult getProjectInfo() {
+        List<Map<String, String>> list = new ArrayList<>();
+        List<ProjectInfo> projectInfoList = projectInfoService.getProjectInfoList();
+        for (ProjectInfo projectInfo : projectInfoList) {
+            Map<String, String> map = new HashMap<>();
+            map.put("id", projectInfo.getId());
+            map.put("name", projectInfo.getProjectBasicInfo().getProjectNameEasy());
+            list.add(map);
+        }
+        return AjaxResult.success(list);
+    }
+
+    /**
+     * 获取场站信息
+     */
+    @GetMapping("/getStationInfo")
+    public AjaxResult getStationInfo() {
+        List<Map<String, String>> list = new ArrayList<>();
+        List<StationInfo> stationInfos = stationInfoService.selectStationInfo();
+        for (StationInfo stationInfo : stationInfos) {
+            Map<String, String> map = new HashMap<>();
+            map.put("id", stationInfo.getId());
+            map.put("name", stationInfo.getStationBasicInfo().getStationName());
+            list.add(map);
+        }
+        return AjaxResult.success(list);
+    }
+
+
+
+
+
+}

+ 18 - 0
neim-biz/src/main/java/com/jiayue/biz/service/FengJiInfoService.java

@@ -0,0 +1,18 @@
+package com.jiayue.biz.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.jiayue.biz.domain.ProvincialEnergyStations;
+import com.jiayue.biz.domain.WindTowerDataParentTable;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 风机信息Service接口
+ *
+ * @author L.ym
+ * @date 2022-05-11
+ */
+public interface FengJiInfoService extends IService<WindTowerDataParentTable> {
+
+}

+ 32 - 0
neim-biz/src/main/java/com/jiayue/biz/service/impl/FengJiInfoServiceImpl.java

@@ -0,0 +1,32 @@
+package com.jiayue.biz.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.jiayue.biz.domain.ProvincialEnergyStations;
+import com.jiayue.biz.domain.StationInfo;
+import com.jiayue.biz.domain.WindTowerDataParentTable;
+import com.jiayue.biz.mapper.WindTowerDataParentTableMapper;
+import com.jiayue.biz.service.FengJiInfoService;
+import com.jiayue.biz.service.ManualEntryService;
+import com.jiayue.biz.service.ProvincialEnergyStationsService;
+import com.jiayue.biz.service.StationInfoService;
+import lombok.AllArgsConstructor;
+import org.springframework.data.mongodb.core.MongoTemplate;
+import org.springframework.stereotype.Service;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 风机信息Service业务层处理
+ *
+ * @author L.ym
+ * @date 2022-05-11
+ */
+@Service
+@AllArgsConstructor
+public class FengJiInfoServiceImpl extends ServiceImpl<WindTowerDataParentTableMapper, WindTowerDataParentTable> implements FengJiInfoService {
+
+
+}

+ 18 - 0
neim-ui/src/api/biz/dataQuery/fengjiInfo.js

@@ -0,0 +1,18 @@
+import request from '@/utils/request'
+
+// 获取项目下拉框
+export function getProjectInfo() {
+  return request({
+    url: '/dataQuery/fengjiInfo/getProjectInfo',
+    method: 'get'
+  })
+}
+
+// 获取场站下拉框
+export function getStationInfo() {
+  return request({
+    url: '/dataQuery/fengjiInfo/getStationInfo',
+    method: 'get'
+  })
+}
+

+ 179 - 0
neim-ui/src/views/dataQuery/fengjiInfo/index.vue

@@ -0,0 +1,179 @@
+<template>
+  <div class="app-container">
+    <el-card class="box-card">
+      <el-tabs type="border-card">
+        <el-tab-pane label="场站风机信息">
+          <el-table v-loading="loading" border :data="stationFanList.slice((page.currentPage-1)*page.pageSize,page.currentPage*page.pageSize)">
+            <el-table-column label="场站名称" align="center" prop="stationName"/>
+            <el-table-column label="风机编号" align="center" prop="_id"/>
+            <el-table-column label="风机名称" align="center" prop="FanName"/>
+            <el-table-column label="风机经度" align="center" prop="longitudeFan"/>
+            <el-table-column label="风机纬度" align="center" prop="latitudeFan"/>
+            <el-table-column label="风机机型" align="center" prop="FanModel"/>
+            <el-table-column label="轮毂高度" align="center" prop="hubHeight"/>
+            <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+              <template slot-scope="scope">
+                <el-button
+                  size="mini"
+                  type="text"
+                  icon="el-icon-edit"
+                  @click="handleUpdate(scope.row)"
+                >修改
+                </el-button>
+                <el-button
+                  size="mini"
+                  type="text"
+                  icon="el-icon-delete"
+                  @click="handleDelete(scope.row)"
+                >删除
+                </el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+          <div class="block">
+            <el-pagination
+              @size-change="handleSizeChange"
+              @current-change="handleCurrentChange"
+              :current-page=page.currentPage
+              :page-sizes="[10, 15, 30, 50]"
+              :page-size=page.pageSize
+              layout="total, sizes, prev, pager, next, jumper"
+              :total=page.total>
+            </el-pagination>
+          </div>
+        </el-tab-pane>
+        <el-tab-pane label="项目预设风机信息">
+          <el-table v-loading="pLoading" border :data="projectFanList.slice((page1.currentPage-1)*page1.pageSize,page1.currentPage*page1.pageSize)">
+            <el-table-column label="项目名称" align="center" prop="projectName"/>
+            <el-table-column label="风机编号" align="center" prop="_id"/>
+            <el-table-column label="风机名称" align="center" prop="FanName"/>
+            <el-table-column label="风机经度" align="center" prop="longitudeFan"/>
+            <el-table-column label="风机纬度" align="center" prop="latitudeFan"/>
+            <el-table-column label="风机机型" align="center" prop="FanModel"/>
+            <el-table-column label="轮毂高度" align="center" prop="hubHeight"/>
+
+            <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+              <template slot-scope="scope">
+                <el-button
+                  size="mini"
+                  type="text"
+                  icon="el-icon-edit"
+                  @click="pHandleUpdate(scope.row)"
+                >修改
+                </el-button>
+                <el-button
+                  size="mini"
+                  type="text"
+                  icon="el-icon-delete"
+                  @click="pHandleDelete(scope.row)"
+                >删除
+                </el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+          <div class="block">
+            <el-pagination
+              @size-change="handleSizeChange1"
+              @current-change="handleCurrentChange1"
+              :current-page=page1.currentPage
+              :page-sizes="[10, 15, 30, 50]"
+              :page-size=page1.pageSize
+              layout="total, sizes, prev, pager, next, jumper"
+              :total=page1.total>
+            </el-pagination>
+          </div>
+        </el-tab-pane>
+
+      </el-tabs>
+    </el-card>
+  </div>
+</template>
+
+<script>
+import {
+  getProjectInfo,getStationInfo
+} from "@/api/biz/dataQuery/fengjiInfo";
+export default {
+  name: "index",
+  data(){
+    return{
+      loading:false,
+      pLoading:false,
+      stationFanList:[],//场站风机list
+      projectFanList:[],//项目风机list
+      page: {
+        total: 0, // 总页数
+        currentPage: 1, // 当前页数
+        pageSize: 10 // 每页显示多少条
+      },
+      page1: {
+        total: 0, // 总页数
+        currentPage: 1, // 当前页数
+        pageSize: 10 // 每页显示多少条
+      },
+    }
+  },
+  mounted() {
+  },
+  methods:{
+    /*获取信息*/
+    getInfo(){
+
+    },
+    /*获取项目下拉框*/
+    getProjectInfo(){
+      getProjectInfo().then(res=>{
+
+      }).catch(err=>{
+
+      })
+    },
+    /*获取场站下拉框*/
+    getStationInfo(){
+      getStationInfo().then(res=>{
+
+      }).catch(err=>{
+
+      })
+    },
+    /*场站的编辑与删除*/
+    handleUpdate(row){
+
+    },
+    handleDelete(row){
+
+    },
+    /*项目的编辑与删除*/
+    pHandleUpdate(row){
+
+    },
+    pHandleDelete(row){
+
+    },
+    /*pageSize改变*/
+    handleSizeChange(val) {
+      this.page.pageSize = val
+      this.page.currentPage = 1
+    },
+    /*currentPage改变*/
+    handleCurrentChange(val) {
+      this.page.currentPage = val
+    },/*pageSize改变*/
+    handleSizeChange1(val) {
+      this.page1.pageSize = val
+      this.page1.currentPage = 1
+    },
+    /*currentPage改变*/
+    handleCurrentChange1(val) {
+      this.page1.currentPage = val
+    },
+  }
+}
+</script>
+
+<style scoped>
+.block {
+  float: right;
+  margin: 1%;
+}
+</style>