Procházet zdrojové kódy

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

xushili před 1 rokem
rodič
revize
60263d57a4
28 změnil soubory, kde provedl 39 přidání a 734 odebrání
  1. 2 0
      electricity/meter/build.gradle
  2. 5 3
      electricity/meter/src/main/java/com/gyee/gaia/meter/adapter/Adapter.java
  3. 2 0
      electricity/meter/src/main/java/com/gyee/gaia/meter/config/AppConfig.java
  4. 3 4
      electricity/meter/src/main/java/com/gyee/gaia/meter/config/XxlJobConfig.java
  5. 0 1
      electricity/meter/src/main/java/com/gyee/gaia/meter/controller/ConfigController.java
  6. 0 75
      electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoCompany.java
  7. 0 95
      electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoLine.java
  8. 0 175
      electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoPowerstation.java
  9. 0 190
      electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoProject.java
  10. 0 11
      electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoCompanyMapper.java
  11. 0 11
      electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoLineMapper.java
  12. 0 11
      electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoPowerstationMapper.java
  13. 0 11
      electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoProjectMapper.java
  14. 14 10
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/AdapterServiceTest.java
  15. 0 16
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoCompanyService.java
  16. 0 16
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoLineService.java
  17. 0 16
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoPowerstationService.java
  18. 0 16
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoProjectService.java
  19. 0 13
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoCompanyServiceImpl.java
  20. 0 13
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoLineServiceImpl.java
  21. 0 13
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoPowerstationServiceImpl.java
  22. 0 12
      electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoProjectServiceImpl.java
  23. 12 0
      electricity/meter/src/main/resources/application.properties
  24. 1 2
      electricity/meter/src/main/resources/bootstrap.yaml
  25. 0 5
      electricity/meter/src/main/resources/mappers-postgresql/MeterInfoCompanyMapper.xml
  26. 0 5
      electricity/meter/src/main/resources/mappers-postgresql/MeterInfoLineMapper.xml
  27. 0 5
      electricity/meter/src/main/resources/mappers-postgresql/MeterInfoPowerstationMapper.xml
  28. 0 5
      electricity/meter/src/main/resources/mappers-postgresql/MeterInfoProjectMapper.xml

+ 2 - 0
electricity/meter/build.gradle

@@ -46,5 +46,7 @@ dependencies {
 
     implementation("$cloudGroup:spring-cloud-starter-openfeign")
     implementation("cn.hutool:hutool-all:5.8.18")
+    implementation("org.springframework.boot:spring-boot-configuration-processor")
+
 }
 

+ 5 - 3
electricity/meter/src/main/java/com/gyee/gaia/meter/adapter/Adapter.java

@@ -12,8 +12,8 @@ import java.util.Map;
  * Author: malijun
  * Data  : 2023: 04: 27
  **/
-@FeignClient(name = "adapter", url = "192.168.10.18:8011/ts")
-//@FeignClient(name="adapter",url = "192.168.1.82:8011/ts")
+@FeignClient(name = "adapter", url = "${adapter.url}")
+//@FeignClient(name = "adapter", url = "192.168.10.18:8011/ts")
 public interface Adapter {
 
 
@@ -24,7 +24,7 @@ public interface Adapter {
             @RequestParam(value = "ts", required = false) Long ts
     );
 
-    //获取一个或多个测点,指定时间的数据(没有则返回前一个时间点的数据)
+    //获取一个测点指定时间段内的数据(可以设置间隔时间单位S)
     @GetMapping("/history/snap")
     List<PointData> getHistorySnap(
             @RequestParam(value = "tagName", required = false) String tagName,
@@ -33,6 +33,8 @@ public interface Adapter {
             @RequestParam(value = "interval", required = false) Integer interval
     );
 
+
+    //获取一个测点指定时间段内的数据
     @GetMapping("/history/raw")
     List<PointData> getHistoryRaw(
             @RequestParam(value = "tagName", required = false) String tagName,

+ 2 - 0
electricity/meter/src/main/java/com/gyee/gaia/meter/config/AppConfig.java

@@ -20,3 +20,5 @@ public class AppConfig {
     }
 
 }
+
+

+ 3 - 4
electricity/meter/src/main/java/com/gyee/gaia/meter/config/XxlJobConfig.java

@@ -1,8 +1,7 @@
 package com.gyee.gaia.meter.config;
 
 import com.xxl.job.core.executor.impl.XxlJobSpringExecutor;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
+import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.context.annotation.Bean;
 import org.springframework.context.annotation.Configuration;
@@ -12,9 +11,9 @@ import org.springframework.context.annotation.Configuration;
  *
  * @author xuxueli 2017-04-28
  */
+@Slf4j
 @Configuration
 public class XxlJobConfig {
-    private Logger logger = LoggerFactory.getLogger(com.gyee.gaia.meter.config.XxlJobConfig.class);
 
     @Value("${xxl.job.admin.addresses}")
     private String adminAddresses;
@@ -43,7 +42,7 @@ public class XxlJobConfig {
 
     @Bean
     public XxlJobSpringExecutor xxlJobExecutor() {
-        logger.info(">>>>>>>>>>> xxl-job config init.");
+        log.info(">>>>>>>>>>> xxl-job config init.");
         XxlJobSpringExecutor xxlJobSpringExecutor = new XxlJobSpringExecutor();
         xxlJobSpringExecutor.setAdminAddresses(adminAddresses);
         xxlJobSpringExecutor.setAppname(appname);

+ 0 - 1
electricity/meter/src/main/java/com/gyee/gaia/meter/controller/ConfigController.java

@@ -1,6 +1,5 @@
 package com.gyee.gaia.meter.controller;
 
-import com.gyee.gaia.meter.config.AppConfig;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;

+ 0 - 75
electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoCompany.java

@@ -1,75 +0,0 @@
-package com.gyee.gaia.meter.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.extension.activerecord.Model;
-import lombok.Data;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-import java.time.LocalDateTime;
-
-/**
- * <p>
- * 公司日发电量表
- * </p>
- */
-@TableName("meter_info_company")
-@Data
-public class MeterInfoCompany extends Model<MeterInfoCompany> implements Serializable {
-
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * id;主键自增
-     */
-    @TableId(value = "id", type = IdType.AUTO)
-    private Integer id;
-
-    /**
-     * 公司编码;公司编码
-     */
-    private String companyNemCode;
-
-    /**
-     * 名称;公司名称
-     */
-    private String name;
-
-    /**
-     * 日期;日期
-     */
-    private LocalDateTime date;
-
-    /**
-     * 日发电量;单位Kwh
-     */
-    private BigDecimal dailyPower;
-
-    /**
-     * 创建人;创建人
-     */
-    private String createBy;
-
-    /**
-     * 创建时间;创建时间
-     */
-    private LocalDateTime createTime;
-
-    /**
-     * 更新人;更新人
-     */
-    private String updateBy;
-
-    /**
-     * 更新时间;更新时间
-     */
-    private LocalDateTime updateTime;
-
-    /**
-     * 备注;备注
-     */
-    private String remark;
-
-}

+ 0 - 95
electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoLine.java

@@ -1,95 +0,0 @@
-package com.gyee.gaia.meter.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.extension.activerecord.Model;
-import lombok.Data;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-import java.time.LocalDateTime;
-
-/**
- * <p>
- * 线路日发电量表
- * </p>
- */
-@TableName("meter_info_line")
-@Data
-public class MeterInfoLine extends Model<MeterInfoLine> implements Serializable {
-
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * 主键;主键自增
-     */
-    @TableId(value = "id", type = IdType.AUTO)
-    private Integer id;
-
-    /**
-     * 公司编码;公司编码
-     */
-    private String companyNemCode;
-
-    /**
-     * 场站编码;场站编码
-     */
-    private String powerstationNemCode;
-
-    /**
-     * 项目期次编码;项目期次编码
-     */
-    private String projectNemCode;
-
-    /**
-     * 线路编码;线路编码
-     */
-    private String lineNemCode;
-
-    /**
-     * 线路名称;线路名称
-     */
-    private String name;
-
-    /**
-     * 日期;日期
-     */
-    private LocalDateTime date;
-
-    /**
-     * 电计量编码;电计量编码
-     */
-    private BigDecimal metercode;
-
-    /**
-     * 日发电量;日发电量,单位kwh
-     */
-    private BigDecimal rfdl;
-
-    /**
-     * 创建人;创建人
-     */
-    private String createBy;
-
-    /**
-     * 创建时间;创建时间
-     */
-    private LocalDateTime createTime;
-
-    /**
-     * 更新人;更新人
-     */
-    private String updateBy;
-
-    /**
-     * 更新时间;更新时间
-     */
-    private LocalDateTime updateTime;
-
-    /**
-     * 备注;备注
-     */
-    private String remark;
-
-}

+ 0 - 175
electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoPowerstation.java

@@ -1,175 +0,0 @@
-package com.gyee.gaia.meter.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.extension.activerecord.Model;
-import lombok.Data;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-import java.time.LocalDateTime;
-
-/**
- * <p>
- * 场站日发电量表
- * </p>
- */
-@TableName("meter_info_powerstation")
-@Data
-public class MeterInfoPowerstation extends Model<MeterInfoPowerstation> implements Serializable {
-
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * 主键;主键自增
-     */
-    @TableId(value = "id", type = IdType.AUTO)
-    private Integer id;
-
-    /**
-     * 公司编码;公司编码
-     */
-    private String companyNemCode;
-
-    /**
-     * 场站编码;场站编码
-     */
-    private String powerstationNemCode;
-
-    /**
-     * 场站名称;场站名称
-     */
-    private String name;
-
-    /**
-     * 日期;日期
-     */
-    private LocalDateTime date;
-
-    /**
-     * 电计量编码;电计量编码
-     */
-    private BigDecimal metercode;
-
-    /**
-     * 送出电量;电表送出电量,单位kwh*42000
-     */
-    private BigDecimal sudl;
-
-    /**
-     * 受入电量;电表受入电量,单位kwh*42000
-     */
-    private BigDecimal srdl;
-
-    /**
-     * 风机总发电量;风机总发电量,单位万kwh
-     */
-    private BigDecimal fjzfdl;
-
-    /**
-     * 平均风速;平均风速,单位m/s
-     */
-    private BigDecimal pjfs;
-
-    /**
-     * 集电线路总发电量;集电线路总发电量,单位万kwh
-     */
-    private BigDecimal jdxlzfdl;
-
-    /**
-     * 上网电量;111线路侧上网电量,单位万kwh
-     */
-    private BigDecimal swdl;
-
-    /**
-     * 主变上网电量;主变高压侧总上网电量,单位万kwh
-     */
-    private BigDecimal zbswdl;
-
-    /**
-     * 购网电量;111线路侧购网电量,单位万kwh
-     */
-    private BigDecimal gwdl;
-
-    /**
-     * 主变购网电量;主变高压侧总购网电量,单位万kwh
-     */
-    private BigDecimal zbgwdl;
-
-    /**
-     * 风机综合厂用电量;风机侧总综合厂用电量,单位万kwh
-     */
-    private BigDecimal fjzhcydl;
-
-    /**
-     * 集电线路综合厂用电量;集电线路总综合厂用电量,单位万kwh
-     */
-    private BigDecimal jdxlzhcydl;
-
-    /**
-     * 风机综合厂用率;风机侧总综合厂用率,%
-     */
-    private BigDecimal fjzhcyl;
-
-    /**
-     * 集电线路综合厂用率;集电线路总综合厂用率,%
-     */
-    private BigDecimal jdxlzhcyl;
-
-    /**
-     * 发电厂用电量;发电厂用电量,单位万kwh
-     */
-    private BigDecimal fdcydl;
-
-    /**
-     * 发电厂用电率;发电厂用电率(%)
-     */
-    private BigDecimal fdcydlv;
-
-    /**
-     * 风机利用小时;风机侧(总)利用小时
-     */
-    private BigDecimal fjlyxs;
-
-    /**
-     * 集电线路利用小时;集电线路侧(总)利用小时
-     */
-    private BigDecimal jdxllyxs;
-
-    /**
-     * 月报理论发电量;月报理论发电量,单位万kwh
-     */
-    private BigDecimal ybllfdl;
-
-    /**
-     * 理论发电量(SIS统计);理论发电量(SIS统计),单位万kwh
-     */
-    private BigDecimal llfdl;
-
-    /**
-     * 创建人;创建人
-     */
-    private String createBy;
-
-    /**
-     * 创建时间;创建时间
-     */
-    private LocalDateTime createTime;
-
-    /**
-     * 更新人;更新人
-     */
-    private String updateBy;
-
-    /**
-     * 更新时间;更新时间
-     */
-    private LocalDateTime updateTime;
-
-    /**
-     * 备注;备注
-     */
-    private String remark;
-
-}

+ 0 - 190
electricity/meter/src/main/java/com/gyee/gaia/meter/entity/MeterInfoProject.java

@@ -1,190 +0,0 @@
-package com.gyee.gaia.meter.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.extension.activerecord.Model;
-import lombok.Data;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-import java.time.LocalDateTime;
-
-/**
- * <p>
- * 项目期次日发电量表
- * </p>
- */
-@TableName("meter_info_project")
-@Data
-public class MeterInfoProject extends Model<MeterInfoProject> implements Serializable {
-
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * 主键;主键自增
-     */
-    @TableId(value = "id", type = IdType.AUTO)
-    private Integer id;
-
-    /**
-     * 公司编码;公司编码
-     */
-    private String companyNemCode;
-
-    /**
-     * 场站编码;场站编码
-     */
-    private String powerstationNemCode;
-
-    /**
-     * 项目期次编码;项目期次编码
-     */
-    private String projectNemCode;
-
-    /**
-     * 项目期次名称;项目期次名称
-     */
-    private String name;
-
-    /**
-     * 日期;日期
-     */
-    private LocalDateTime date;
-
-    /**
-     * 电计量编码;电计量编码
-     */
-    private BigDecimal metercode;
-
-    /**
-     * 送出电量;电表送出电量,单位kwh*42000
-     */
-    private BigDecimal sudl;
-
-    /**
-     * 受入电量;电表受入电量,单位kwh*42000
-     */
-    private BigDecimal srdl;
-
-    /**
-     * 用变;用变,单位kwh*某倍率(不同站不同)
-     */
-    private BigDecimal yb;
-
-    /**
-     * 电容器;电容器单位kwh*21000
-     */
-    private BigDecimal drq;
-
-    /**
-     * 电抗器;电抗器单位kwh*21000
-     */
-    private BigDecimal dkq;
-
-    /**
-     * SVG;SVG,单位kwh*某倍率
-     */
-    private BigDecimal svg;
-
-    /**
-     * 风机总发电量;风机总发电量,单位万kwh
-     */
-    private BigDecimal fjzfdl;
-
-    /**
-     * 平均风速;平均风速,单位m/s
-     */
-    private BigDecimal pjfs;
-
-    /**
-     * 集电线路总发电量;集电线路总发电量,单位万kwh
-     */
-    private BigDecimal jdxlzfdl;
-
-    /**
-     * 上网电量;111线路侧上网电量,单位万kwh
-     */
-    private BigDecimal swdl;
-
-    /**
-     * 购网电量;111线路侧购网电量,单位万kwh
-     */
-    private BigDecimal gwdl;
-
-    /**
-     * 风机综合厂用电量;风机侧总综合厂用电量,单位万kwh
-     */
-    private BigDecimal fjzhcydl;
-
-    /**
-     * 集电线路综合厂用电量;集电线路总综合厂用电量,单位万kwh
-     */
-    private BigDecimal jdxlzhcydl;
-
-    /**
-     * 风机综合厂用率;风机侧总综合厂用率,%
-     */
-    private BigDecimal fjzhcyl;
-
-    /**
-     * 集电线路综合厂用率;集电线路总综合厂用率,%
-     */
-    private BigDecimal jdxlzhcyl;
-
-    /**
-     * 发电厂用电量;发电厂用电量,单位万kwh
-     */
-    private BigDecimal fdcydl;
-
-    /**
-     * 发电厂用电率;发电厂用电率(%)
-     */
-    private BigDecimal fdcydlv;
-
-    /**
-     * 风机利用小时;风机侧(总)利用小时
-     */
-    private BigDecimal fjlyxs;
-
-    /**
-     * 集电线路利用小时;集电线路侧(总)利用小时
-     */
-    private BigDecimal jdxllyxs;
-
-    /**
-     * 月报理论发电量;月报理论发电量,单位万kwh
-     */
-    private BigDecimal ybllfdl;
-
-    /**
-     * 理论发电量(SIS统计);理论发电量(SIS统计),单位万kwh
-     */
-    private BigDecimal llfdl;
-
-    /**
-     * 创建人;创建人
-     */
-    private String createBy;
-
-    /**
-     * 创建时间;创建时间
-     */
-    private LocalDateTime createTime;
-
-    /**
-     * 更新人;更新人
-     */
-    private String updateBy;
-
-    /**
-     * 更新时间;更新时间
-     */
-    private LocalDateTime updateTime;
-
-    /**
-     * 备注;备注
-     */
-    private String remark;
-
-}

+ 0 - 11
electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoCompanyMapper.java

@@ -1,11 +0,0 @@
-package com.gyee.gaia.meter.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import com.gyee.gaia.meter.entity.MeterInfoCompany;
-import org.apache.ibatis.annotations.Mapper;
-
-
-@Mapper
-public interface MeterInfoCompanyMapper extends BaseMapper<MeterInfoCompany> {
-
-}

+ 0 - 11
electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoLineMapper.java

@@ -1,11 +0,0 @@
-package com.gyee.gaia.meter.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import com.gyee.gaia.meter.entity.MeterInfoLine;
-import org.apache.ibatis.annotations.Mapper;
-
-
-@Mapper
-public interface MeterInfoLineMapper extends BaseMapper<MeterInfoLine> {
-
-}

+ 0 - 11
electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoPowerstationMapper.java

@@ -1,11 +0,0 @@
-package com.gyee.gaia.meter.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import com.gyee.gaia.meter.entity.MeterInfoPowerstation;
-import org.apache.ibatis.annotations.Mapper;
-
-
-@Mapper
-public interface MeterInfoPowerstationMapper extends BaseMapper<MeterInfoPowerstation> {
-
-}

+ 0 - 11
electricity/meter/src/main/java/com/gyee/gaia/meter/mapper/MeterInfoProjectMapper.java

@@ -1,11 +0,0 @@
-package com.gyee.gaia.meter.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import com.gyee.gaia.meter.entity.MeterInfoProject;
-import org.apache.ibatis.annotations.Mapper;
-
-
-@Mapper
-public interface MeterInfoProjectMapper extends BaseMapper<MeterInfoProject> {
-
-}

+ 14 - 10
electricity/meter/src/main/java/com/gyee/gaia/meter/service/AdapterServiceTest.java

@@ -8,8 +8,8 @@ import com.gyee.gaia.meter.adapter.Adapter;
 import com.gyee.gaia.meter.entity.*;
 import com.gyee.gaia.meter.service.impl.*;
 import org.junit.jupiter.api.Test;
+import org.springframework.beans.factory.annotation.Value;
 import org.springframework.boot.test.context.SpringBootTest;
-
 import javax.annotation.Resource;
 import java.math.BigDecimal;
 import java.math.RoundingMode;
@@ -29,7 +29,7 @@ class AdapterServiceTest {
     Adapter adapter;
 
 
-    //测试获取和保存数据
+    //测试适配器读取数据,测试实体类直接保存数据到数据库.
     @Test
     void getHistorySection() {
 
@@ -51,10 +51,14 @@ class AdapterServiceTest {
     @Resource
     EquipmentServiceImpl equipmentService;
 
+    @Value("${start.time}")
+    private String adapterUrl;
+
     //测试读取设备发电量,并写入pg数据库
     @Test
     void saveEquipmentRfdl() {
 
+
         //1,在testingpoint中根据 uniform_code=AI064 和code like "%_FJ_%" 取出所有风机的电量测点code
         List<TestingPoint> list = testingPointService.list(new QueryWrapper<TestingPoint>().eq("uniform_code", "AI064").like("code", "%_FJ_%"));
 
@@ -69,7 +73,7 @@ class AdapterServiceTest {
             String thingId = testingPoint.getThingId();
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime2 = DateUtil.endOfDay(dateTime);
@@ -155,7 +159,7 @@ class AdapterServiceTest {
                 String pointcode = meterPoint.getNemCode();
 
                 //6,设置取值开始日期前一天
-                String str = "2023-04-30";
+                String str = adapterUrl;
 
                 DateTime dateTime = DateUtil.parse(str);
                 DateTime dateTime2 = DateUtil.endOfDay(dateTime);
@@ -233,7 +237,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;
@@ -468,7 +472,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;
@@ -660,7 +664,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;
@@ -839,7 +843,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;
@@ -938,7 +942,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;
@@ -1040,7 +1044,7 @@ class AdapterServiceTest {
 
 
             //6,设置取值开始日期前一天
-            String str = "2023-04-30";
+            String str = adapterUrl;
 
             DateTime dateTime = DateUtil.parse(str);
             DateTime dateTime1 = dateTime;

+ 0 - 16
electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoCompanyService.java

@@ -1,16 +0,0 @@
-package com.gyee.gaia.meter.service;
-
-import com.baomidou.mybatisplus.extension.service.IService;
-import com.gyee.gaia.meter.entity.MeterInfoCompany;
-
-/**
- * <p>
- * 公司日发电量表 服务类
- * </p>
- *
- * @author gfhd
- * @since 2023-04-28
- */
-public interface IMeterInfoCompanyService extends IService<MeterInfoCompany> {
-
-}

+ 0 - 16
electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoLineService.java

@@ -1,16 +0,0 @@
-package com.gyee.gaia.meter.service;
-
-import com.baomidou.mybatisplus.extension.service.IService;
-import com.gyee.gaia.meter.entity.MeterInfoLine;
-
-/**
- * <p>
- * 线路日发电量表 服务类
- * </p>
- *
- * @author gfhd
- * @since 2023-04-28
- */
-public interface IMeterInfoLineService extends IService<MeterInfoLine> {
-
-}

+ 0 - 16
electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoPowerstationService.java

@@ -1,16 +0,0 @@
-package com.gyee.gaia.meter.service;
-
-import com.baomidou.mybatisplus.extension.service.IService;
-import com.gyee.gaia.meter.entity.MeterInfoPowerstation;
-
-/**
- * <p>
- * 场站日发电量表 服务类
- * </p>
- *
- * @author gfhd
- * @since 2023-04-28
- */
-public interface IMeterInfoPowerstationService extends IService<MeterInfoPowerstation> {
-
-}

+ 0 - 16
electricity/meter/src/main/java/com/gyee/gaia/meter/service/IMeterInfoProjectService.java

@@ -1,16 +0,0 @@
-package com.gyee.gaia.meter.service;
-
-import com.baomidou.mybatisplus.extension.service.IService;
-import com.gyee.gaia.meter.entity.MeterInfoProject;
-
-/**
- * <p>
- * 项目期次日发电量表 服务类
- * </p>
- *
- * @author gfhd
- * @since 2023-04-28
- */
-public interface IMeterInfoProjectService extends IService<MeterInfoProject> {
-
-}

+ 0 - 13
electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoCompanyServiceImpl.java

@@ -1,13 +0,0 @@
-package com.gyee.gaia.meter.service.impl;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.gyee.gaia.meter.entity.MeterInfoCompany;
-import com.gyee.gaia.meter.mapper.MeterInfoCompanyMapper;
-import com.gyee.gaia.meter.service.IMeterInfoCompanyService;
-import org.springframework.stereotype.Service;
-
-
-@Service
-public class MeterInfoCompanyServiceImpl extends ServiceImpl<MeterInfoCompanyMapper, MeterInfoCompany> implements IMeterInfoCompanyService {
-
-}

+ 0 - 13
electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoLineServiceImpl.java

@@ -1,13 +0,0 @@
-package com.gyee.gaia.meter.service.impl;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.gyee.gaia.meter.entity.MeterInfoLine;
-import com.gyee.gaia.meter.mapper.MeterInfoLineMapper;
-import com.gyee.gaia.meter.service.IMeterInfoLineService;
-import org.springframework.stereotype.Service;
-
-
-@Service
-public class MeterInfoLineServiceImpl extends ServiceImpl<MeterInfoLineMapper, MeterInfoLine> implements IMeterInfoLineService {
-
-}

+ 0 - 13
electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoPowerstationServiceImpl.java

@@ -1,13 +0,0 @@
-package com.gyee.gaia.meter.service.impl;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.gyee.gaia.meter.entity.MeterInfoPowerstation;
-import com.gyee.gaia.meter.mapper.MeterInfoPowerstationMapper;
-import com.gyee.gaia.meter.service.IMeterInfoPowerstationService;
-import org.springframework.stereotype.Service;
-
-
-@Service
-public class MeterInfoPowerstationServiceImpl extends ServiceImpl<MeterInfoPowerstationMapper, MeterInfoPowerstation> implements IMeterInfoPowerstationService {
-
-}

+ 0 - 12
electricity/meter/src/main/java/com/gyee/gaia/meter/service/impl/MeterInfoProjectServiceImpl.java

@@ -1,12 +0,0 @@
-package com.gyee.gaia.meter.service.impl;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.gyee.gaia.meter.entity.MeterInfoProject;
-import com.gyee.gaia.meter.mapper.MeterInfoProjectMapper;
-import com.gyee.gaia.meter.service.IMeterInfoProjectService;
-import org.springframework.stereotype.Service;
-
-@Service
-public class MeterInfoProjectServiceImpl extends ServiceImpl<MeterInfoProjectMapper, MeterInfoProject> implements IMeterInfoProjectService {
-
-}

+ 12 - 0
electricity/meter/src/main/resources/application.properties

@@ -0,0 +1,12 @@
+##需要动态配置的属性##
+
+#动态配置适配器的地址
+adapter.url=http://192.168.10.18:8011/ts
+#adapter.url=http://192.168.1.82:8011/ts
+
+#动态配置开始日期前一天
+start.time="2023-04-30"
+
+meter.stations=MHS_FDC,NSS_FDC
+
+test.abcd=123456

+ 1 - 2
electricity/meter/src/main/resources/bootstrap.yaml

@@ -43,8 +43,7 @@ spring:
     time-zone: GMT+8
     default-property-inclusion: always
 
-meter:
-  stations: MHS_FDC,NSS_FDC
+
 
 mybatis-plus:
   typeAliasesPackage: com.gyee.gaia.meter.entity

+ 0 - 5
electricity/meter/src/main/resources/mappers-postgresql/MeterInfoCompanyMapper.xml

@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.gyee.gaia.meter.mapper.MeterInfoCompanyMapper">
-
-</mapper>

+ 0 - 5
electricity/meter/src/main/resources/mappers-postgresql/MeterInfoLineMapper.xml

@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.gyee.gaia.meter.mapper.MeterInfoLineMapper">
-
-</mapper>

+ 0 - 5
electricity/meter/src/main/resources/mappers-postgresql/MeterInfoPowerstationMapper.xml

@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.gyee.gaia.meter.mapper.MeterInfoPowerstationMapper">
-
-</mapper>

+ 0 - 5
electricity/meter/src/main/resources/mappers-postgresql/MeterInfoProjectMapper.xml

@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.gyee.gaia.meter.mapper.MeterInfoProjectMapper">
-
-</mapper>