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
b86478b9
Commit
b86478b9
authored
Dec 29, 2021
by
helinlin
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/developer' into developer
parents
83df507d
09a7eabd
Show whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
1300 additions
and
35 deletions
+1300
-35
InformWorkFlowEnum.java
...in/amos/boot/module/tzs/api/enums/InformWorkFlowEnum.java
+42
-0
EquipmentDto.java
...eejoin/amos/boot/module/tzs/flc/api/dto/EquipmentDto.java
+13
-1
EquipmentIndexInformDto.java
.../boot/module/tzs/flc/api/dto/EquipmentIndexInformDto.java
+42
-0
EquipmentInformDto.java
.../amos/boot/module/tzs/flc/api/dto/EquipmentInformDto.java
+7
-0
InformEquipmentDto.java
.../amos/boot/module/tzs/flc/api/dto/InformEquipmentDto.java
+12
-0
InformProcessInfoDto.java
...mos/boot/module/tzs/flc/api/dto/InformProcessInfoDto.java
+48
-0
Equipment.java
...eejoin/amos/boot/module/tzs/flc/api/entity/Equipment.java
+26
-1
EquipmentIndexInform.java
.../boot/module/tzs/flc/api/entity/EquipmentIndexInform.java
+61
-0
EquipmentInform.java
.../amos/boot/module/tzs/flc/api/entity/EquipmentInform.java
+12
-1
InformEquipment.java
.../amos/boot/module/tzs/flc/api/entity/InformEquipment.java
+25
-0
InformProcessInfo.java
...mos/boot/module/tzs/flc/api/entity/InformProcessInfo.java
+73
-0
EquipmentInformStatusEnum.java
...t/module/tzs/flc/api/enums/EquipmentInformStatusEnum.java
+2
-1
EquipmentIndexInformMapper.java
...module/tzs/flc/api/mapper/EquipmentIndexInformMapper.java
+14
-0
InformProcessInfoMapper.java
...ot/module/tzs/flc/api/mapper/InformProcessInfoMapper.java
+14
-0
IEquipmentIndexInformService.java
...ule/tzs/flc/api/service/IEquipmentIndexInformService.java
+12
-0
IEquipmentInformService.java
...t/module/tzs/flc/api/service/IEquipmentInformService.java
+67
-2
IInformProcessInfoService.java
...module/tzs/flc/api/service/IInformProcessInfoService.java
+19
-0
EquipmentIndexInformMapper.xml
.../src/main/resources/mapper/EquipmentIndexInformMapper.xml
+5
-0
EquipmentInformMapper.xml
...s-api/src/main/resources/mapper/EquipmentInformMapper.xml
+3
-1
InformProcessInfoMapper.xml
...api/src/main/resources/mapper/InformProcessInfoMapper.xml
+5
-0
DownloadFileService.java
...yeejoin/equipmanage/service/impl/DownloadFileService.java
+3
-3
EquipmentSpecificSerivceImpl.java
...quipmanage/service/impl/EquipmentSpecificSerivceImpl.java
+1
-0
EquipmentIndexInformController.java
...zs/flc/biz/controller/EquipmentIndexInformController.java
+116
-0
EquipmentInformController.java
...ule/tzs/flc/biz/controller/EquipmentInformController.java
+85
-11
InformProcessInfoController.java
...e/tzs/flc/biz/controller/InformProcessInfoController.java
+116
-0
EquipmentIndexInformServiceImpl.java
...flc/biz/service/impl/EquipmentIndexInformServiceImpl.java
+34
-0
EquipmentInformServiceImpl.java
.../tzs/flc/biz/service/impl/EquipmentInformServiceImpl.java
+334
-12
InformEquipmentServiceImpl.java
.../tzs/flc/biz/service/impl/InformEquipmentServiceImpl.java
+8
-2
InformProcessInfoServiceImpl.java
...zs/flc/biz/service/impl/InformProcessInfoServiceImpl.java
+71
-0
application.properties
...boot-system-tzs/src/main/resources/application.properties
+5
-0
tzs-1.0.0.0.xml
...ystem-tzs/src/main/resources/db/changelog/tzs-1.0.0.0.xml
+25
-0
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/api/enums/InformWorkFlowEnum.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
api
.
enums
;
import
lombok.AllArgsConstructor
;
@AllArgsConstructor
public
enum
InformWorkFlowEnum
{
企业提交审批
(
"submitInform"
,
"企业提交审批"
,
"0"
),
接收方接收告知书
(
"acceptInform"
,
"接收方接收告知书"
,
"9"
),
接收方移交告知书
(
"transferInform"
,
"接收方移交告知书"
,
"1"
),
企业撤回告知书
(
"withdrawInform"
,
"企业撤回告知书"
,
"2"
),
接收方驳回告知书
(
"dismissInform"
,
"接收方驳回告知书"
,
"3"
),
企业撤销告知书
(
"cancelInform"
,
"企业撤销告知书"
,
"-1"
);
private
String
code
;
//流程编码
private
String
stage
;
//流程阶段
private
String
processStatus
;
// 流程状态
public
String
getCode
()
{
return
code
;
}
public
void
setCode
(
String
code
)
{
this
.
code
=
code
;
}
public
String
getStage
()
{
return
stage
;
}
public
void
setStage
(
String
stage
)
{
this
.
stage
=
stage
;
}
public
String
getProcessStatus
()
{
return
processStatus
;
}
public
void
setProcessStatus
(
String
processStatus
)
{
this
.
processStatus
=
processStatus
;
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/EquipmentDto.java
View file @
b86478b9
...
...
@@ -79,7 +79,7 @@ public class EquipmentDto extends BaseDto {
private
String
productCode
;
@ApiModelProperty
(
value
=
"监督检验机构"
)
private
Lo
ng
supervisionAgency
;
private
Stri
ng
supervisionAgency
;
@ApiModelProperty
(
value
=
"检验报告编号"
)
private
String
inspectionReportCode
;
...
...
@@ -101,4 +101,16 @@ public class EquipmentDto extends BaseDto {
@ApiModelProperty
(
value
=
"设备所属单位"
)
private
String
equipUnit
;
@ApiModelProperty
(
value
=
"详细地址"
)
private
String
address
;
@ApiModelProperty
(
value
=
"经度"
)
private
String
longitude
;
@ApiModelProperty
(
value
=
"纬度"
)
private
String
latitude
;
@ApiModelProperty
(
value
=
"所属区域代码"
)
private
String
regionCode
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/EquipmentIndexInformDto.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.util.Date
;
/**
* 设备指标
*
* @author system_generator
* @date 2021-12-29
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"EquipmentIndexInformDto"
,
description
=
"设备指标"
)
public
class
EquipmentIndexInformDto
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"设备id"
)
private
Long
equipmentId
;
@ApiModelProperty
(
value
=
"设备名称"
)
private
String
equipmentName
;
@ApiModelProperty
(
value
=
"指标值"
)
private
String
value
;
@ApiModelProperty
(
value
=
"装备定义指标id"
)
private
Long
defIndexId
;
@ApiModelProperty
(
value
=
"装备定义指标名称"
)
private
String
defIndexName
;
@ApiModelProperty
(
value
=
"装备定义指标key"
)
private
String
defIndexKey
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/EquipmentInformDto.java
View file @
b86478b9
...
...
@@ -148,4 +148,11 @@ public class EquipmentInformDto extends BaseDto {
@ApiModelProperty
(
value
=
"施工区域"
)
private
String
productArea
;
@ApiModelProperty
(
value
=
"流程ID"
)
private
String
processId
;
@ApiModelProperty
(
value
=
"流程状态"
)
private
String
processStatus
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/InformEquipmentDto.java
View file @
b86478b9
...
...
@@ -108,4 +108,16 @@ public class InformEquipmentDto extends BaseDto {
private
List
<
EquipmentIndexDto
>
equipmentIndex
;
@ApiModelProperty
(
value
=
"详细地址"
)
private
String
address
;
@ApiModelProperty
(
value
=
"经度"
)
private
String
longitude
;
@ApiModelProperty
(
value
=
"纬度"
)
private
String
latitude
;
@ApiModelProperty
(
value
=
"所属区域代码"
)
private
String
regionCode
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/InformProcessInfoDto.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.util.Date
;
/**
* 通话记录附件
*
* @author system_generator
* @date 2021-12-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"InformProcessInfoDto"
,
description
=
"通话记录附件"
)
public
class
InformProcessInfoDto
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"流转内容"
)
private
String
processInfo
;
@ApiModelProperty
(
value
=
"流程操作人"
)
private
String
handler
;
@ApiModelProperty
(
value
=
"操作人所属单位id"
)
private
Long
handlerUnitId
;
@ApiModelProperty
(
value
=
"流程状态"
)
private
String
processStatus
;
@ApiModelProperty
(
value
=
"流程操作人id"
)
private
Long
handlerId
;
@ApiModelProperty
(
value
=
"操作人所属单位"
)
private
String
handlerUnit
;
@ApiModelProperty
(
value
=
"流程id"
)
private
String
processId
;
@ApiModelProperty
(
value
=
"告知书id"
)
private
Long
informId
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/Equipment.java
View file @
b86478b9
...
...
@@ -129,7 +129,7 @@ public class Equipment extends BaseEntity {
* 监督检验机构
*/
@TableField
(
"supervision_agency"
)
private
Lo
ng
supervisionAgency
;
private
Stri
ng
supervisionAgency
;
/**
* 检验报告编号
...
...
@@ -155,4 +155,29 @@ public class Equipment extends BaseEntity {
@TableField
(
"equip_unit"
)
private
String
equipUnit
;
/**
* 详细地址
*/
@TableField
(
"address"
)
private
String
address
;
/**
* 经度
*/
@TableField
(
"longitude"
)
private
String
longitude
;
/**
* 纬度
*/
@TableField
(
"latitude"
)
private
String
latitude
;
/**
* 所属区域代码
*/
@TableField
(
"region_code"
)
private
String
regionCode
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/EquipmentIndexInform.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yeejoin.amos.boot.biz.common.entity.BaseEntity
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
import
java.util.Date
;
/**
* 设备指标
*
* @author system_generator
* @date 2021-12-29
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@Accessors
(
chain
=
true
)
@TableName
(
"tcb_equipment_index_inform"
)
public
class
EquipmentIndexInform
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 设备id
*/
@TableField
(
"equipment_id"
)
private
Long
equipmentId
;
/**
* 设备名称
*/
@TableField
(
"equipment_name"
)
private
String
equipmentName
;
/**
* 指标值
*/
@TableField
(
"value"
)
private
String
value
;
/**
* 装备定义指标id
*/
@TableField
(
"def_index_id"
)
private
Long
defIndexId
;
/**
* 装备定义指标名称
*/
@TableField
(
"def_index_name"
)
private
String
defIndexName
;
/**
* 装备定义指标key
*/
@TableField
(
"def_index_key"
)
private
String
defIndexKey
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/EquipmentInform.java
View file @
b86478b9
...
...
@@ -215,9 +215,20 @@ public class EquipmentInform extends BaseEntity {
private
String
informCode
;
/**
* 告知单状态 0 暂存 1未接收
9
已接收
* 告知单状态 0 暂存 1未接收
2
已接收
*/
@TableField
(
"inform_status"
)
private
String
informStatus
;
/**
* 流程ID
*/
@TableField
(
"process_id"
)
private
String
processId
;
/**
* 流程状态
*/
@TableField
(
"process_status"
)
private
String
processStatus
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/InformEquipment.java
View file @
b86478b9
...
...
@@ -165,4 +165,29 @@ public class InformEquipment extends BaseEntity {
*/
@TableField
(
"source_equipment_id"
)
private
Long
sourceEquipmentId
;
/**
* 详细地址
*/
@TableField
(
"address"
)
private
String
address
;
/**
* 经度
*/
@TableField
(
"longitude"
)
private
String
longitude
;
/**
* 纬度
*/
@TableField
(
"latitude"
)
private
String
latitude
;
/**
* 所属区域代码
*/
@TableField
(
"region_code"
)
private
String
regionCode
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/InformProcessInfo.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yeejoin.amos.boot.biz.common.entity.BaseEntity
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
import
java.util.Date
;
/**
* 通话记录附件
*
* @author system_generator
* @date 2021-12-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@Accessors
(
chain
=
true
)
@TableName
(
"tz_inform_process_info"
)
public
class
InformProcessInfo
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 流转内容
*/
@TableField
(
"process_info"
)
private
String
processInfo
;
/**
* 流程操作人
*/
@TableField
(
"handler"
)
private
String
handler
;
/**
* 操作人所属单位id
*/
@TableField
(
"handler_unit_id"
)
private
Long
handlerUnitId
;
/**
* 流程状态
*/
@TableField
(
"process_status"
)
private
String
processStatus
;
/**
* 流程操作人id
*/
@TableField
(
"handler_id"
)
private
Long
handlerId
;
/**
* 操作人所属单位
*/
@TableField
(
"handler_unit"
)
private
String
handlerUnit
;
/**
* 流程id
*/
@TableField
(
"process_id"
)
private
String
processId
;
/**
* 告知书id
*/
@TableField
(
"inform_id"
)
private
Long
informId
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/enums/EquipmentInformStatusEnum.java
View file @
b86478b9
...
...
@@ -10,7 +10,8 @@ public enum EquipmentInformStatusEnum {
暂存
(
"0"
,
"暂存"
),
未接收
(
"1"
,
"未接收"
),
已接收
(
"2"
,
"已接收"
);
已接收
(
"2"
,
"已接收"
),
已驳回
(
"9"
,
"已驳回"
);
private
String
code
;
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/mapper/EquipmentIndexInformMapper.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentIndexInform
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* 设备指标 Mapper 接口
*
* @author system_generator
* @date 2021-12-29
*/
public
interface
EquipmentIndexInformMapper
extends
BaseMapper
<
EquipmentIndexInform
>
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/mapper/InformProcessInfoMapper.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.InformProcessInfo
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* 通话记录附件 Mapper 接口
*
* @author system_generator
* @date 2021-12-27
*/
public
interface
InformProcessInfoMapper
extends
BaseMapper
<
InformProcessInfo
>
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IEquipmentIndexInformService.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
service
;
/**
* 设备指标接口类
*
* @author system_generator
* @date 2021-12-29
*/
public
interface
IEquipmentIndexInformService
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IEquipmentInformService.java
View file @
b86478b9
...
...
@@ -15,7 +15,7 @@ import java.util.List;
*/
public
interface
IEquipmentInformService
{
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
);
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
,
ReginParams
userInfo
);
Page
<
EquipmentInformDto
>
queryDtoList
(
Page
<
EquipmentInformDto
>
page
,
EquipmentInformDto
equipmentInformDto
,
String
sortParam
,
String
sortRule
);
...
...
@@ -23,9 +23,74 @@ public interface IEquipmentInformService {
Boolean
acceptInform
(
Long
sequenceNbr
);
EquipmentInformDto
updateEquipmentInform
(
EquipmentInformDto
model
);
EquipmentInformDto
updateEquipmentInform
(
EquipmentInformDto
model
,
ReginParams
userInfo
);
EquipmentInformDto
queryDtoBySeq
(
Long
sequenceNbr
);
/**
* 启动 告知书流程
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
startWorkflow
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 接收方接收告知书
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
acceptInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 企业移交告知书
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
transferInform
(
Long
sequenceNbr
,
ReginParams
userInfo
,
Long
transferUnitId
)
throws
Exception
;
/**
* 企业撤回告知书
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
withdrawInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 接收方驳回告知书
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
dismissInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 企业撤销告知书
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
cancelInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 企业再次提交
* @param sequenceNbr
* @param userInfo
* @return
* @throws Exception
*/
Boolean
reSubmit
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
;
/**
* 监管端撤回已经通过的告知书
* @param sequenceNbr
* @return
*/
Boolean
callbackInform
(
Long
sequenceNbr
);
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IInformProcessInfoService.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
service
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
/**
* 通话记录附件接口类
*
* @author system_generator
* @date 2021-12-27
*/
public
interface
IInformProcessInfoService
{
// 保存流程过程记录
Boolean
saveProcessInfo
(
EquipmentInformDto
model
,
ReginParams
userInfo
,
String
processStage
)
throws
Exception
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/EquipmentIndexInformMapper.xml
0 → 100644
View file @
b86478b9
<?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.yeejoin.amos.boot.module.tzs.flc.api.mapper.EquipmentIndexInformMapper"
>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/EquipmentInformMapper.xml
View file @
b86478b9
...
...
@@ -18,8 +18,10 @@
'暂存'
WHEN 1 THEN
'未接收'
WHEN
9
THEN
WHEN
2
THEN
'已接收'
WHEN 9 THEN
'已驳回'
ELSE
''
END AS informStatus,
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/InformProcessInfoMapper.xml
0 → 100644
View file @
b86478b9
<?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.yeejoin.amos.boot.module.tzs.flc.api.mapper.InformProcessInfoMapper"
>
</mapper>
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/DownloadFileService.java
View file @
b86478b9
...
...
@@ -75,13 +75,13 @@ public class DownloadFileService implements IDownloadFileService {
//装备信息
//
appDownload.setDownloadEquipmentDatas(equipmentMapper.getDownloadEquipmentData());
appDownload
.
setDownloadEquipmentDatas
(
equipmentMapper
.
getDownloadEquipmentData
());
//
// //性能指标模板
// appDownload.setEquipmentIndex(equipmentIndexService.list(queryWrapper1
));
appDownload
.
setEquipmentIndex
(
equipmentIndexService
.
list
(
));
//
// //性能指标
// appDownload.setEquipmentSpecificIndexs(equipmentSpecificIndexSerivce.list(queryWrapper
));
appDownload
.
setEquipmentSpecificIndexs
(
equipmentSpecificIndexSerivce
.
list
(
));
//仓库
appDownload
.
setWarehouseStructure
(
warehouseStructureService
.
list
());
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/EquipmentSpecificSerivceImpl.java
View file @
b86478b9
...
...
@@ -1067,6 +1067,7 @@ public class EquipmentSpecificSerivceImpl extends ServiceImpl<EquipmentSpecificM
AlamVideoVO
video
=
videoMapper
.
getVideoById
(
id
);
if
(!
ObjectUtils
.
isEmpty
(
video
)){
video
.
setUrl
(
videoService
.
getVideoUrl
(
video
.
getName
().
toString
(),
video
.
getPresetPosition
(),
video
.
getUrl
(),
video
.
getCode
()));
video
.
setId
(
id
);
}
return
video
;
}
else
{
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/EquipmentIndexInformController.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.Api
;
import
org.springframework.web.bind.annotation.RestController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
java.util.List
;
import
com.yeejoin.amos.boot.module.tzs.flc.biz.service.impl.EquipmentIndexInformServiceImpl
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
javax.servlet.http.HttpServletRequest
;
import
org.springframework.web.bind.annotation.*
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentIndexInformDto
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
/**
* 设备指标
*
* @author system_generator
* @date 2021-12-29
*/
@RestController
@Api
(
tags
=
"设备指标Api"
)
@RequestMapping
(
value
=
"/equipment-index-inform"
)
public
class
EquipmentIndexInformController
extends
BaseController
{
@Autowired
EquipmentIndexInformServiceImpl
equipmentIndexInformServiceImpl
;
/**
* 新增设备指标
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增设备指标"
,
notes
=
"新增设备指标"
)
public
ResponseModel
<
EquipmentIndexInformDto
>
save
(
@RequestBody
EquipmentIndexInformDto
model
)
{
model
=
equipmentIndexInformServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新设备指标"
,
notes
=
"根据sequenceNbr更新设备指标"
)
public
ResponseModel
<
EquipmentIndexInformDto
>
updateBySequenceNbrEquipmentIndexInform
(
@RequestBody
EquipmentIndexInformDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
equipmentIndexInformServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除设备指标"
,
notes
=
"根据sequenceNbr删除设备指标"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
){
return
ResponseHelper
.
buildResponse
(
equipmentIndexInformServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个设备指标"
,
notes
=
"根据sequenceNbr查询单个设备指标"
)
public
ResponseModel
<
EquipmentIndexInformDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
equipmentIndexInformServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备指标分页查询"
,
notes
=
"设备指标分页查询"
)
public
ResponseModel
<
Page
<
EquipmentIndexInformDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
EquipmentIndexInformDto
>
page
=
new
Page
<
EquipmentIndexInformDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
equipmentIndexInformServiceImpl
.
queryForEquipmentIndexInformPage
(
page
));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备指标列表全部数据查询"
,
notes
=
"设备指标列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
EquipmentIndexInformDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
equipmentIndexInformServiceImpl
.
queryForEquipmentIndexInformList
());
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/EquipmentInformController.java
View file @
b86478b9
...
...
@@ -63,30 +63,32 @@ public class EquipmentInformController extends BaseController {
}
/**
* 新增设备告知单
* 暂存新增设备告知单 有id 为更新无id 为新增
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"
新增设备告知单"
,
notes
=
"新增设备告知单
"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"
暂存新增设备告知单 有id 为更新无id 为新增"
,
notes
=
"暂存新增设备告知单 有id 为更新无id 为新增
"
)
public
ResponseModel
<
EquipmentInformDto
>
save
(
@RequestBody
EquipmentInformDto
model
)
{
model
=
equipmentInformServiceImpl
.
createEquipmentInform
(
model
);
model
=
equipmentInformServiceImpl
.
createEquipmentInform
(
model
,
getSelectedOrgInfo
()
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
* 提交设备告知单
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/updateEquipmentInform"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新设备告知单"
,
notes
=
"根据sequenceNbr更新设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
updateBySequenceNbrEquipmentInform
(
@RequestBody
EquipmentInformDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
updateWithModel
(
model
));
@PostMapping
(
value
=
"/submit"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"提交设备告知单"
,
notes
=
"提交设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
submit
(
@RequestBody
EquipmentInformDto
model
)
{
if
(
ValidationUtil
.
isEmpty
(
model
.
getSequenceNbr
()))
{
throw
new
BadRequest
(
"参数校验失败."
);
}
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
updateEquipmentInform
(
model
,
getSelectedOrgInfo
()));
}
...
...
@@ -100,7 +102,7 @@ public class EquipmentInformController extends BaseController {
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个设备告知单"
,
notes
=
"根据sequenceNbr查询单个设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
queryBySeq
(
sequenceNbr
));
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
query
Dto
BySeq
(
sequenceNbr
));
}
...
...
@@ -153,8 +155,80 @@ public class EquipmentInformController extends BaseController {
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
batchDelete
(
sequenceNbrList
));
}
/**
* 企业通过流程
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/finishWorkflow/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"通过流程"
,
notes
=
"测试通过流程"
)
public
ResponseModel
<
Boolean
>
finishWorkflow
(
@PathVariable
Long
sequenceNbr
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
acceptInform
(
sequenceNbr
,
getSelectedOrgInfo
()));
}
/**
* 接收方驳回告知书
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/dismissInform/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"接收方驳回告知书"
,
notes
=
"接收方驳回告知书"
)
public
ResponseModel
<
Boolean
>
dismissInform
(
@PathVariable
Long
sequenceNbr
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
dismissInform
(
sequenceNbr
,
getSelectedOrgInfo
()));
}
/**
* 企业撤回告知书
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/withdrawInform/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"企业撤回告知书"
,
notes
=
"企业撤回告知书"
)
public
ResponseModel
<
Boolean
>
withdrawInform
(
@PathVariable
Long
sequenceNbr
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
withdrawInform
(
sequenceNbr
,
getSelectedOrgInfo
()));
}
/**
* 接收方移交告知书
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/transferInform/{sequenceNbr}/{transferUnitId}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"接收方移交告知书"
,
notes
=
"接收方移交告知书"
)
public
ResponseModel
<
Boolean
>
transferInform
(
@PathVariable
Long
sequenceNbr
,
@PathVariable
Long
transferUnitId
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
transferInform
(
sequenceNbr
,
getSelectedOrgInfo
(),
transferUnitId
));
}
/**
* 企业废弃告知书
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/cancelInform/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"企业废弃告知书"
,
notes
=
"企业废弃告知书"
)
public
ResponseModel
<
Boolean
>
cancelInform
(
@PathVariable
Long
sequenceNbr
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
cancelInform
(
sequenceNbr
,
getSelectedOrgInfo
()));
}
/**
* 监管端撤回已经通过的申请
* @param sequenceNbr
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/callbackInform/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"监管端撤回已经通过的申请"
,
notes
=
"监管端撤回已经通过的申请"
)
public
ResponseModel
<
Boolean
>
callbackInform
(
@PathVariable
Long
sequenceNbr
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
callbackInform
(
sequenceNbr
));
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/InformProcessInfoController.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.Api
;
import
org.springframework.web.bind.annotation.RestController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
java.util.List
;
import
com.yeejoin.amos.boot.module.tzs.flc.biz.service.impl.InformProcessInfoServiceImpl
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
javax.servlet.http.HttpServletRequest
;
import
org.springframework.web.bind.annotation.*
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.InformProcessInfoDto
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
/**
* 通话记录附件
*
* @author system_generator
* @date 2021-12-27
*/
@RestController
@Api
(
tags
=
"通话记录附件Api"
)
@RequestMapping
(
value
=
"/inform-process-info"
)
public
class
InformProcessInfoController
extends
BaseController
{
@Autowired
InformProcessInfoServiceImpl
informProcessInfoServiceImpl
;
/**
* 新增通话记录附件
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增通话记录附件"
,
notes
=
"新增通话记录附件"
)
public
ResponseModel
<
InformProcessInfoDto
>
save
(
@RequestBody
InformProcessInfoDto
model
)
{
model
=
informProcessInfoServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新通话记录附件"
,
notes
=
"根据sequenceNbr更新通话记录附件"
)
public
ResponseModel
<
InformProcessInfoDto
>
updateBySequenceNbrInformProcessInfo
(
@RequestBody
InformProcessInfoDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
informProcessInfoServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除通话记录附件"
,
notes
=
"根据sequenceNbr删除通话记录附件"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
){
return
ResponseHelper
.
buildResponse
(
informProcessInfoServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个通话记录附件"
,
notes
=
"根据sequenceNbr查询单个通话记录附件"
)
public
ResponseModel
<
InformProcessInfoDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
informProcessInfoServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"通话记录附件分页查询"
,
notes
=
"通话记录附件分页查询"
)
public
ResponseModel
<
Page
<
InformProcessInfoDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
InformProcessInfoDto
>
page
=
new
Page
<
InformProcessInfoDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
informProcessInfoServiceImpl
.
queryForInformProcessInfoPage
(
page
));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"通话记录附件列表全部数据查询"
,
notes
=
"通话记录附件列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
InformProcessInfoDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
informProcessInfoServiceImpl
.
queryForInformProcessInfoList
());
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/EquipmentIndexInformServiceImpl.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentIndexInform
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.mapper.EquipmentIndexInformMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IEquipmentIndexInformService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentIndexInformDto
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
java.util.List
;
/**
* 设备指标服务实现类
*
* @author system_generator
* @date 2021-12-29
*/
@Service
public
class
EquipmentIndexInformServiceImpl
extends
BaseService
<
EquipmentIndexInformDto
,
EquipmentIndexInform
,
EquipmentIndexInformMapper
>
implements
IEquipmentIndexInformService
{
/**
* 分页查询
*/
public
Page
<
EquipmentIndexInformDto
>
queryForEquipmentIndexInformPage
(
Page
<
EquipmentIndexInformDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
* 列表查询 示例
*/
public
List
<
EquipmentIndexInformDto
>
queryForEquipmentIndexInformList
()
{
return
this
.
queryForList
(
""
,
false
);
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/EquipmentInformServiceImpl.java
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.workflow.feign.WorkflowFeignService
;
import
com.yeejoin.amos.boot.module.common.api.dto.AttachmentDto
;
import
com.yeejoin.amos.boot.module.common.api.dto.FailureDetailsDto
;
import
com.yeejoin.amos.boot.module.common.api.entity.OrgUsr
;
import
com.yeejoin.amos.boot.module.common.api.enums.FailureStatuEnum
;
import
com.yeejoin.amos.boot.module.common.biz.service.impl.OrgUsrServiceImpl
;
import
com.yeejoin.amos.boot.module.common.biz.service.impl.SourceFileServiceImpl
;
import
com.yeejoin.amos.boot.module.tzs.api.dto.AlertCalledQueryDto
;
import
com.yeejoin.amos.boot.module.tzs.api.enums.InformWorkFlowEnum
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentIndexDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.InformEquipmentDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.Equipment
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentIndex
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentIndexInform
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentInform
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.enums.EquipmentInformStatusEnum
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.enums.EquipmentStatusEnum
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.mapper.EquipmentInformMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IEquipmentIndexInformService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IEquipmentInformService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IInformEquipmentService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IInformProcessInfoService
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
org.apache.commons.lang3.ObjectUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.interceptor.TransactionAspectSupport
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
java.text.SimpleDateFormat
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Random
;
/**
* 设备告知单服务实现类
...
...
@@ -47,6 +64,9 @@ public class EquipmentInformServiceImpl extends BaseService<EquipmentInformDto,E
@Autowired
SourceFileServiceImpl
sourceFileService
;
@Autowired
WorkflowFeignService
workflowFeignService
;
@Autowired
EquipmentServiceImpl
equipmentServiceImpl
;
...
...
@@ -60,6 +80,17 @@ public class EquipmentInformServiceImpl extends BaseService<EquipmentInformDto,E
@Autowired
InformEquipmentServiceImpl
informEquipmentServiceImpl
;
@Value
(
"${inform.work.flow.processDefinitionKey}"
)
private
String
processDefinitionKey
;
@Autowired
IInformProcessInfoService
iInformProcessInfoService
;
@Autowired
EquipmentIndexInformServiceImpl
iEquipmentIndexInformService
;
/**
* 分页查询
*/
...
...
@@ -75,7 +106,9 @@ public class EquipmentInformServiceImpl extends BaseService<EquipmentInformDto,E
}
@Override
public
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
)
{
public
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
,
ReginParams
userInfo
)
{
model
.
setInformStatus
(
EquipmentInformStatusEnum
.
暂存
.
getCode
());
if
(
model
.
getSequenceNbr
()
==
null
)
{
// 新增
// 获取用户所在单位 保存施工单位所属信息
OrgUsr
myUnit
=
null
;
AgencyUserModel
user
=
Privilege
.
agencyUserClient
.
getme
().
getResult
();
...
...
@@ -86,21 +119,13 @@ public class EquipmentInformServiceImpl extends BaseService<EquipmentInformDto,E
if
(
myUnit
==
null
)
{
throw
new
BadRequest
(
"该用户非施工单位人员无法创建告知单"
);
}
// 判断是暂存还是提交
if
(
EquipmentInformStatusEnum
.
未接收
.
getCode
().
equals
(
model
.
getInformStatus
()))
{
// 提交判断日期
if
(
model
.
getPlanProductDate
()
==
null
)
{
throw
new
BadRequest
(
"未填写计划施工日期"
);
}
if
((
model
.
getPlanProductDate
().
getTime
()
-
System
.
currentTimeMillis
()
)
<
3
*
24
*
60
*
60
*
1000
)
{
throw
new
BadRequest
(
"计划施工日期比现在时间至少提前3天"
);
}
}
model
.
setProductInformDate
(
new
Date
());
model
.
setProductUnitId
(
myUnit
.
getSequenceNbr
());
model
.
setProductUnit
(
myUnit
.
getBizOrgName
());
model
=
this
.
createWithModel
(
model
);
}
else
{
model
=
this
.
updateWithModel
(
model
);
}
saveSourceFile
(
model
);
return
model
;
}
...
...
@@ -130,6 +155,303 @@ public class EquipmentInformServiceImpl extends BaseService<EquipmentInformDto,E
return
true
;
}
/**
* 根据informId 接收告知书
* @param sequenceNbr
* @return
*/
@Transactional
@Override
public
Boolean
acceptInform
(
Long
sequenceNbr
)
{
// 接收告知书 更新告知书状态
Boolean
flag
=
false
;
flag
=
this
.
update
(
new
LambdaUpdateWrapper
<
EquipmentInform
>().
eq
(
EquipmentInform:
:
getSequenceNbr
,
sequenceNbr
).
set
(
EquipmentInform:
:
getInformStatus
,
"9"
));
if
(
flag
)
{
// 更新设备相关参数
List
<
InformEquipmentDto
>
equipmentList
=
informEquipmentServiceImpl
.
getEquipListByInformId
(
sequenceNbr
);
equipmentList
.
stream
().
forEach
(
t
->
{
// 更新设备信息
Equipment
sourceEquip
=
equipmentServiceImpl
.
getById
(
t
.
getSourceEquipmentId
()
);
BeanUtils
.
copyProperties
(
t
,
sourceEquip
);
sourceEquip
.
setSequenceNbr
(
t
.
getSourceEquipmentId
());
equipmentServiceImpl
.
updateById
(
sourceEquip
);
// 获取设备附件信息 保存附件信息
// 原附件信息
Map
<
String
,
List
<
AttachmentDto
>>
sourceAttach
=
sourceFileService
.
getAttachments
(
t
.
getSequenceNbr
());
for
(
Map
.
Entry
<
String
,
List
<
AttachmentDto
>>
m
:
sourceAttach
.
entrySet
())
{
List
<
AttachmentDto
>
tempList
=
m
.
getValue
();
tempList
.
stream
().
forEach
(
l
->
{
l
.
setSequenceNbr
(
null
);
});
}
if
(
sourceAttach
!=
null
)
{
sourceFileService
.
saveAttachments
(
t
.
getSourceEquipmentId
()
,
sourceAttach
);
}
// 先删除备份保存的参数信息再保存新参数信息
iEquipmentIndexInformService
.
remove
(
new
LambdaQueryWrapper
<
EquipmentIndexInform
>().
eq
(
EquipmentIndexInform:
:
getEquipmentId
,
sourceEquip
.
getSequenceNbr
()));
// 备份参数
List
<
EquipmentIndex
>
indexList
=
equipmentIndexServiceImpl
.
list
(
new
LambdaQueryWrapper
<
EquipmentIndex
>().
eq
(
EquipmentIndex:
:
getEquipmentId
,
sourceEquip
.
getSequenceNbr
()));
indexList
.
stream
().
forEach
(
i
->
{
EquipmentIndexInform
tempIndex
=
new
EquipmentIndexInform
();
BeanUtils
.
copyProperties
(
i
,
tempIndex
);
tempIndex
.
setSequenceNbr
(
null
);
iEquipmentIndexInformService
.
save
(
tempIndex
);
equipmentIndexServiceImpl
.
removeById
(
i
);
});
// 保存设备参数信息
List
<
EquipmentIndexDto
>
equipmentIndex
=
t
.
getEquipmentIndex
();
if
(
equipmentIndex
!=
null
&&
equipmentIndex
.
size
()>
0
)
{
for
(
EquipmentIndexDto
index
:
equipmentIndex
)
{
index
.
setEquipmentId
(
sourceEquip
.
getSequenceNbr
());
index
.
setEquipmentName
(
sourceEquip
.
getName
());
index
.
setSequenceNbr
(
null
);
equipmentIndexServiceImpl
.
createWithModel
(
index
);
}
}
});
}
return
flag
;
}
@Transactional
@Override
public
EquipmentInformDto
updateEquipmentInform
(
EquipmentInformDto
model
,
ReginParams
userInfo
)
{
if
(
model
.
getPlanProductDate
()
==
null
)
{
throw
new
BadRequest
(
"未填写计划施工日期"
);
}
if
((
model
.
getPlanProductDate
().
getTime
()
-
System
.
currentTimeMillis
()
)
<
3
*
24
*
60
*
60
*
1000
)
{
throw
new
BadRequest
(
"计划施工日期比现在时间至少提前3天"
);
}
this
.
updateWithModel
(
model
);
saveSourceFile
(
model
);
EquipmentInform
inform
=
this
.
getById
(
model
.
getSequenceNbr
());
String
informStatus
=
inform
.
getInformStatus
();
if
(
EquipmentInformStatusEnum
.
已驳回
.
getCode
().
equals
(
informStatus
))
{
// 已驳回重新提交
try
{
this
.
startWorkflow
(
model
.
getSequenceNbr
(),
userInfo
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
else
{
String
processStatus
=
inform
.
getProcessStatus
();
if
(
StringUtils
.
isEmpty
(
processStatus
))
{
try
{
this
.
startWorkflow
(
model
.
getSequenceNbr
(),
userInfo
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
else
if
(
processStatus
.
equals
(
InformWorkFlowEnum
.
企业撤回告知书
.
getProcessStatus
())
||
processStatus
.
equals
(
InformWorkFlowEnum
.
接收方驳回告知书
.
getProcessStatus
()))
{
try
{
this
.
reSubmit
(
model
.
getSequenceNbr
(),
userInfo
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
}
return
model
;
}
@Override
public
EquipmentInformDto
queryDtoBySeq
(
Long
sequenceNbr
)
{
EquipmentInformDto
result
=
this
.
queryBySeq
(
sequenceNbr
);
// 封装附件
Map
attachment
=
sourceFileService
.
getAttachments
(
sequenceNbr
);
result
.
setAttachments
(
attachment
);
return
result
;
}
@Override
@Transactional
public
Boolean
startWorkflow
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
String
businessKey
=
buildOrderNo
();
JSONObject
body
=
new
JSONObject
();
body
.
put
(
"businessKey"
,
businessKey
);
body
.
put
(
"processDefinitionKey"
,
processDefinitionKey
);
JSONObject
jsonObject
=
workflowFeignService
.
startByVariable
(
body
);
if
(
jsonObject
==
null
)
{
TransactionAspectSupport
.
currentTransactionStatus
().
setRollbackOnly
();
}
JSONObject
instance
=
jsonObject
.
getJSONObject
(
"data"
);
if
(
instance
==
null
)
{
TransactionAspectSupport
.
currentTransactionStatus
().
setRollbackOnly
();
}
// 启动流程 后更新状态和流程ID
// 拿到流程processId
model
.
setProcessId
(
instance
.
getString
(
"id"
));
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
企业提交审批
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 其他操作
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
model
.
setInformStatus
(
EquipmentInformStatusEnum
.
未接收
.
getCode
());
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
@Transactional
public
Boolean
acceptInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
model
.
setInformStatus
(
"9"
);
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
接收方接收告知书
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
model
.
setInformStatus
(
EquipmentInformStatusEnum
.
已接收
.
getCode
());
this
.
updateWithModel
(
model
);
this
.
acceptInform
(
sequenceNbr
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
@Transactional
public
Boolean
transferInform
(
Long
sequenceNbr
,
ReginParams
userInfo
,
Long
transferUnitId
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
// company
CompanyModel
companyInfo
=
Privilege
.
companyClient
.
seleteOne
(
transferUnitId
).
getResult
();
if
(
companyInfo
!=
null
)
{
model
.
setAcceptUnit
(
companyInfo
.
getCompanyName
());
model
.
setAcceptUnitId
(
transferUnitId
);
}
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
接收方移交告知书
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
@Transactional
public
Boolean
withdrawInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
企业撤回告知书
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
@Transactional
public
Boolean
dismissInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
接收方驳回告知书
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
@Transactional
public
Boolean
cancelInform
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
企业撤销告知书
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
model
.
setIsDelete
(
true
);
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
public
Boolean
reSubmit
(
Long
sequenceNbr
,
ReginParams
userInfo
)
throws
Exception
{
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
InformWorkFlowEnum
submit
=
InformWorkFlowEnum
.
企业提交审批
;
model
.
setProcessStatus
(
submit
.
getProcessStatus
());
// 流程流转
if
(
excuteTask
(
model
,
userInfo
,
submit
))
{
this
.
updateWithModel
(
model
);
return
true
;
}
else
{
throw
new
Exception
(
"执行流程失败"
);
}
}
@Override
public
Boolean
callbackInform
(
Long
sequenceNbr
)
{
// 状态修改为驳回 还原index
EquipmentInformDto
model
=
this
.
queryBySeq
(
sequenceNbr
);
model
.
setInformStatus
(
EquipmentInformStatusEnum
.
已驳回
.
getCode
());
this
.
updateWithModel
(
model
);
// 还原index
// 更新设备相关参数
List
<
InformEquipmentDto
>
equipmentList
=
informEquipmentServiceImpl
.
getEquipListByInformId
(
sequenceNbr
);
equipmentList
.
stream
().
forEach
(
t
->
{
// 更新设备信息
Equipment
sourceEquip
=
equipmentServiceImpl
.
getById
(
t
.
getSourceEquipmentId
()
);
// 先删除现在参数
equipmentIndexServiceImpl
.
remove
(
new
LambdaQueryWrapper
<
EquipmentIndex
>().
eq
(
EquipmentIndex:
:
getEquipmentId
,
sourceEquip
.
getSequenceNbr
()));
// 还原备份参数
List
<
EquipmentIndexInform
>
indexList
=
iEquipmentIndexInformService
.
list
(
new
LambdaQueryWrapper
<
EquipmentIndexInform
>().
eq
(
EquipmentIndexInform:
:
getEquipmentId
,
sourceEquip
.
getSequenceNbr
()));
indexList
.
stream
().
forEach
(
i
->
{
EquipmentIndex
tempIndex
=
new
EquipmentIndex
();
BeanUtils
.
copyProperties
(
i
,
tempIndex
);
tempIndex
.
setSequenceNbr
(
null
);
equipmentIndexServiceImpl
.
save
(
tempIndex
);
});
});
return
true
;
}
public
boolean
excuteTask
(
EquipmentInformDto
model
,
ReginParams
userInfo
,
InformWorkFlowEnum
informWorkFlowEnum
)
throws
Exception
{
HashMap
<
String
,
Object
>
conditionMap
=
new
HashMap
<
String
,
Object
>();
conditionMap
.
put
(
"condition"
,
informWorkFlowEnum
.
getProcessStatus
());
JSONObject
teskObject
=
workflowFeignService
.
getTaskList
(
model
.
getProcessId
());
if
(
ObjectUtils
.
isNotEmpty
(
teskObject
))
{
JSONArray
taskDetailArray
=
teskObject
.
getJSONArray
(
"data"
);
for
(
Object
obj
:
taskDetailArray
)
{
JSONObject
detail
=
JSONObject
.
parseObject
(
JSONObject
.
toJSONString
(
obj
));
workflowFeignService
.
pickupAndCompleteTask
(
detail
.
getString
(
"id"
),
conditionMap
);
}
}
// 更新流程日志
iInformProcessInfoService
.
saveProcessInfo
(
model
,
userInfo
,
informWorkFlowEnum
.
getStage
());
return
true
;
}
public
static
String
buildOrderNo
()
{
SimpleDateFormat
sdf
=
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
);
String
newDate
=
sdf
.
format
(
new
Date
());
String
result
=
""
;
Random
random
=
new
Random
();
for
(
int
i
=
0
;
i
<
3
;
i
++)
{
result
+=
random
.
nextInt
(
10
);
}
return
newDate
+
result
;
}
// 保存附件信息
public
void
saveSourceFile
(
EquipmentInformDto
model
)
{
if
(
model
.
getAttachments
()
!=
null
)
{
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/InformEquipmentServiceImpl.java
View file @
b86478b9
...
...
@@ -46,18 +46,24 @@ public class InformEquipmentServiceImpl extends BaseService<InformEquipmentDto,I
@Transactional
@Override
public
InformEquipmentDto
saveInformEquipment
(
InformEquipmentDto
model
)
{
String
address
=
model
.
getAddress
();
String
latitude
=
model
.
getLatitude
();
String
longitude
=
model
.
getLongitude
();
// 首先获取设备基本信息并复制
Equipment
sourceEquip
=
equipmentServiceImpl
.
getById
(
model
.
getSourceEquipmentId
());
BeanUtils
.
copyProperties
(
sourceEquip
,
model
);
model
.
setSequenceNbr
(
null
);
model
.
setRecDate
(
new
Date
());
model
.
setRecUserId
(
null
);
model
.
setRecUserName
(
null
);
model
.
setAddress
(
address
);
model
.
setLatitude
(
latitude
);
model
.
setLongitude
(
longitude
);
model
.
setIsDelete
(
false
);
this
.
createWithModel
(
model
);
// 保存设备参数信息
List
<
EquipmentIndex
>
indexList
=
equipmentIndexServiceImpl
.
list
(
new
LambdaQueryWrapper
<
EquipmentIndex
>().
eq
(
EquipmentIndex:
:
getEquipmentId
,
model
.
getSourceEquipmentId
())
.
eq
(
EquipmentIndex:
:
getIsDelete
,
false
)
);
List
<
EquipmentIndex
>
indexList
=
equipmentIndexServiceImpl
.
list
(
new
LambdaQueryWrapper
<
EquipmentIndex
>().
eq
(
EquipmentIndex:
:
getEquipmentId
,
model
.
getSourceEquipmentId
()));
if
(
indexList
!=
null
&&
indexList
.
size
()>
0
)
{
for
(
EquipmentIndex
t
:
indexList
)
{
EquipmentIndexDto
temp
=
new
EquipmentIndexDto
();
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/InformProcessInfoServiceImpl.java
0 → 100644
View file @
b86478b9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.InformProcessInfoDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentInform
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.InformProcessInfo
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.mapper.InformProcessInfoMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IInformProcessInfoService
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.List
;
/**
* 通话记录附件服务实现类
*
* @author system_generator
* @date 2021-12-27
*/
@Service
public
class
InformProcessInfoServiceImpl
extends
BaseService
<
InformProcessInfoDto
,
InformProcessInfo
,
InformProcessInfoMapper
>
implements
IInformProcessInfoService
{
@Autowired
EquipmentInformServiceImpl
equipmentInformServiceImpl
;
/**
* 分页查询
*/
public
Page
<
InformProcessInfoDto
>
queryForInformProcessInfoPage
(
Page
<
InformProcessInfoDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
* 列表查询 示例
*/
public
List
<
InformProcessInfoDto
>
queryForInformProcessInfoList
()
{
return
this
.
queryForList
(
""
,
false
);
}
@Override
@Transactional
public
Boolean
saveProcessInfo
(
EquipmentInformDto
model
,
ReginParams
userInfo
,
String
processStage
)
throws
Exception
{
// 记录 流程操作人 所属单位 流程状态 和动作
InformProcessInfoDto
info
=
new
InformProcessInfoDto
();
AgencyUserModel
user
=
userInfo
.
getUserModel
();
List
<
CompanyModel
>
companys
=
user
.
getCompanys
();
CompanyModel
company
=
null
;
if
(
companys
!=
null
&&
companys
.
size
()
>
0
)
{
company
=
companys
.
get
(
0
);
info
.
setHandlerUnit
(
company
.
getCompanyName
());
info
.
setHandlerUnitId
(
company
.
getSequenceNbr
());
}
info
.
setHandlerId
(
Long
.
parseLong
(
user
.
getUserId
()));
info
.
setHandler
(
user
.
getRealName
());
info
.
setProcessId
(
model
.
getProcessId
());
info
.
setInformId
(
model
.
getSequenceNbr
());
info
.
setProcessInfo
(
processStage
);
info
.
setProcessStatus
(
model
.
getProcessStatus
());
this
.
createWithModel
(
info
);
return
true
;
}
}
\ No newline at end of file
amos-boot-system-tzs/src/main/resources/application.properties
View file @
b86478b9
...
...
@@ -60,3 +60,7 @@ failure.work.flow.processDefinitionKey=malfunction_repair
video.fegin.name
=
video
latentDanger.feign.name
=
AMOS-LATENT-DANGER
Knowledgebase.fegin.name
=
AMOS-API-KNOWLEDGEBASE
## 设备告知流程v1
inform.work.flow.processDefinitionKey
=
equipment_inform_process_v1
\ No newline at end of file
amos-boot-system-tzs/src/main/resources/db/changelog/tzs-1.0.0.0.xml
View file @
b86478b9
...
...
@@ -780,5 +780,30 @@
</sql>
</changeSet>
<changeSet
author=
"kongfm"
id=
"2021-12-29-01"
>
<preConditions
onFail=
"MARK_RAN"
>
<not>
<tableExists
tableName=
"tcb_equipment_index_inform"
/>
</not>
</preConditions>
<comment>
add tcb_equipment_index_inform table
</comment>
<sql>
CREATE TABLE `tcb_equipment_index_inform` (
`sequence_nbr` bigint(50) NOT NULL COMMENT '主键',
`equipment_id` bigint(50) NOT NULL COMMENT '设备id',
`equipment_name` varchar(255) DEFAULT NULL COMMENT '设备名称',
`value` varchar(255) DEFAULT NULL COMMENT '指标值',
`def_index_id` bigint(50) DEFAULT NULL COMMENT '装备定义指标id',
`def_index_name` varchar(255) DEFAULT NULL COMMENT '装备定义指标名称',
`def_index_key` varchar(255) DEFAULT NULL COMMENT '装备定义指标key',
`rec_user_id` bigint(50) DEFAULT NULL COMMENT '更新人id',
`rec_user_name` varchar(255) DEFAULT NULL COMMENT '更新人名称',
`rec_date` datetime DEFAULT NULL COMMENT '更新时间',
`is_delete` bit(1) DEFAULT NULL COMMENT '是否删除(1删除,0未删除)',
PRIMARY KEY (`sequence_nbr`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='设备指标';
</sql>
</changeSet>
</databaseChangeLog>
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