Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
375ea4d5
Commit
375ea4d5
authored
Jul 18, 2023
by
caotao
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://39.98.45.134:8090/moa/amos-boot-biz
into developer
parents
94a897c6
d22562cd
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
53 additions
and
37 deletions
+53
-37
PowerStationProcessStateEnum.java
...ot/module/hygf/api/Enum/PowerStationProcessStateEnum.java
+2
-2
DesignInformation.java
...n/amos/boot/module/hygf/api/entity/DesignInformation.java
+27
-26
PowerStationServiceImpl.java
...module/hygf/biz/service/impl/PowerStationServiceImpl.java
+21
-7
MonitorFanIdxController.java
.../module/jxiop/biz/controller/MonitorFanIdxController.java
+3
-2
No files found.
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/Enum/PowerStationProcessStateEnum.java
View file @
375ea4d5
...
...
@@ -11,8 +11,8 @@ import lombok.Getter;
@AllArgsConstructor
public
enum
PowerStationProcessStateEnum
{
进行中
(
"进行中"
,
"0"
,
"progress"
),
通过
(
"通过"
,
"1"
,
"
yes
"
),
不通过
(
"不通过"
,
"2"
,
"
no
"
),
通过
(
"通过"
,
"1"
,
"
0
"
),
不通过
(
"不通过"
,
"2"
,
"
1
"
),
完成
(
"完成"
,
"3"
,
"complete"
),
作废
(
"作废"
,
"4"
,
"reject"
);
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/entity/DesignInformation.java
View file @
375ea4d5
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.TableName
;
import
com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler
;
...
...
@@ -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
;
/**
* 组件排布图
*/
@TableField
(
value
=
"component_layout"
,
typeHandler
=
FastjsonTypeHandler
.
class
)
@TableField
(
value
=
"component_layout"
,
typeHandler
=
FastjsonTypeHandler
.
class
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
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
;
/**
* 组串接线图
*/
@TableField
(
value
=
"connection_line"
,
typeHandler
=
FastjsonTypeHandler
.
class
)
@TableField
(
value
=
"connection_line"
,
typeHandler
=
FastjsonTypeHandler
.
class
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
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
;
/**
* 组件
*/
@TableField
(
value
=
"assembly"
,
typeHandler
=
FastjsonTypeHandler
.
class
)
@TableField
(
value
=
"assembly"
,
typeHandler
=
FastjsonTypeHandler
.
class
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
List
<
Object
>
assembly
;
/**
* 逆变器
*/
@TableField
(
value
=
"inverter"
,
typeHandler
=
FastjsonTypeHandler
.
class
)
@TableField
(
value
=
"inverter"
,
typeHandler
=
FastjsonTypeHandler
.
class
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
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
;
/**
* 支架
*/
@TableField
(
value
=
"support"
,
typeHandler
=
FastjsonTypeHandler
.
class
)
@TableField
(
value
=
"support"
,
typeHandler
=
FastjsonTypeHandler
.
class
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
List
<
Object
>
support
;
/**
* 防滑雪措施
*/
@TableField
(
"anti_skiing"
)
@TableField
(
value
=
"anti_skiing"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
antiSkiing
;
/**
* 防滑雪措施备注
*/
@TableField
(
"anti_skiing_notes"
)
@TableField
(
value
=
"anti_skiing_notes"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
antiSkiingNotes
;
/**
* 抽检
*/
@TableField
(
"spot_check"
)
@TableField
(
value
=
"spot_check"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
spotCheck
;
/**
* 抽检意见
*/
@TableField
(
"spot_check_opinion"
)
@TableField
(
value
=
"spot_check_opinion"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
spotCheckOpinion
;
/**
* 是否定制
*/
@TableField
(
"isok_customized"
)
@TableField
(
value
=
"isok_customized"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
isokCustomized
;
/**
* 是否加固
*/
@TableField
(
"wind_resistant"
)
@TableField
(
value
=
"wind_resistant"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
windResistant
;
/**
* 试点方案
*/
@TableField
(
"pilot_program"
)
@TableField
(
value
=
"pilot_program"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
pilotProgram
;
/**
* s试点物料
*/
@TableField
(
"pilot_materials"
)
@TableField
(
value
=
"pilot_materials"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
pilotMaterials
;
/**
* 方位角
*/
@TableField
(
"azimuth"
)
@TableField
(
value
=
"azimuth"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
azimuth
;
/**
* 倾角
*/
@TableField
(
"dip_angle"
)
@TableField
(
value
=
"dip_angle"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
dipAngle
;
/**
* 应用场景
*/
@TableField
(
"application_scenario"
)
@TableField
(
value
=
"application_scenario"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
applicationScenario
;
/**
* 应用场景数量
*/
@TableField
(
"application_scenario_num"
)
@TableField
(
value
=
"application_scenario_num"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
Integer
applicationScenarioNum
;
/**
* 支架方案
*/
@TableField
(
"support_scheme"
)
@TableField
(
value
=
"support_scheme"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
supportScheme
;
/**
* 支架方案数量
*/
@TableField
(
"support_scheme_num"
)
@TableField
(
value
=
"support_scheme_num"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
Integer
supportSchemeNum
;
/**
* 特殊方案
*/
@TableField
(
"special_plan"
)
@TableField
(
value
=
"special_plan"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
specialPlan
;
/**
* 特殊方案数量
*/
@TableField
(
"special_plan_num"
)
@TableField
(
value
=
"special_plan_num"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
Integer
specialPlanNum
;
/**
* 农户id
*/
@TableField
(
"peasant_household_id"
)
@TableField
(
value
=
"peasant_household_id"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
String
peasantHouseholdId
;
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/PowerStationServiceImpl.java
View file @
375ea4d5
...
...
@@ -2,8 +2,13 @@ package com.yeejoin.amos.boot.module.hygf.biz.service.impl;
import
com.alibaba.fastjson.JSON
;
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.update.LambdaUpdateWrapper
;
import
com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
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.dto.PowerStationDto
;
...
...
@@ -17,6 +22,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.service.IPowerStationService
;
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
lombok.extern.slf4j.Slf4j
;
import
net.sf.cglib.beans.BeanMap
;
...
...
@@ -29,6 +35,7 @@ import org.springframework.stereotype.Service;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
springfox.documentation.service.ApiListing
;
import
java.util.Date
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -51,11 +58,12 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS
IPowerStationService
powerStationService
;
@Autowired
DesignInformationMapper
designInformationMapper
;
@Autowired
DesignInformationServiceImpl
designInformationService
;
private
static
final
String
IDX_REQUEST_STATE
=
"200"
;
private
static
final
String
VERIFY_RESULT_YES
=
"
yes
"
;
private
static
final
String
VERIFY_RESULT_NO
=
"
no
"
;
private
static
final
String
VERIFY_RESULT_YES
=
"
0
"
;
private
static
final
String
VERIFY_RESULT_NO
=
"
1
"
;
@Autowired
WorkflowFeignClient
workflowFeignClient
;
...
...
@@ -111,7 +119,7 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS
if
(
PowerStationNodeEnum
.
设计上传图纸
.
getCode
().
equals
(
nodeCode
)||
PowerStationNodeEnum
.
经销商上传图纸
.
getCode
().
equals
(
nodeCode
))
{
this
.
updateSeve
(
powerStation
.
getPeasantHouseholdId
(),
kv
);
}
else
{
String
result
=
String
.
valueOf
(
kv
.
get
(
"
VERIFY_RESULT
"
));
String
result
=
String
.
valueOf
(
kv
.
get
(
"
approvalStatue
"
));
if
(
VERIFY_RESULT_NO
.
equals
(
result
))
{
powerStation
.
setProcessStatus
(
PowerStationProcessStateEnum
.
不通过
.
getName
());
}
...
...
@@ -226,10 +234,15 @@ public void updateSeve(String peasantHouseholdId, Map<String, Object> kv ){
designInformationnew
.
setTypicalDiagram
(
designInformation
.
getTypicalDiagram
());
designInformationnew
.
setPeasantHouseholdId
(
peasantHouseholdId
);
designInformationnew
.
setSequenceNbr
(
designInformation
.
getSequenceNbr
());
designInformationnew
.
setRecDate
(
designInformation
.
getRecDate
());
designInformationnew
.
setRecUserId
(
designInformation
.
getRecUserId
());
designInformationnew
.
setRecUserName
(
designInformation
.
getRecUserName
());
designInformationnew
.
setIsDelete
(
designInformation
.
getIsDelete
());
designInformationMapper
.
updateById
(
designInformationnew
);
}
else
{
DesignInformation
designInformationnew
=
this
.
mapToBean
(
kv
,
DesignInformation
.
class
);
DesignInformation
designInformationnew
=
new
DesignInformation
();
designInformationnew
.
setTypicalDiagram
((
List
<
Object
>)
kv
.
get
(
"typicalDiagram"
))
;
designInformationnew
.
setPeasantHouseholdId
(
peasantHouseholdId
);
designInformationMapper
.
insert
(
designInformationnew
);
...
...
@@ -239,11 +252,12 @@ public void updateSeve(String peasantHouseholdId, Map<String, Object> kv ){
public
<
T
>
T
mapToBean
(
Map
<
String
,
Object
>
map
,
Class
<
T
>
clazz
)
{
ObjectMapper
objectMapper
=
new
ObjectMapper
();
T
bean
=
null
;
try
{
bean
=
clazz
.
newInstance
();
BeanMap
beanMap
=
BeanMap
.
create
(
bean
);
beanMap
.
putAll
(
map
);
bean
=
objectMapper
.
convertValue
(
map
,
clazz
);
}
catch
(
Exception
e
){
throw
new
BaseException
(
" 数据转化异常!"
,
"400"
,
"数据转化异常!"
);
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/controller/MonitorFanIdxController.java
View file @
375ea4d5
...
...
@@ -19,6 +19,7 @@ import io.swagger.annotations.ApiOperation;
import
org.eclipse.paho.client.mqttv3.MqttException
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.scheduling.annotation.Scheduled
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
...
...
@@ -411,7 +412,7 @@ public class MonitorFanIdxController extends BaseController {
return
ResponseHelper
.
buildResponse
(
resultsData
);
}
// @Scheduled(cron = "0/10
* * * * ? ")
@Scheduled
(
cron
=
"0/15
* * * * ? "
)
@TycloudOperation
(
needAuth
=
false
,
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
value
=
"模拟量列表消息"
)
@GetMapping
(
"/getAnalogQuantityInfo"
)
...
...
@@ -425,7 +426,7 @@ public class MonitorFanIdxController extends BaseController {
return
CommonResponseUtil
.
success
();
}
// @Scheduled(cron = "0/10
* * * * ? ")
@Scheduled
(
cron
=
"0/15
* * * * ? "
)
@TycloudOperation
(
needAuth
=
false
,
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
value
=
"升压站主屏消息接口"
)
@GetMapping
(
"/getMajorAnalogQuantityByPage"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment