Browse Source

Merge branch 'master' of http://124.70.43.205:3000/GYEE_R.D/Gyee_Frame_NX

chenminghua 1 year ago
parent
commit
7f8d2a41df

+ 0 - 1
src/main/java/com/gyee/frame/common/cache/RedisConfig.java

@@ -67,7 +67,6 @@ public class RedisConfig {
         redisStandaloneConfiguration.setDatabase(database);
         redisStandaloneConfiguration.setPassword(pwd);
         redisStandaloneConfiguration.setPort(port);
-        redisStandaloneConfiguration.setDatabase(1);
 
         JedisClientConfiguration.JedisPoolingClientConfigurationBuilder jpcb = (JedisClientConfiguration.JedisPoolingClientConfigurationBuilder) JedisClientConfiguration.builder();
         jpcb.poolConfig(jedisPoolConfig);

+ 3 - 1
src/main/java/com/gyee/frame/common/spring/Constant.java

@@ -538,7 +538,9 @@ public class Constant {
 	public static final String TPOINT_WT_FJGL = "AI130";// 风机功率
 	public static final String TPOINT_WT_GLYS = "AI067";// 功率因数
 	public static final String QSTPOINT_WT_BJJD1 = "AI184";// 青山变桨角度1
-	public static final String QSTPOINT_WT_FDJZS = "AI223";// 发电机转速
+//	public static final String QSTPOINT_WT_FDJZS = "AI223";// 发电机转速
+	public static final String QSTPOINT_WT_FDJZS = "AI128";// 发电机转速
+
 	public static final String TPOINT_WT_BJJD1 = "AI076";// 变桨角度1
 	public static final String TPOINT_WT_FDJZS = "AI128";// 发电机转速
 	public static final String TPOINT_WT_YLZS = "AI012";// 叶轮转速

+ 14 - 5
src/main/java/com/gyee/frame/common/spring/ConstantTR.java

@@ -292,14 +292,16 @@ public class ConstantTR {
 	// 10#进线-断路器位置
 	/******************************************** 马场湖风电场 *****************************************/
 
-	public static final String MCHRZQD = "MCHGGL.NX_GD_MCHG_YC_P1_L1_001_QXZ001"; // 马场湖日照强度
+//	public static final String MCHRZQD = "MCHGGL.NX_GD_MCHG_YC_P1_L1_001_QXZ001"; // 马场湖日照强度
+	public static final String MCHRZQD = "NX_GD_MCHG_GF_P1_L1_026_AI0011"; // 马场湖日照强度正确
 	/******************************************** 宣和风电场 *****************************************/
 	public static final String XHRFDL = "XHGDCJSFW.NX_GD_XHG_XX_XX_XXX_XXX_CI0088"; // 宣和日发电量
 	public static final String XHYFDL = "XHGDCJSFW.NX_GD_XHG_XX_XX_XXX_XXX_CI0146"; // 宣和月发电量
 	public static final String XHNFDL = "XHGDCJSFW.NX_GD_XHG_XX_XX_XXX_XXX_CI0037"; // 宣和年发电量
 	public static final String XHSWDL = "XHGDCJSFW.NX_GD_XHG_XX_XX_XXX_XXX_CI0136"; // 宣和上网电量
 	public static final String XHZGL = "XHDQ.NX_GD_XHG_DQ_P1_L1_001_AI0002"; // 宣和总功率
-	public static final String XHFS = "XHGGL.NX_GD_XHG_YC_P1_L1_001_QXZ001"; // 宣和日照强度
+//	public static final String XHFS = "XHGGL.NX_GD_XHG_YC_P1_L1_001_QXZ001"; // 宣和日照强度
+	public static final String XHFS = "XHDQ.NX_GD_XHG_DQ_P1_L1_001_AI0192"; // 宣和日照强度
 																				// XHDQ.NX_GD_XHG_DQ_P1_L1_001_AI0192
 	// public static final String XHFS =
 	// "XHGDCJSFW.NX_GD_XHG_XX_XX_XXX_XXX_CI0134"; // 宣和日照强度
@@ -314,11 +316,18 @@ public class ConstantTR {
 	/******************************************** 宣和风电场 *****************************************/
 
 	/******************************************** 海子井风电场 *****************************************/
-	public static final String HZJWD = "HZJGGL.NX_GD_HZJG_YC_P1_L1_001_QXZ005"; // 海子井测风塔温度
-	public static final String HZJPJFS = "HZJGGL.NX_GD_HZJG_YC_P1_L1_001_QXZ001"; // 海子井光照强度
-	public static final String HZJGL = "HZJDQ.NX_GD_HZJG_DQ_P1_L1_001_AI0052";//海子井功率(5号主变高压侧)
+	public static final String HZJWD = "AKDQ.NX_GD_AKG_DQ_P1_L1_001_AI0161"; // 海子井测风塔温度
+	public static final String HZJPJFS = "AKDQ.NX_GD_AKG_DQ_P1_L1_001_AI0157"; // 海子井光照强度
+	public static final String HZJGL = "AKDQ.NX_GD_AKG_DQ_P1_L1_001_AI0139";//海子井功率(5号主变高压侧)
 	/******************************************** 海子井风电场 *****************************************/
 
+
+	/******************************************** 艾肯风电场 *****************************************/
+	public static final String AKWD = "HZJGGL.NX_GD_HZJG_YC_P1_L1_001_QXZ005"; // 海子井测风塔温度
+	public static final String AKPJFS = "HZJGGL.NX_GD_HZJG_YC_P1_L1_001_QXZ001"; // 海子井光照强度
+	public static final String AKGL = "HZJDQ.NX_GD_HZJG_DQ_P1_L1_001_AI0052";//海子井功率(5号主变高压侧)
+	/******************************************** 艾肯风电场 *****************************************/
+
 	/******************************************** 香山风电场 *****************************************/
 	public static final String XSRFDL = "XSFCJSFW.NX_GD_XSF_XX_XX_XXX_XXX_CI0088"; // 香山日发电量
 	public static final String XSYFDL = "XSFCJSFW.NX_GD_XSF_XX_XX_XXX_XXX_CI0146"; // 香山月发电量

+ 2 - 1
src/main/java/com/gyee/frame/common/spring/WpEnum.java

@@ -11,7 +11,8 @@ public  enum  WpEnum {
     PL_GDC("PL_GDC"),
     XH_GDC("XH_GDC"),
     MCH_GDC("MCH_GDC"),
-    HZJ_GDC("HZJ_GDC");
+    HZJ_GDC("HZJ_GDC"),
+    AK_GDC("AK_GDC");
 
     public String id;
     WpEnum(final  String c) {

+ 15 - 9
src/main/java/com/gyee/frame/controller/singleanalysis/SingleAnalysisController.java

@@ -5,6 +5,7 @@ import com.gyee.frame.common.domain.AjaxResult;
 import com.gyee.frame.model.custom.SingleAnalysisVo;
 import com.gyee.frame.model.custom.Tablepar;
 import com.gyee.frame.service.singleanalysis.SingleAnalysisService;
+import com.gyee.frame.util.DateUtils;
 import com.gyee.frame.util.StringUtils;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiImplicitParam;
@@ -30,8 +31,6 @@ public class SingleAnalysisController {
      * 单机信息总览首页
      * @param tablepar
      * @param wpId
-     * @param year
-     * @param month
      * @return
      * @throws Exception
      */
@@ -41,16 +40,16 @@ public class SingleAnalysisController {
     @ApiImplicitParams({
             @ApiImplicitParam(name = "tablepar", value = "分页对象", required = true, dataType = "Tablepar", paramType = "query"),
             @ApiImplicitParam(name = "wpId", value = "风场编号", required = true, dataType = "string", paramType = "query"),
-            @ApiImplicitParam(name = "year", value = "年份", required = true, dataType = "string", paramType = "query"),
-            @ApiImplicitParam(name = "month", value = "月份", required = true, dataType = "string", paramType = "query")})
+            @ApiImplicitParam(name = "beginDate", value = "开始日期", required = true, dataType = "string", paramType = "query"),
+            @ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query")})
 
-    public AjaxResult singleanalysisMain(Tablepar tablepar, String wpId, String year, String month) throws Exception {
+    public AjaxResult singleanalysisMain(Tablepar tablepar, String wpId, String beginDate, String endDate) throws Exception {
 
         List<SingleAnalysisVo> vos =new ArrayList<>();
 
-        if (StringUtils.notEmp(wpId) && StringUtils.notEmp(year) && StringUtils.notEmp(month)) {
+        if (StringUtils.notEmp(wpId) && StringUtils.notEmp(beginDate) && StringUtils.notEmp(endDate)) {
 
-            Calendar cal = Calendar.getInstance();
+            /*Calendar cal = Calendar.getInstance();
             cal.set(Calendar.HOUR_OF_DAY, 0);
             cal.set(Calendar.MINUTE, 0);
             cal.set(Calendar.SECOND, 0);
@@ -61,9 +60,16 @@ public class SingleAnalysisController {
             cal.set(Calendar.DAY_OF_MONTH, cal.getActualMinimum(Calendar.DAY_OF_MONTH));
             Date beginDate = cal.getTime();
             cal.add(Calendar.MONTH, 1);
-            Date endDate = cal.getTime();
+            Date endDate = cal.getTime();*/
+            Date date1 = DateUtils.parseDate(beginDate);
+            Date date2 = DateUtils.parseDate(endDate);
+            Calendar cal = Calendar.getInstance();
+            cal.setTime(date2);
+            cal.add(Calendar.DATE, 1);
+            cal.add(Calendar.MILLISECOND, -1);
+            date2 = cal.getTime();
 
-            vos =singleAnalysisService.SingleAnalysisList(tablepar, wpId,beginDate,endDate);
+            vos =singleAnalysisService.SingleAnalysisList(tablepar, wpId,date1,date2);
 
         }
 

+ 2 - 2
src/main/resources/mybatis/auto/WindTurbineInfoDayMapper.xml

@@ -1392,8 +1392,8 @@
   ,sum(Faulthours)   gzxs,sum(Maintainhours)   jxxs
   ,sum(Stophours)   tjxs,sum(Interrupthours)   zdxs
   ,sum(Daycalendarhours)   rlxs,avg(Speed)   fs
-  ,avg(Daysbklyl)   sbklyl,avg(Daysbklyl)   dxklyxs
-  ,avg(Daylyxs)   sbklyl,avg(dayLYXS)  lyxs
+  ,avg(Daysbklyl)   sbklyl,avg(Daydxkyxs)   dxklyxs
+  ,avg(dayLYXS)  lyxs
   ,avg(Windhours)   yxfss
   from WindTurbineInfoDay
   where   Windpowerstationid = #{wpId} and Recorddate >= #{beginDate} and Recorddate &lt; #{endDate}