Commit 17d219cd authored by tangwei's avatar tangwei

修改接口

parent 9eafd313
package com.yeejoin.amos.boot.module.hygf.api.entity; package com.yeejoin.amos.boot.module.hygf.api.entity;
import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler; import com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler;
...@@ -27,157 +28,157 @@ public class DesignInformation extends BaseEntity { ...@@ -27,157 +28,157 @@ public class DesignInformation extends BaseEntity {
/** /**
* 典型设计图信息 * 典型设计图信息
*/ */
@TableField(value = "typical_diagram",typeHandler = FastjsonTypeHandler.class) @TableField(value = "typical_diagram",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> typicalDiagram; private List<Object> typicalDiagram;
/** /**
* 组件排布图 * 组件排布图
*/ */
@TableField(value = "component_layout",typeHandler = FastjsonTypeHandler.class) @TableField(value = "component_layout",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> componentLayout; private List<Object> componentLayout;
/** /**
* 组件支架图 * 组件支架图
*/ */
@TableField(value = "component_bracket",typeHandler = FastjsonTypeHandler.class) @TableField(value = "component_bracket",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> componentBracket; private List<Object> componentBracket;
/** /**
* 组串接线图 * 组串接线图
*/ */
@TableField(value = "connection_line",typeHandler = FastjsonTypeHandler.class) @TableField(value = "connection_line",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> connectionLine; private List<Object> connectionLine;
/** /**
* 一次接线图 * 一次接线图
*/ */
@TableField(value = "once_line",typeHandler = FastjsonTypeHandler.class) @TableField(value = "once_line",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> onceLine; private List<Object> onceLine;
/** /**
* 组件 * 组件
*/ */
@TableField(value = "assembly",typeHandler = FastjsonTypeHandler.class) @TableField(value = "assembly",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> assembly; private List<Object> assembly;
/** /**
* 逆变器 * 逆变器
*/ */
@TableField(value = "inverter",typeHandler = FastjsonTypeHandler.class) @TableField(value = "inverter",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> inverter; private List<Object> inverter;
/** /**
* 电表箱 * 电表箱
*/ */
@TableField(value = "electricity_meter",typeHandler = FastjsonTypeHandler.class) @TableField(value = "electricity_meter",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> electricityMeter; private List<Object> electricityMeter;
/** /**
* 支架 * 支架
*/ */
@TableField(value = "support",typeHandler = FastjsonTypeHandler.class) @TableField(value = "support",typeHandler = FastjsonTypeHandler.class,updateStrategy = FieldStrategy.IGNORED)
private List<Object> support; private List<Object> support;
/** /**
* 防滑雪措施 * 防滑雪措施
*/ */
@TableField("anti_skiing") @TableField(value = "anti_skiing",updateStrategy = FieldStrategy.IGNORED)
private String antiSkiing; private String antiSkiing;
/** /**
* 防滑雪措施备注 * 防滑雪措施备注
*/ */
@TableField("anti_skiing_notes") @TableField(value = "anti_skiing_notes",updateStrategy = FieldStrategy.IGNORED)
private String antiSkiingNotes; private String antiSkiingNotes;
/** /**
* 抽检 * 抽检
*/ */
@TableField("spot_check") @TableField(value = "spot_check",updateStrategy = FieldStrategy.IGNORED)
private String spotCheck; private String spotCheck;
/** /**
* 抽检意见 * 抽检意见
*/ */
@TableField("spot_check_opinion") @TableField(value = "spot_check_opinion",updateStrategy = FieldStrategy.IGNORED)
private String spotCheckOpinion; private String spotCheckOpinion;
/** /**
* 是否定制 * 是否定制
*/ */
@TableField("isok_customized") @TableField(value = "isok_customized",updateStrategy = FieldStrategy.IGNORED)
private String isokCustomized; private String isokCustomized;
/** /**
* 是否加固 * 是否加固
*/ */
@TableField("wind_resistant") @TableField(value = "wind_resistant",updateStrategy = FieldStrategy.IGNORED)
private String windResistant; private String windResistant;
/** /**
* 试点方案 * 试点方案
*/ */
@TableField("pilot_program") @TableField(value = "pilot_program",updateStrategy = FieldStrategy.IGNORED)
private String pilotProgram; private String pilotProgram;
/** /**
* s试点物料 * s试点物料
*/ */
@TableField("pilot_materials") @TableField(value = "pilot_materials",updateStrategy = FieldStrategy.IGNORED)
private String pilotMaterials; private String pilotMaterials;
/** /**
* 方位角 * 方位角
*/ */
@TableField("azimuth") @TableField(value = "azimuth",updateStrategy = FieldStrategy.IGNORED)
private String azimuth; private String azimuth;
/** /**
* 倾角 * 倾角
*/ */
@TableField("dip_angle") @TableField(value = "dip_angle",updateStrategy = FieldStrategy.IGNORED)
private String dipAngle; private String dipAngle;
/** /**
* 应用场景 * 应用场景
*/ */
@TableField("application_scenario") @TableField(value = "application_scenario",updateStrategy = FieldStrategy.IGNORED)
private String applicationScenario; private String applicationScenario;
/** /**
* 应用场景数量 * 应用场景数量
*/ */
@TableField("application_scenario_num") @TableField(value = "application_scenario_num",updateStrategy = FieldStrategy.IGNORED)
private Integer applicationScenarioNum; private Integer applicationScenarioNum;
/** /**
* 支架方案 * 支架方案
*/ */
@TableField("support_scheme") @TableField(value = "support_scheme",updateStrategy = FieldStrategy.IGNORED)
private String supportScheme; private String supportScheme;
/** /**
* 支架方案数量 * 支架方案数量
*/ */
@TableField("support_scheme_num") @TableField(value = "support_scheme_num",updateStrategy = FieldStrategy.IGNORED)
private Integer supportSchemeNum; private Integer supportSchemeNum;
/** /**
* 特殊方案 * 特殊方案
*/ */
@TableField("special_plan") @TableField(value = "special_plan",updateStrategy = FieldStrategy.IGNORED)
private String specialPlan; private String specialPlan;
/** /**
* 特殊方案数量 * 特殊方案数量
*/ */
@TableField("special_plan_num") @TableField(value = "special_plan_num",updateStrategy = FieldStrategy.IGNORED)
private Integer specialPlanNum; private Integer specialPlanNum;
/** /**
* 农户id * 农户id
*/ */
@TableField("peasant_household_id") @TableField(value = "peasant_household_id",updateStrategy = FieldStrategy.IGNORED)
private String peasantHouseholdId; private String peasantHouseholdId;
} }
...@@ -2,8 +2,12 @@ package com.yeejoin.amos.boot.module.hygf.biz.service.impl; ...@@ -2,8 +2,12 @@ package com.yeejoin.amos.boot.module.hygf.biz.service.impl;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler;
import com.yeejoin.amos.boot.module.hygf.api.Enum.PowerStationNodeEnum; import com.yeejoin.amos.boot.module.hygf.api.Enum.PowerStationNodeEnum;
import com.yeejoin.amos.boot.module.hygf.api.Enum.PowerStationProcessStateEnum; import com.yeejoin.amos.boot.module.hygf.api.Enum.PowerStationProcessStateEnum;
import com.yeejoin.amos.boot.module.hygf.api.dto.PowerStationDto; import com.yeejoin.amos.boot.module.hygf.api.dto.PowerStationDto;
...@@ -17,6 +21,7 @@ import com.yeejoin.amos.boot.module.hygf.api.mapper.PeasantHouseholdMapper; ...@@ -17,6 +21,7 @@ import com.yeejoin.amos.boot.module.hygf.api.mapper.PeasantHouseholdMapper;
import com.yeejoin.amos.boot.module.hygf.api.mapper.PowerStationMapper; import com.yeejoin.amos.boot.module.hygf.api.mapper.PowerStationMapper;
import com.yeejoin.amos.boot.module.hygf.api.service.IPowerStationService; import com.yeejoin.amos.boot.module.hygf.api.service.IPowerStationService;
import com.yeejoin.amos.boot.module.hygf.biz.feign.WorkflowFeignClient; import com.yeejoin.amos.boot.module.hygf.biz.feign.WorkflowFeignClient;
import com.yeejoin.amos.boot.module.jxiop.api.service.IDesignInformationService;
import com.yeejoin.amos.component.feign.model.FeignClientResult; import com.yeejoin.amos.component.feign.model.FeignClientResult;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import net.sf.cglib.beans.BeanMap; import net.sf.cglib.beans.BeanMap;
...@@ -29,6 +34,7 @@ import org.springframework.stereotype.Service; ...@@ -29,6 +34,7 @@ import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import springfox.documentation.service.ApiListing; import springfox.documentation.service.ApiListing;
import java.util.Date;
import java.util.LinkedHashMap; import java.util.LinkedHashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -51,7 +57,8 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS ...@@ -51,7 +57,8 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS
IPowerStationService powerStationService; IPowerStationService powerStationService;
@Autowired @Autowired
DesignInformationMapper designInformationMapper; DesignInformationMapper designInformationMapper;
@Autowired
DesignInformationServiceImpl designInformationService;
private static final String IDX_REQUEST_STATE="200"; private static final String IDX_REQUEST_STATE="200";
private static final String VERIFY_RESULT_YES="yes"; private static final String VERIFY_RESULT_YES="yes";
...@@ -226,10 +233,23 @@ public void updateSeve(String peasantHouseholdId, Map<String, Object> kv ){ ...@@ -226,10 +233,23 @@ public void updateSeve(String peasantHouseholdId, Map<String, Object> kv ){
designInformationnew.setTypicalDiagram(designInformation.getTypicalDiagram()); designInformationnew.setTypicalDiagram(designInformation.getTypicalDiagram());
designInformationnew.setPeasantHouseholdId(peasantHouseholdId); designInformationnew.setPeasantHouseholdId(peasantHouseholdId);
designInformationnew.setSequenceNbr(designInformation.getSequenceNbr()); designInformationnew.setSequenceNbr(designInformation.getSequenceNbr());
designInformationnew.setRecDate(designInformation.getRecDate());
designInformationnew.setRecUserId(designInformation.getRecUserId());
designInformationnew.setRecUserName(designInformation.getRecUserName());
designInformationnew.setIsDelete(designInformation.getIsDelete());
designInformationnew.setComponentLayout(kv.containsKey("componentLayout")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setComponentBracket( kv.containsKey("componentBracket")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setConnectionLine( kv.containsKey("connectionLine")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setOnceLine( kv.containsKey("onceLine")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setAssembly( kv.containsKey("assembly")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setInverter( kv.containsKey("inverter")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setElectricityMeter( kv.containsKey("electricityMeter")?(List<Object>)kv.get("componentLayout"):null);
designInformationnew.setSupport( kv.containsKey("support")?(List<Object>)kv.get("componentLayout"):null);
designInformationMapper.updateById(designInformationnew); designInformationMapper.updateById(designInformationnew);
}else{ }else{
DesignInformation designInformationnew=this.mapToBean(kv,DesignInformation.class); DesignInformation designInformationnew=new DesignInformation();
designInformationnew.setTypicalDiagram((List<Object>)kv.get("typicalDiagram")) ;
designInformationnew.setPeasantHouseholdId(peasantHouseholdId); designInformationnew.setPeasantHouseholdId(peasantHouseholdId);
designInformationMapper.insert(designInformationnew); designInformationMapper.insert(designInformationnew);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment