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
fbac7206
Commit
fbac7206
authored
Apr 29, 2024
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.车用气瓶使用登记增加作废功能
parent
27ff8cb2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
83 additions
and
46 deletions
+83
-46
JgVehicleInformationDto.java
.../amos/boot/module/jg/api/dto/JgVehicleInformationDto.java
+14
-4
JgVehicleInformation.java
.../amos/boot/module/jg/api/entity/JgVehicleInformation.java
+19
-0
JgVehicleInformationVo.java
...in/amos/boot/module/jg/api/vo/JgVehicleInformationVo.java
+1
-1
JgVehicleInformationController.java
...ule/jg/biz/controller/JgVehicleInformationController.java
+9
-0
ICommonService.java
...ejoin/amos/boot/module/jg/biz/service/ICommonService.java
+2
-1
CommonServiceImpl.java
...os/boot/module/jg/biz/service/impl/CommonServiceImpl.java
+3
-2
JgInstallationNoticeServiceImpl.java
.../jg/biz/service/impl/JgInstallationNoticeServiceImpl.java
+1
-1
JgMaintenanceContractServiceImpl.java
...jg/biz/service/impl/JgMaintenanceContractServiceImpl.java
+2
-2
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+32
-35
JgVehicleInformationServiceImpl.java
.../jg/biz/service/impl/JgVehicleInformationServiceImpl.java
+0
-0
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/dto/JgVehicleInformationDto.java
View file @
fbac7206
...
...
@@ -5,21 +5,20 @@ import io.swagger.annotations.ApiModel;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.util.Date
;
import
java.util.List
;
/**
*
*
* @author system_generator
* @date 2024-03-18
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"JgVehicleInformationDto"
,
description
=
""
)
@ApiModel
(
value
=
"JgVehicleInformationDto"
,
description
=
""
)
public
class
JgVehicleInformationDto
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"设备监管码"
)
...
...
@@ -228,4 +227,15 @@ public class JgVehicleInformationDto extends BaseDto {
@ApiModelProperty
(
value
=
"电话"
)
private
String
phone
;
@ApiModelProperty
(
value
=
"作废日期"
)
private
Date
cancelDate
;
@ApiModelProperty
(
value
=
"作废人员id"
)
private
String
cancelUserId
;
@ApiModelProperty
(
value
=
"作废原因"
)
private
String
cancelReason
;
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/entity/JgVehicleInformation.java
View file @
fbac7206
...
...
@@ -408,4 +408,23 @@ public class JgVehicleInformation extends BaseEntity {
@TableField
(
value
=
"phone"
)
private
String
phone
;
/**
* 作废日期
*/
@TableField
(
"cancel_date"
)
private
Date
cancelDate
;
/**
* 作废人员id
*/
@TableField
(
"cancel_user_id"
)
private
String
cancelUserId
;
/**
* 作废原因
*/
@TableField
(
"cancel_reason"
)
private
String
cancelReason
;
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/vo/JgVehicleInformationVo.java
View file @
fbac7206
...
...
@@ -199,7 +199,7 @@ public class JgVehicleInformationVo implements Serializable {
private
String
currentUserId
;
private
List
<
Map
<
String
,
Object
>
>
equipmentLists
;
private
List
<
?
extends
Map
>
equipmentLists
;
@ApiModelProperty
(
value
=
"主键ID"
)
protected
Long
sequenceNbr
;
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgVehicleInformationController.java
View file @
fbac7206
...
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.jg.biz.controller;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgVehicleInformation
;
import
com.yeejoin.amos.boot.module.jg.api.vo.JgVehicleInformationVo
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
...
...
@@ -182,4 +183,12 @@ public class JgVehicleInformationController extends BaseController {
@RequestParam
(
value
=
"printType"
,
defaultValue
=
"0"
)
String
printType
)
{
jgVehicleInformationServiceImpl
.
exportVehicleUseRegistrationCertificate
(
sequenceNbr
,
response
,
printType
);
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"车用气瓶使用登记单条作废"
,
notes
=
"车用气瓶使用登记单条作废"
)
@PutMapping
(
value
=
"/cancel/application"
)
public
ResponseModel
<
JgVehicleInformation
>
cancelApplication
(
@RequestBody
JgVehicleInformationDto
vehicleInformationDto
)
{
JgVehicleInformation
result
=
jgVehicleInformationServiceImpl
.
cancelApplication
(
vehicleInformationDto
.
getSequenceNbr
(),
vehicleInformationDto
.
getCancelReason
());
return
ResponseHelper
.
buildResponse
(
result
);
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/ICommonService.java
View file @
fbac7206
...
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.jg.biz.service;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.boot.biz.common.bo.CompanyBo
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
...
...
@@ -136,7 +137,7 @@ public interface ICommonService {
* @param currentDocumentId 业务id
* @return Object
*/
Object
queryHistoryDataObj
(
Long
currentDocumentId
);
JSONArray
queryHistoryDataObj
(
Long
currentDocumentId
);
/**
* 统计指定设备流程中的引用次数(12个流程中,非待提交、非已撤回、非已驳回)
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/CommonServiceImpl.java
View file @
fbac7206
...
...
@@ -6,6 +6,7 @@ import cn.hutool.core.date.DatePattern;
import
cn.hutool.core.date.DateUtil
;
import
cn.hutool.core.io.IoUtil
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.aspose.words.SaveFormat
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
...
...
@@ -1644,11 +1645,11 @@ public class CommonServiceImpl implements ICommonService {
}
@Override
public
Object
queryHistoryDataObj
(
Long
currentDocumentId
)
{
public
JSONArray
queryHistoryDataObj
(
Long
currentDocumentId
)
{
LambdaQueryWrapper
<
JgRegistrationHistory
>
lambda
=
new
QueryWrapper
<
JgRegistrationHistory
>().
lambda
();
lambda
.
eq
(
JgRegistrationHistory:
:
getCurrentDocumentId
,
currentDocumentId
);
JgRegistrationHistory
jgRegistrationHistory
=
jgRegistrationHistoryService
.
getBaseMapper
().
selectOne
(
lambda
);
return
jgRegistrationHistory
!=
null
?
JSON
.
parse
(
jgRegistrationHistory
.
getChangeData
())
:
null
;
return
jgRegistrationHistory
!=
null
?
JSON
.
parse
Array
(
jgRegistrationHistory
.
getChangeData
())
:
new
JSONArray
()
;
}
@Override
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgInstallationNoticeServiceImpl.java
View file @
fbac7206
...
...
@@ -1264,7 +1264,7 @@ public class JgInstallationNoticeServiceImpl extends BaseService<JgInstallationN
installationNotice
.
setNoticeStatus
(
String
.
valueOf
(
FlowStatusEnum
.
TO_BE_DISCARD
.
getCode
()));
installationNotice
.
setCancelReason
(
cancelReason
);
installationNotice
.
setCancelDate
(
new
Date
());
installationNotice
.
setC
reate
UserId
(
RequestContext
.
getExeUserId
());
installationNotice
.
setC
ancel
UserId
(
RequestContext
.
getExeUserId
());
installationNotice
.
setNextExecuteUserIds
(
null
);
installationNotice
.
setPromoter
(
null
);
this
.
updateById
(
installationNotice
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgMaintenanceContractServiceImpl.java
View file @
fbac7206
...
...
@@ -145,9 +145,9 @@ public class JgMaintenanceContractServiceImpl extends BaseService<JgMaintenanceC
}
}
else
{
// 完成的显示历史表的数据
JSONArray
objects
=
(
JSONArray
)
commonService
.
queryHistoryDataObj
(
dto
.
getSequenceNbr
());
JSONArray
objects
=
commonService
.
queryHistoryDataObj
(
dto
.
getSequenceNbr
());
// 兼容老数据
if
(
objects
==
null
)
{
if
(
objects
.
isEmpty
()
)
{
List
<
Map
<
String
,
Object
>>
list
=
maintenanceContractMapper
.
selectEquipList
(
sequenceNbr
);
if
(!
ObjectUtils
.
isEmpty
(
list
))
{
vo
.
setEquipmentLists
(
list
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
View file @
fbac7206
...
...
@@ -974,9 +974,6 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
registerInfo
.
setEquCode
(
equCode
);
mapData
.
put
(
"equCode"
,
equCode
);
lambda
.
set
(
true
,
IdxBizJgRegisterInfo:
:
getEquCode
,
equCode
);
// 更新新生成的历史数据的设备代码
jgRegistrationHistory
.
setChangeData
(
JSON
.
toJSONString
(
mapData
));
jgRegistrationHistoryService
.
updateById
(
jgRegistrationHistory
);
}
}
...
...
@@ -1370,37 +1367,6 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
}
/**
* 填充设备最新的数据至历史json
*
* @param jsonObject 历史json
* @param jgUseRegistration 使用信息
* @param record 设备唯一标识
*/
private
void
fillHistoryDataWithNewEquip
(
JSONObject
jsonObject
,
JgUseRegistration
jgUseRegistration
,
String
record
)
{
// 非已完成、非作废时显示设备最新信息。前置需求:一个设备只能同时发起一个流程
if
(!(
jgUseRegistration
.
getStatus
().
equals
(
FlowStatusEnum
.
TO_BE_FINISHED
.
getName
())
||
jgUseRegistration
.
getStatus
().
equals
(
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
())))
{
// 基本信息 + 制造信息
Map
<
String
,
Object
>
detail
=
this
.
baseMapper
.
getDetail
(
record
);
// 设计信息
Map
<
String
,
Object
>
desDetail
=
this
.
baseMapper
.
getDesDetail
(
record
);
if
(!
ObjectUtils
.
isEmpty
(
desDetail
))
{
detail
.
putAll
(
desDetail
);
}
// 安装信息
Map
<
String
,
Object
>
installDetail
=
this
.
baseMapper
.
getiInstallDetail
(
record
);
// 维保信息
Map
<
String
,
Object
>
maintenanceDetail
=
this
.
baseMapper
.
getMaintenanceDetail
(
record
);
if
(!
ObjectUtils
.
isEmpty
(
maintenanceDetail
))
{
detail
.
putAll
(
maintenanceDetail
);
}
if
(!
ObjectUtils
.
isEmpty
(
installDetail
))
{
detail
.
putAll
(
installDetail
);
}
jsonObject
.
putAll
(
detail
);
}
}
/**
* 参数为监管码
*
* @param supervisoryCode
...
...
@@ -1539,6 +1505,37 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
}
}
/**
* 填充设备最新的数据至历史json
*
* @param jsonObject 历史json
* @param jgUseRegistration 使用信息
* @param record 设备唯一标识
*/
private
void
fillHistoryDataWithNewEquip
(
JSONObject
jsonObject
,
JgUseRegistration
jgUseRegistration
,
String
record
)
{
// 非已完成、非作废时显示设备最新信息。前置需求:一个设备只能同时发起一个流程
if
(!(
jgUseRegistration
.
getStatus
().
equals
(
FlowStatusEnum
.
TO_BE_FINISHED
.
getName
())
||
jgUseRegistration
.
getStatus
().
equals
(
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
())))
{
// 基本信息 + 制造信息
Map
<
String
,
Object
>
detail
=
this
.
baseMapper
.
getDetail
(
record
);
// 设计信息
Map
<
String
,
Object
>
desDetail
=
this
.
baseMapper
.
getDesDetail
(
record
);
if
(!
ObjectUtils
.
isEmpty
(
desDetail
))
{
detail
.
putAll
(
desDetail
);
}
// 安装信息
Map
<
String
,
Object
>
installDetail
=
this
.
baseMapper
.
getiInstallDetail
(
record
);
// 维保信息
Map
<
String
,
Object
>
maintenanceDetail
=
this
.
baseMapper
.
getMaintenanceDetail
(
record
);
if
(!
ObjectUtils
.
isEmpty
(
maintenanceDetail
))
{
detail
.
putAll
(
maintenanceDetail
);
}
if
(!
ObjectUtils
.
isEmpty
(
installDetail
))
{
detail
.
putAll
(
installDetail
);
}
jsonObject
.
putAll
(
detail
);
}
}
private
UseFlagParamDto
buildUseFlagParamDto
(
JgUseRegistration
useRegistration
,
IdxBizJgRegisterInfo
registerInfo
,
IdxBizJgFactoryInfo
factoryInfo
,
Map
<
String
,
Object
>
exportParamsMap
)
{
UseFlagParamDto
useFlagParamDto
=
new
UseFlagParamDto
();
useFlagParamDto
.
setReceiveCompanyCode
(
useRegistration
.
getReceiveCompanyCode
());
...
...
@@ -1626,7 +1623,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
jgUseRegistration
.
setStatus
(
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
());
jgUseRegistration
.
setCancelReason
(
cancelReason
);
jgUseRegistration
.
setCancelDate
(
new
Date
());
jgUseRegistration
.
setC
reate
UserId
(
RequestContext
.
getExeUserId
());
jgUseRegistration
.
setC
ancel
UserId
(
RequestContext
.
getExeUserId
());
jgUseRegistration
.
setNextExecuteUserIds
(
""
);
jgUseRegistration
.
setPromoter
(
""
);
this
.
updateById
(
jgUseRegistration
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgVehicleInformationServiceImpl.java
View file @
fbac7206
This diff is collapsed.
Click to expand it.
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