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
cbe71cc5
Commit
cbe71cc5
authored
Jan 23, 2024
by
韩桐桐
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(改造告知):列表返回设备监管码
parent
c700060d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
51 deletions
+53
-51
JgReformNoticeMapper.xml
...jg-api/src/main/resources/mapper/JgReformNoticeMapper.xml
+10
-8
JgReformNoticeController.java
...ot/module/jg/biz/controller/JgReformNoticeController.java
+43
-43
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgReformNoticeMapper.xml
View file @
cbe71cc5
...
...
@@ -31,9 +31,13 @@
isn.equ_list_code,
isn.equ_category,
isn.create_user_id,
isn.next_execute_user_ids
isn.next_execute_user_ids,
oi.SUPERVISORY_CODE AS supervisoryCode
FROM
tzs_jg_reform_notice isn
LEFT JOIN tzs_jg_reform_notice_eq re ON re.equip_transfer_id = isn.sequence_nbr
LEFT JOIN idx_biz_jg_register_info ri ON ri.record = re.equ_id
LEFT JOIN idx_biz_jg_other_info oi ON ri.RECORD = oi.RECORD
<where>
isn.is_delete = false
<if
test=
"param != null "
>
...
...
@@ -69,8 +73,7 @@
</select>
<select
id=
"queryEquipInformation"
resultType=
"java.util.Map"
>
select
isn.sequence_nbr AS sequenceNbr,
select isn.sequence_nbr AS sequenceNbr,
isn.install_unit_name AS installUnitName,
isn.apply_no AS applyNo,
isn.province_name AS provinceName,
...
...
@@ -127,8 +130,7 @@
tec1.name AS equList,
tec.name AS equDefine,
oi.SUPERVISORY_CODE AS supervisoryCode
FROM
tzs_jg_reform_notice isn
FROM tzs_jg_reform_notice isn
LEFT JOIN tzs_jg_reform_notice_eq re ON re.equip_transfer_id = isn.sequence_nbr
LEFT JOIN idx_biz_jg_register_info ri ON ri.record = re.equ_id
LEFT JOIN idx_biz_jg_design_info di ON di.record = re.equ_id
...
...
@@ -140,13 +142,13 @@
LEFT JOIN tz_equipment_category tec1 ON ri."EQU_LIST"::text = tec1.code::text
LEFT JOIN tz_equipment_category tec2 ON ri."EQU_DEFINE"::text = tec2.code::text
LEFT JOIN idx_biz_jg_other_info oi ON ri.RECORD = oi.RECORD
WHERE
isn.sequence_nbr = #{sequenceNbr}
WHERE isn.sequence_nbr = #{sequenceNbr}
LIMIT 1
</select>
<update
id=
"updatePromoter"
>
UPDATE tzs_jg_reform_notice set promoter = null
UPDATE tzs_jg_reform_notice
set promoter = null
where sequence_nbr = #{id}
</update>
</mapper>
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgReformNoticeController.java
View file @
cbe71cc5
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.common.biz.utils.CommonResponseUtil
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgReformNoticeDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgReformNotice
;
import
com.yeejoin.amos.boot.module.jg.api.service.IJgInstallationNoticeService
;
import
io.swagger.annotations.ApiParam
;
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.Map
;
import
java.util.Objects
;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.JgReformNoticeServiceImpl
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.util.Map
;
import
java.util.Objects
;
/**
* 改造告知
...
...
@@ -29,8 +28,8 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
* @date 2023-12-19
*/
@RestController
@Api
(
tags
=
"改造告知Api"
)
@RequestMapping
(
value
=
"/jg-reform-notice"
)
@Api
(
tags
=
"改造告知Api"
)
@RequestMapping
(
value
=
"/jg-reform-notice"
)
public
class
JgReformNoticeController
extends
BaseController
{
@Autowired
...
...
@@ -44,9 +43,9 @@ public class JgReformNoticeController extends BaseController {
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增改造告知"
,
notes
=
"新增改造告知"
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增改造告知"
,
notes
=
"新增改造告知"
)
public
ResponseModel
<
Object
>
save
(
@RequestParam
String
submitType
,
@RequestBody
Map
<
String
,
Object
>
model
)
{
ReginParams
reginParams
=
getSelectedOrgInfo
();
return
ResponseHelper
.
buildResponse
(
jgReformNoticeService
.
saveNotice
(
submitType
,
model
,
reginParams
));
...
...
@@ -55,15 +54,16 @@ public class JgReformNoticeController extends BaseController {
/**
* 更新
*
* @param submitType 更新或提交
* @param installationInfo 改造告知信息
* @param op 参数
* @return JgReformNoticeDto
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/update"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新改造告知"
,
notes
=
"根据sequenceNbr更新改造告知"
)
public
ResponseModel
<
JgReformNoticeDto
>
updateBySequenceNbrJgReformNotice
(
@RequestParam
String
submitType
,
@RequestBody
JgReformNoticeDto
installationInfo
,
@RequestParam
(
value
=
"op"
,
required
=
false
)
String
op
)
{
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/update"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新改造告知"
,
notes
=
"根据sequenceNbr更新改造告知"
)
public
ResponseModel
<
JgReformNoticeDto
>
updateBySequenceNbrJgReformNotice
(
@RequestParam
String
submitType
,
@RequestBody
JgReformNoticeDto
installationInfo
,
@RequestParam
(
value
=
"op"
,
required
=
false
)
String
op
)
{
if
(
Objects
.
isNull
(
installationInfo
))
{
throw
new
IllegalArgumentException
(
"参数installationInfo不能为空"
);
}
...
...
@@ -76,10 +76,10 @@ public class JgReformNoticeController extends BaseController {
*
* @param sequenceNbr 主键
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/delete"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除改造告知"
,
notes
=
"根据sequenceNbr删除改造告知"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
@RequestParam
(
value
=
"sequenceNbr"
)
Long
[]
sequenceNbr
)
{
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/delete"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除改造告知"
,
notes
=
"根据sequenceNbr删除改造告知"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
@RequestParam
(
value
=
"sequenceNbr"
)
Long
[]
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
jgReformNoticeService
.
removeById
(
sequenceNbr
));
}
...
...
@@ -88,10 +88,10 @@ public class JgReformNoticeController extends BaseController {
*
* @param sequenceNbrs 主键
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/batchDelete"
)
@ApiOperation
(
value
=
"根据sequenceNbr删除维保合同备案"
,
notes
=
"根据sequenceNbr删除维保合同备案"
)
public
ResponseModel
<
Boolean
>
deleteForBatch
(
@RequestParam
(
"sequenceNbrs"
)
Long
[]
sequenceNbrs
)
{
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/batchDelete"
)
@ApiOperation
(
value
=
"根据sequenceNbr删除维保合同备案"
,
notes
=
"根据sequenceNbr删除维保合同备案"
)
public
ResponseModel
<
Boolean
>
deleteForBatch
(
@RequestParam
(
"sequenceNbrs"
)
Long
[]
sequenceNbrs
)
{
try
{
return
ResponseHelper
.
buildResponse
(
jgReformNoticeService
.
deleteForBatch
(
sequenceNbrs
));
}
catch
(
Exception
e
)
{
...
...
@@ -104,10 +104,10 @@ public class JgReformNoticeController extends BaseController {
*
* @param sequenceNbr 主键
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/details"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个改造告知"
,
notes
=
"根据sequenceNbr查询单个改造告知"
)
public
ResponseModel
<
Map
<
String
,
Object
>>
selectOne
(
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/details"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个改造告知"
,
notes
=
"根据sequenceNbr查询单个改造告知"
)
public
ResponseModel
<
Map
<
String
,
Object
>>
selectOne
(
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
jgReformNoticeService
.
queryBySequenceNbr
(
sequenceNbr
));
}
...
...
@@ -119,13 +119,13 @@ public class JgReformNoticeController extends BaseController {
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GE
T"
,
value
=
"改造告知分页查询"
,
notes
=
"改造告知分页查询"
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"POS
T"
,
value
=
"改造告知分页查询"
,
notes
=
"改造告知分页查询"
)
public
ResponseModel
<
Page
<
JgReformNoticeDto
>>
queryForPage
(
@ApiParam
(
value
=
"当前页码"
,
required
=
true
)
@RequestParam
(
value
=
"current"
,
defaultValue
=
"1"
)
int
current
,
@ApiParam
(
value
=
"每页大小"
,
required
=
true
)
@RequestParam
(
value
=
"size"
,
defaultValue
=
"20"
)
int
size
,
@RequestBody
(
required
=
false
)
JgReformNoticeDto
model
@ApiParam
(
value
=
"当前页码"
,
required
=
true
)
@RequestParam
(
value
=
"current"
,
defaultValue
=
"1"
)
int
current
,
@ApiParam
(
value
=
"每页大小"
,
required
=
true
)
@RequestParam
(
value
=
"size"
,
defaultValue
=
"20"
)
int
size
,
@RequestBody
(
required
=
false
)
JgReformNoticeDto
model
)
{
Page
<
JgReformNotice
>
page
=
new
Page
<>(
current
,
size
);
ReginParams
reginParams
=
getSelectedOrgInfo
();
...
...
@@ -136,10 +136,10 @@ public class JgReformNoticeController extends BaseController {
/**
* 生成告知单
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"改造告知列表全部数据查询"
,
notes
=
"改造告知列表全部数据查询"
)
@GetMapping
(
value
=
"/generate-report"
)
public
ResponseModel
<
String
>
generateReport
(
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"改造告知列表全部数据查询"
,
notes
=
"改造告知列表全部数据查询"
)
@GetMapping
(
value
=
"/generate-report"
)
public
ResponseModel
<
String
>
generateReport
(
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
jgReformNoticeService
.
generateInstallationNoticeReport
(
sequenceNbr
));
}
}
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