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
ada6d160
Commit
ada6d160
authored
Aug 13, 2025
by
tianyiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 补证登记/车用气瓶变更登记/设备移交列表查询增加监管单位查看逻辑
parent
8c934585
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
225 additions
and
92 deletions
+225
-92
JgChangeVehicleRegistrationUnitDto.java
...module/jg/api/dto/JgChangeVehicleRegistrationUnitDto.java
+4
-0
JgCertificateReplenishMapper.java
...ot/module/jg/api/mapper/JgCertificateReplenishMapper.java
+9
-1
JgChangeVehicleRegistrationUnitMapper.java
.../jg/api/mapper/JgChangeVehicleRegistrationUnitMapper.java
+7
-4
JgEquipTransferMapper.java
...amos/boot/module/jg/api/mapper/JgEquipTransferMapper.java
+3
-1
IJgEquipTransferService.java
...s/boot/module/jg/api/service/IJgEquipTransferService.java
+1
-1
JgCertificateReplenishMapper.xml
...rc/main/resources/mapper/JgCertificateReplenishMapper.xml
+78
-0
JgChangeRegistrationTransferMapper.xml
...n/resources/mapper/JgChangeRegistrationTransferMapper.xml
+2
-1
JgChangeRegistrationUnitMapper.xml
.../main/resources/mapper/JgChangeRegistrationUnitMapper.xml
+3
-1
JgChangeVehicleRegistrationUnitMapper.xml
...esources/mapper/JgChangeVehicleRegistrationUnitMapper.xml
+31
-8
JgEquipTransferMapper.xml
...g-api/src/main/resources/mapper/JgEquipTransferMapper.xml
+26
-13
JgMaintainNoticeMapper.xml
...-api/src/main/resources/mapper/JgMaintainNoticeMapper.xml
+4
-3
JgScrapCancelMapper.xml
...-jg-api/src/main/resources/mapper/JgScrapCancelMapper.xml
+3
-2
JgCertificateReplenishController.java
...e/jg/biz/controller/JgCertificateReplenishController.java
+7
-3
JgChangeVehicleRegistrationUnitController.java
...controller/JgChangeVehicleRegistrationUnitController.java
+9
-7
JgEquipTransferController.java
...t/module/jg/biz/controller/JgEquipTransferController.java
+4
-2
JgCertificateReplenishServiceImpl.java
...g/biz/service/impl/JgCertificateReplenishServiceImpl.java
+15
-28
JgChangeVehicleRegistrationUnitServiceImpl.java
...vice/impl/JgChangeVehicleRegistrationUnitServiceImpl.java
+10
-12
JgEquipTransferServiceImpl.java
...odule/jg/biz/service/impl/JgEquipTransferServiceImpl.java
+9
-5
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/JgChangeVehicleRegistrationUnitDto.java
View file @
ada6d160
...
@@ -34,6 +34,8 @@ public class JgChangeVehicleRegistrationUnitDto extends BaseDto {
...
@@ -34,6 +34,8 @@ public class JgChangeVehicleRegistrationUnitDto extends BaseDto {
private
String
applyNo
;
private
String
applyNo
;
@ApiModelProperty
(
value
=
"申请日期"
)
@ApiModelProperty
(
value
=
"申请日期"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
applyDate
;
private
Date
applyDate
;
@ApiModelProperty
(
value
=
"登记机构"
)
@ApiModelProperty
(
value
=
"登记机构"
)
...
@@ -46,6 +48,8 @@ public class JgChangeVehicleRegistrationUnitDto extends BaseDto {
...
@@ -46,6 +48,8 @@ public class JgChangeVehicleRegistrationUnitDto extends BaseDto {
private
String
receiveCompanyCode
;
private
String
receiveCompanyCode
;
@ApiModelProperty
(
value
=
"终审通过时间"
)
@ApiModelProperty
(
value
=
"终审通过时间"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
auditPassDate
;
private
Date
auditPassDate
;
@ApiModelProperty
(
value
=
"备注"
)
@ApiModelProperty
(
value
=
"备注"
)
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgCertificateReplenishMapper.java
View file @
ada6d160
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateReplenish
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgCertificateReplenishDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateReplenish
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
/**
/**
* 使用登记表补证 Mapper 接口
* 使用登记表补证 Mapper 接口
...
@@ -9,6 +14,9 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
...
@@ -9,6 +14,9 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
* @author system_generator
* @author system_generator
* @date 2025-03-19
* @date 2025-03-19
*/
*/
@Mapper
public
interface
JgCertificateReplenishMapper
extends
BaseMapper
<
JgCertificateReplenish
>
{
public
interface
JgCertificateReplenishMapper
extends
BaseMapper
<
JgCertificateReplenish
>
{
Page
<
JgCertificateReplenish
>
queryForPage
(
Page
<
JgCertificateReplenish
>
page
,
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"dto"
)
JgCertificateReplenishDto
dto
,
@Param
(
"type"
)
String
type
,
@Param
(
"companyCode"
)
String
companyCode
,
@Param
(
"orgCode"
)
String
orgCode
);
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgChangeVehicleRegistrationUnitMapper.java
View file @
ada6d160
...
@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...
@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.yeejoin.amos.boot.module.jg.api.dto.CompanyEquipCountDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.CompanyEquipCountDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgChangeVehicleRegistrationUnitDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgChangeVehicleRegistrationUnitDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgChangeVehicleRegistrationUnit
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgChangeVehicleRegistrationUnit
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
com.yeejoin.amos.boot.module.jg.api.vo.tableDataExportVo.ChangeVehicleRegistrationUnitVo
;
import
com.yeejoin.amos.boot.module.jg.api.vo.tableDataExportVo.ChangeVehicleRegistrationUnitVo
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
...
@@ -21,12 +22,14 @@ public interface JgChangeVehicleRegistrationUnitMapper extends BaseMapper<JgChan
...
@@ -21,12 +22,14 @@ public interface JgChangeVehicleRegistrationUnitMapper extends BaseMapper<JgChan
List
<
Map
<
String
,
Object
>>
getEquList
(
@Param
(
"records"
)
List
<
String
>
records
);
List
<
Map
<
String
,
Object
>>
getEquList
(
@Param
(
"records"
)
List
<
String
>
records
);
Page
<
Map
<
String
,
Object
>>
getPage
(
@Param
(
"page"
)
Page
<
JgChangeVehicleRegistrationUnit
>
page
,
Page
<
Map
<
String
,
Object
>>
getPage
(
@Param
(
"page"
)
Page
<
JgChangeVehicleRegistrationUnit
>
page
,
@Param
(
"dto"
)
JgChangeVehicleRegistrationUnitDto
dto
,
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"dto"
)
JgChangeVehicleRegistrationUnitDto
dto
,
@Param
(
"type"
)
String
type
,
@Param
(
"type"
)
String
type
,
@Param
(
"orgCode"
)
String
org
Code
,
@Param
(
"companyCode"
)
String
company
Code
,
@Param
(
"currentUserId"
)
String
currentUserId
,
@Param
(
"currentUserId"
)
String
currentUserId
,
@Param
(
"roleIds"
)
List
<
String
>
roleIds
);
@Param
(
"roleIds"
)
List
<
String
>
roleIds
,
@Param
(
"orgCode"
)
String
orgCode
);
List
<
ChangeVehicleRegistrationUnitVo
>
queryChangeVehicleRegistrationUnitInIds
(
@Param
(
"ids"
)
List
<
String
>
ids
);
List
<
ChangeVehicleRegistrationUnitVo
>
queryChangeVehicleRegistrationUnitInIds
(
@Param
(
"ids"
)
List
<
String
>
ids
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgEquipTransferMapper.java
View file @
ada6d160
...
@@ -22,7 +22,9 @@ public interface JgEquipTransferMapper extends CustomBaseMapper<JgEquipTransfer>
...
@@ -22,7 +22,9 @@ public interface JgEquipTransferMapper extends CustomBaseMapper<JgEquipTransfer>
Page
<
JgEquipTransferDto
>
queryForPage
(
Page
<
JgEquipTransferDto
>
page
,
Page
<
JgEquipTransferDto
>
queryForPage
(
Page
<
JgEquipTransferDto
>
page
,
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"param"
)
JgEquipTransferDto
model
,
@Param
(
"param"
)
JgEquipTransferDto
model
,
@Param
(
"currentUserId"
)
String
currentUserId
);
@Param
(
"currentUserId"
)
String
currentUserId
,
@Param
(
"type"
)
String
type
,
@Param
(
"orgCode"
)
String
orgCode
);
List
<
EquipTransferVo
>
queryEquipTransferInIds
(
@Param
(
"ids"
)
List
<
String
>
ids
);
List
<
EquipTransferVo
>
queryEquipTransferInIds
(
@Param
(
"ids"
)
List
<
String
>
ids
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/service/IJgEquipTransferService.java
View file @
ada6d160
...
@@ -24,7 +24,7 @@ public interface IJgEquipTransferService extends IService<JgEquipTransfer> {
...
@@ -24,7 +24,7 @@ public interface IJgEquipTransferService extends IService<JgEquipTransfer> {
* @param dto 查询参数
* @param dto 查询参数
* @return 设备移交分页列表
* @return 设备移交分页列表
*/
*/
Page
<
JgEquipTransferDto
>
queryForJgEquipTransferPage
(
Page
<
JgEquipTransferDto
>
page
,
String
sort
,
JgEquipTransferDto
dto
,
ReginParams
reginParams
);
Page
<
JgEquipTransferDto
>
queryForJgEquipTransferPage
(
Page
<
JgEquipTransferDto
>
page
,
String
sort
,
JgEquipTransferDto
dto
,
ReginParams
reginParams
,
String
client
);
/**
/**
* 根据sequenceNbr查询
* 根据sequenceNbr查询
*
*
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgCertificateReplenishMapper.xml
View file @
ada6d160
...
@@ -2,4 +2,82 @@
...
@@ -2,4 +2,82 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!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.jg.api.mapper.JgCertificateReplenishMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.jg.api.mapper.JgCertificateReplenishMapper"
>
<sql
id=
"page_list"
>
<![CDATA[/*+ set(query_dop 16)*/ ]]>
WITH equip_data as (
SELECT
certificate_replenish_id,
equ_id,
group_concat(distinct si."ORG_BRANCH_CODE") as orgBranchCodes
FROM
tzs_jg_certificate_replenish_eq tjcreq
LEFT JOIN idx_biz_jg_supervision_info si ON si.record = tjcreq.equ_id
GROUP BY certificate_replenish_id
)
select
DISTINCT tjcr.sequence_nbr AS sequenceNbr,
tjcr.*,
ed.orgBranchCodes
</sql>
<select
id=
"queryForPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateReplenish"
>
<include
refid=
"page_list"
/>
FROM tzs_jg_certificate_replenish tjcr
LEFT JOIN equip_data ed on ed.certificate_replenish_id = tjcr.sequence_nbr
<where>
tjcr.is_delete = 0
<if
test=
"dto != null"
>
<if
test=
"dto.applyNo != null and dto.applyNo != ''"
>
AND tjcr.apply_no LIKE CONCAT('%', #{dto.applyNo}, '%')
</if>
<if
test=
"dto.useRegistrationCode != null and dto.useRegistrationCode != ''"
>
AND tjcr.use_registration_code LIKE CONCAT('%', #{dto.useRegistrationCode}, '%')
</if>
<if
test=
"dto.useRegistrationCode != null and dto.useRegistrationCode != ''"
>
AND tjcr.use_registration_code LIKE CONCAT('%', #{dto.useRegistrationCode}, '%')
</if>
<if
test=
"dto.useUnitCode != null and dto.useUnitCode != ''"
>
AND tjcr.use_unit_code LIKE CONCAT('%', #{dto.useUnitCode}, '%')
</if>
<if
test=
"dto.useUnitName != null and dto.useUnitName != ''"
>
AND tjcr.use_unit_name LIKE CONCAT('%', #{dto.useUnitName}, '%')
</if>
<if
test=
"dto.applyStatus != null and dto.applyStatus != ''"
>
AND tjcr.apply_status = #{dto.applyStatus}
</if>
<if
test=
"dto.equListCode != null and dto.equListCode != ''"
>
AND tjcr.equ_list_code LIKE CONCAT('%', #{dto.equListCode}, '%')
</if>
<if
test=
"dto.applicationReason != null and dto.applicationReason != ''"
>
AND tjcr.application_reason = #{dto.applicationReason}
</if>
<if
test=
"dto.lossDamageTime != null and dto.lossDamageTime != ''"
>
AND tjcr.loss_damage_time = #{dto.lossDamageTime}
</if>
<if
test=
"dto.acceptDate != null and dto.acceptDate != ''"
>
AND tjcr.accept_date = #{dto.acceptDate}
</if>
<if
test=
"type == 'supervision'"
>
AND tjcr.instance_id
<![CDATA[<>]]>
''
AND tjcr.receive_company_code = #{companyCode}
</if>
<if
test=
"type == 'enterprise'"
>
AND tjcr.use_unit_code = #{dto.useUnitCode}
</if>
<if
test=
"orgCode != null and orgCode != ''"
>
AND tjcr.instance_id
<![CDATA[<>]]>
''
AND EXISTS (
SELECT 1
FROM unnest(string_to_array(ed.orgBranchCodes, ',')) AS elem
WHERE elem LIKE concat(#{orgCode},'%' ) )
</if>
</if>
</where>
ORDER BY
<if
test=
"sort != null"
>
tjcr.${sort.field} ${sort.sortType},
</if>
tjcr.create_date DESC, tjcr.apply_no DESC
</select>
</mapper>
</mapper>
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgChangeRegistrationTransferMapper.xml
View file @
ada6d160
...
@@ -48,7 +48,8 @@
...
@@ -48,7 +48,8 @@
concat(use."PROVINCE_NAME", '', use."CITY_NAME", '', use."COUNTY_NAME", '', use."STREET_NAME") as allAddress,
concat(use."PROVINCE_NAME", '', use."CITY_NAME", '', use."COUNTY_NAME", '', use."STREET_NAME") as allAddress,
(SELECT name from tz_equipment_category WHERE code = jri.EQU_LIST) AS equList,
(SELECT name from tz_equipment_category WHERE code = jri.EQU_LIST) AS equList,
(SELECT name from tz_equipment_category where code = jri.EQU_CATEGORY) as equCategory,
(SELECT name from tz_equipment_category where code = jri.EQU_CATEGORY) as equCategory,
(SELECT name from tz_equipment_category where code = jri.EQU_DEFINE) as equDefine
(SELECT name from tz_equipment_category where code = jri.EQU_DEFINE) as equDefine,
ed.orgBranchCodes
from tzs_jg_change_registration_transfer crt
from tzs_jg_change_registration_transfer crt
LEFT JOIN crteq_limited crteq ON crt.sequence_nbr = crteq.equip_transfer_id AND crteq.rn = 1
LEFT JOIN crteq_limited crteq ON crt.sequence_nbr = crteq.equip_transfer_id AND crteq.rn = 1
LEFT JOIN idx_biz_jg_register_info jri on crteq.equ_id = jri.RECORD
LEFT JOIN idx_biz_jg_register_info jri on crteq.equ_id = jri.RECORD
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgChangeRegistrationUnitMapper.xml
View file @
ada6d160
...
@@ -15,7 +15,9 @@
...
@@ -15,7 +15,9 @@
GROUP BY unit_change_registration_id
GROUP BY unit_change_registration_id
)
)
select
select
isn.*
DISTINCT ins.sequence_nbr AS sequenceNbr,
isn.*,
ed.orgBranchCodes
FROM
FROM
tzs_jg_change_registration_unit isn
tzs_jg_change_registration_unit isn
LEFT JOIN equip_data ed on ed.unit_change_registration_id = isn.sequence_nbr
LEFT JOIN equip_data ed on ed.unit_change_registration_id = isn.sequence_nbr
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgChangeVehicleRegistrationUnitMapper.xml
View file @
ada6d160
...
@@ -39,8 +39,19 @@
...
@@ -39,8 +39,19 @@
</select>
</select>
<sql
id=
"page_list"
>
<sql
id=
"page_list"
>
<![CDATA[/*+ set(query_dop 16)*/ ]]>
WITH equip_data as (
SELECT
unit_change_id,
equ_id,
group_concat(distinct si."ORG_BRANCH_CODE") as orgBranchCodes
FROM
tzs_jg_change_vehicle_registration_unit_eq crueq
LEFT JOIN idx_biz_jg_supervision_info si ON si.record = crueq.equ_id
GROUP BY unit_change_id
)
select
select
cru.sequence_nbr as sequenceNbr,
DISTINCT
cru.sequence_nbr as sequenceNbr,
cru.change_type as changeType,
cru.change_type as changeType,
cru.apply_no as applyNo,
cru.apply_no as applyNo,
date_format(cru.apply_date,'%Y-%m-%d') as applyDate,
date_format(cru.apply_date,'%Y-%m-%d') as applyDate,
...
@@ -61,11 +72,12 @@
...
@@ -61,11 +72,12 @@
cru.promoter,
cru.promoter,
cru.next_executor_ids as nextExecutorIds,
cru.next_executor_ids as nextExecutorIds,
cru.instance_id as instanceId,
cru.instance_id as instanceId,
cru.create_user_id as createUserId
cru.create_user_id as createUserId,
ed.orgBranchCodes
from tzs_jg_change_vehicle_registration_unit cru
from tzs_jg_change_vehicle_registration_unit cru
LEFT JOIN equip_data ed on ed.unit_change_id = cru.sequence_nbr
</sql>
</sql>
<select
id=
"getPage"
<select
id=
"getPage"
resultType=
"java.util.Map"
>
resultType=
"java.util.Map"
>
<include
refid=
"page_list"
/>
<include
refid=
"page_list"
/>
<where>
<where>
<if
test=
"dto.applyNo != null and dto.applyNo != ''"
>
<if
test=
"dto.applyNo != null and dto.applyNo != ''"
>
...
@@ -78,7 +90,7 @@
...
@@ -78,7 +90,7 @@
and cru.status = #{dto.status}
and cru.status = #{dto.status}
</if>
</if>
<if
test=
"dto.auditPassDate != null and dto.auditPassDate != ''"
>
<if
test=
"dto.auditPassDate != null and dto.auditPassDate != ''"
>
and cru.audit_pass_date = #{dto.auditPassDate}
AND cru.audit_pass_date like concat('%',DATE_FORMAT(#{dto.auditPassDate},'%Y-%m-%d'),'%')
</if>
</if>
<if
test=
"dto.newUseUnitCreditCode != null and dto.newUseUnitCreditCode != ''"
>
<if
test=
"dto.newUseUnitCreditCode != null and dto.newUseUnitCreditCode != ''"
>
and cru.new_use_unit_credit_code = #{dto.newUseUnitCreditCode}
and cru.new_use_unit_credit_code = #{dto.newUseUnitCreditCode}
...
@@ -96,19 +108,30 @@
...
@@ -96,19 +108,30 @@
AND cru.create_date LIKE concat(DATE_FORMAT(#{dto.createDate},'%Y-%m-%d'),'%')
AND cru.create_date LIKE concat(DATE_FORMAT(#{dto.createDate},'%Y-%m-%d'),'%')
</if>
</if>
<if
test=
"type == 'supervision'"
>
<if
test=
"type == 'supervision'"
>
AND (cru.receive_org_code = #{
org
Code} or cru.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
AND (cru.receive_org_code = #{
company
Code} or cru.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
AND cru.instance_id
<![CDATA[<>]]>
''
AND cru.instance_id
<![CDATA[<>]]>
''
</if>
</if>
<if
test=
"type == 'enterprise'"
>
<if
test=
"type == 'enterprise'"
>
AND (cru.new_use_unit_credit_code = #{
org
Code} or cru.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
AND (cru.new_use_unit_credit_code = #{
dto.newUseUnitCredit
Code} or cru.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
</if>
</if>
<if
test=
"roleIds != null and type == 'supervision'"
>
<if
test=
"roleIds != null and type == 'supervision'"
>
<foreach
collection=
'roleIds'
item=
'role'
open=
'and ('
close=
')'
separator=
'or'
>
<foreach
collection=
'roleIds'
item=
'role'
open=
'and ('
close=
')'
separator=
'or'
>
cru.instance_status like concat('%',#{role},'%')
cru.instance_status like concat('%',#{role},'%')
</foreach>
</foreach>
</if>
</if>
<if
test=
"orgCode != null and orgCode != ''"
>
AND cru.instance_id
<![CDATA[<>]]>
''
AND EXISTS (
SELECT 1
FROM unnest(string_to_array(ed.orgBranchCodes, ',')) AS elem
WHERE elem LIKE concat(#{orgCode},'%' ) )
</if>
</where>
</where>
order by cru.create_date DESC, cru.apply_no DESC
order by
<if
test=
"sort != null"
>
cru.${sort.field} ${sort.sortType},
</if>
cru.create_date DESC, cru.apply_no DESC
</select>
</select>
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgEquipTransferMapper.xml
View file @
ada6d160
...
@@ -2,8 +2,19 @@
...
@@ -2,8 +2,19 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!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.jg.api.mapper.JgEquipTransferMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.jg.api.mapper.JgEquipTransferMapper"
>
<sql
id=
"page_list"
>
<sql
id=
"page_list"
>
<![CDATA[/*+ set(query_dop 16)*/ ]]>
WITH equip_data as (
SELECT
equip_transfer_id,
equ_id,
group_concat(distinct si."ORG_BRANCH_CODE") as orgBranchCodes
FROM
tzs_jg_equip_transfer_eq jeteq
LEFT JOIN idx_biz_jg_supervision_info si ON si.record = jeteq.equ_id
GROUP BY equip_transfer_id
)
select
select
jet.sequence_nbr AS sequenceNbr,
DISTINCT
jet.sequence_nbr AS sequenceNbr,
jet.apply_no AS applyNo,
jet.apply_no AS applyNo,
jet.use_unit_credit_code AS useUnitCreditCode,
jet.use_unit_credit_code AS useUnitCreditCode,
jet.use_unit_name AS useUnitName,
jet.use_unit_name AS useUnitName,
...
@@ -60,7 +71,8 @@
...
@@ -60,7 +71,8 @@
oi.CODE96333 as code96333,
oi.CODE96333 as code96333,
(select name from tz_equipment_category tec1 where tec1.code = ri."EQU_LIST") AS equList,
(select name from tz_equipment_category tec1 where tec1.code = ri."EQU_LIST") AS equList,
(select name from tz_equipment_category tec2 where tec2.code = ri."EQU_CATEGORY") AS equCategory,
(select name from tz_equipment_category tec2 where tec2.code = ri."EQU_CATEGORY") AS equCategory,
(select name from tz_equipment_category tec3 where tec3.code = ri."EQU_DEFINE") AS equDefine
(select name from tz_equipment_category tec3 where tec3.code = ri."EQU_DEFINE") AS equDefine,
ed.orgBranchCodes
FROM tzs_jg_equip_transfer jet
FROM tzs_jg_equip_transfer jet
LEFT JOIN (SELECT *,
LEFT JOIN (SELECT *,
ROW_NUMBER() OVER (PARTITION BY equip_transfer_id ORDER BY equip_transfer_id) AS rn
ROW_NUMBER() OVER (PARTITION BY equip_transfer_id ORDER BY equip_transfer_id) AS rn
...
@@ -71,6 +83,7 @@
...
@@ -71,6 +83,7 @@
LEFT JOIN idx_biz_jg_factory_info fi ON fi.record = ete.equ_id
LEFT JOIN idx_biz_jg_factory_info fi ON fi.record = ete.equ_id
LEFT JOIN idx_biz_jg_use_info ui ON ui.record = ete.equ_id
LEFT JOIN idx_biz_jg_use_info ui ON ui.record = ete.equ_id
LEFT JOIN idx_biz_jg_other_info oi ON oi.RECORD = ete.equ_id
LEFT JOIN idx_biz_jg_other_info oi ON oi.RECORD = ete.equ_id
LEFT JOIN equip_data ed on ed.equip_transfer_id = jet.sequence_nbr
</sql>
</sql>
<select
id=
"queryForPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgEquipTransferDto"
>
<select
id=
"queryForPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgEquipTransferDto"
>
<include
refid=
"page_list"
/>
<include
refid=
"page_list"
/>
...
@@ -125,27 +138,27 @@
...
@@ -125,27 +138,27 @@
AND jet.create_date LIKE concat(DATE_FORMAT(#{param.createDate},'%Y-%m-%d'),'%')
AND jet.create_date LIKE concat(DATE_FORMAT(#{param.createDate},'%Y-%m-%d'),'%')
</if>
</if>
</if>
</if>
<choose>
<if
test=
"type == 'use,install'"
>
<when
test=
"param.useUnitCodeFilter != '' and param.useUnitCodeFilter != null and
param.installUnitCodeFilter != '' and param.installUnitCodeFilter != null"
>
-- 同时有使用单位和施工单位
and (
and (
jet.use_unit_credit_code = #{param.useUnitCodeFilter}
jet.use_unit_credit_code = #{param.useUnitCodeFilter}
or jet.install_unit_credit_code = #{param.installUnitCodeFilter}
or jet.install_unit_credit_code = #{param.installUnitCodeFilter}
or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' )
or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' )
)
)
</when>
</if>
<otherwise
>
<if
test=
"type == 'use'"
>
-- 只有使用单位或者施工单位
<if
test=
"param.useUnitCodeFilter != '' and param.useUnitCodeFilter != null"
>
and (jet.use_unit_credit_code = #{param.useUnitCodeFilter} or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
and (jet.use_unit_credit_code = #{param.useUnitCodeFilter} or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
</if>
</if>
<if
test=
"param.installUnitCodeFilter != '' and param.installUnitCodeFilter != null
"
>
<if
test=
"type == 'install'
"
>
and (jet.install_unit_credit_code = #{param.installUnitCodeFilter} or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
and (jet.install_unit_credit_code = #{param.installUnitCodeFilter} or jet.transfer_to_user_ids LIKE concat ( '%', #{currentUserId}, '%' ))
AND jet.instance_id
<![CDATA[<>]]>
''
AND jet.instance_id
<![CDATA[<>]]>
''
</if>
</if>
</otherwise>
<if
test=
"orgCode != null and orgCode != ''"
>
</choose>
AND jet.instance_id
<![CDATA[<>]]>
''
AND EXISTS (
SELECT 1
FROM unnest(string_to_array(ed.orgBranchCodes, ',')) AS elem
WHERE elem LIKE concat(#{orgCode},'%' ) )
</if>
</where>
</where>
ORDER BY
ORDER BY
<if
test=
"sort != null"
>
<if
test=
"sort != null"
>
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgMaintainNoticeMapper.xml
View file @
ada6d160
...
@@ -80,7 +80,8 @@
...
@@ -80,7 +80,8 @@
isn.cancel_reason AS cancelReason,
isn.cancel_reason AS cancelReason,
(SELECT name from tz_equipment_category ec WHERE ec.code = isn.equ_list_code) AS equListName,
(SELECT name from tz_equipment_category ec WHERE ec.code = isn.equ_list_code) AS equListName,
DATE_FORMAT(isn.create_date,'%Y-%m-%d') AS createDate,
DATE_FORMAT(isn.create_date,'%Y-%m-%d') AS createDate,
(select name from tz_equipment_category ec WHERE ec.code = isn.equ_category) AS equCategoryName
(select name from tz_equipment_category ec WHERE ec.code = isn.equ_category) AS equCategoryName,
ed.orgBranchCodes
</sql>
</sql>
<select
id=
"queryForPage"
resultType=
"java.util.Map"
>
<select
id=
"queryForPage"
resultType=
"java.util.Map"
>
<include
refid=
"page_list"
/>
<include
refid=
"page_list"
/>
...
@@ -131,10 +132,10 @@
...
@@ -131,10 +132,10 @@
</if>
</if>
<if
test=
"type != 'company' and type != null"
>
<if
test=
"type != 'company' and type != null"
>
AND isn.instance_id
<![CDATA[<>]]>
''
AND isn.instance_id
<![CDATA[<>]]>
''
AND (isn.receive_company_code = #{
org
Code} or isn.transfer_to_user_ids like concat('%',#{userId},'%'))
AND (isn.receive_company_code = #{
company
Code} or isn.transfer_to_user_ids like concat('%',#{userId},'%'))
</if>
</if>
<if
test=
"type == 'company'"
>
<if
test=
"type == 'company'"
>
AND (isn.install_unit_credit_code = #{
org
Code} or isn.transfer_to_user_ids like
AND (isn.install_unit_credit_code = #{
param.useUnitCredit
Code} or isn.transfer_to_user_ids like
concat('%',#{userId},'%'))
concat('%',#{userId},'%'))
</if>
</if>
<if
test=
"orgCode != null and orgCode != ''"
>
<if
test=
"orgCode != null and orgCode != ''"
>
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgScrapCancelMapper.xml
View file @
ada6d160
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
GROUP BY equip_transfer_id
GROUP BY equip_transfer_id
)
)
select
select
tjsc.sequence_nbr,
DISTINCT
tjsc.sequence_nbr,
tjsc.instance_id,
tjsc.instance_id,
tjsc.create_user_id,
tjsc.create_user_id,
tjsc.audit_status,
tjsc.audit_status,
...
@@ -45,7 +45,8 @@
...
@@ -45,7 +45,8 @@
tjsc.use_unit_name,
tjsc.use_unit_name,
tjsc.use_unit_code,
tjsc.use_unit_code,
tjsc.use_registration_code,
tjsc.use_registration_code,
tjsc.equ_list_code
tjsc.equ_list_code,
ed.orgBranchCodes
from tzs_jg_scrap_cancel tjsc
from tzs_jg_scrap_cancel tjsc
LEFT JOIN equip_data ed on ed.equip_transfer_id = tjsc.sequence_nbr
LEFT JOIN equip_data ed on ed.equip_transfer_id = tjsc.sequence_nbr
</sql>
</sql>
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgCertificateReplenishController.java
View file @
ada6d160
...
@@ -10,6 +10,7 @@ import com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateReplenish;
...
@@ -10,6 +10,7 @@ import com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateReplenish;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.JgCertificateReplenishServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.JgCertificateReplenishServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.component.event.RestEventTrigger
;
import
org.typroject.tyboot.component.event.RestEventTrigger
;
...
@@ -101,12 +102,15 @@ public class JgCertificateReplenishController extends BaseController {
...
@@ -101,12 +102,15 @@ public class JgCertificateReplenishController extends BaseController {
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"分页查询"
,
notes
=
"分页查询"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"分页查询"
,
notes
=
"分页查询"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<
Page
<
JgCertificateReplenish
>>
queryForPage
(
JgCertificateReplenishDto
dto
,
public
ResponseModel
<
Page
<
JgCertificateReplenish
>>
queryForPage
(
JgCertificateReplenishDto
dto
,
@RequestParam
(
value
=
"current"
)
int
current
,
@ApiParam
(
value
=
"当前页码"
,
required
=
true
)
@RequestParam
(
value
=
"current"
,
defaultValue
=
"1"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
@ApiParam
(
value
=
"每页大小"
,
required
=
true
)
@RequestParam
(
value
=
"size"
,
defaultValue
=
"20"
)
int
size
,
@ApiParam
(
value
=
"排序字段"
,
required
=
false
)
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
@ApiParam
(
value
=
"客户端类型: jgAudit-监管审核;jgLook-监管查看"
)
@RequestParam
(
value
=
"client"
,
required
=
false
,
defaultValue
=
"jgAudit"
)
String
client
)
{
Page
<
JgCertificateReplenish
>
page
=
new
Page
<
JgCertificateReplenish
>();
Page
<
JgCertificateReplenish
>
page
=
new
Page
<
JgCertificateReplenish
>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
jgCertificateReplenishServiceImpl
.
queryForJgCertificateReplenishPage
(
page
,
dto
));
return
ResponseHelper
.
buildResponse
(
jgCertificateReplenishServiceImpl
.
queryForJgCertificateReplenishPage
(
page
,
dto
,
sort
,
client
));
}
}
/**
/**
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgChangeVehicleRegistrationUnitController.java
View file @
ada6d160
...
@@ -12,6 +12,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.impl.CommonServiceImpl;
...
@@ -12,6 +12,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.impl.CommonServiceImpl;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.JgChangeVehicleRegistrationUnitServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.JgChangeVehicleRegistrationUnitServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
...
@@ -204,19 +205,20 @@ public class JgChangeVehicleRegistrationUnitController extends BaseController {
...
@@ -204,19 +205,20 @@ public class JgChangeVehicleRegistrationUnitController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/getPage"
)
@PostMapping
(
value
=
"/getPage"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"车用气瓶列表"
,
notes
=
"车用气瓶列表"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"车用气瓶列表"
,
notes
=
"车用气瓶列表"
)
public
ResponseModel
<
Object
>
getPage
(
JgChangeVehicleRegistrationUnitDto
dto
,
public
ResponseModel
<
Object
>
getPage
(
@RequestBody
(
required
=
false
)
JgChangeVehicleRegistrationUnitDto
dto
,
@RequestParam
(
value
=
"number"
)
int
number
,
@RequestParam
(
value
=
"number"
)
int
number
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
@RequestParam
(
value
=
"size"
)
int
size
,
@ApiParam
(
value
=
"排序字段"
,
required
=
false
)
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
@ApiParam
(
value
=
"客户端类型: jgAudit-监管审核;jgLook-监管查看"
)
@RequestParam
(
value
=
"client"
,
required
=
false
,
defaultValue
=
"jgAudit"
)
String
client
)
{
Page
<
JgChangeVehicleRegistrationUnit
>
page
=
new
Page
<>(
number
,
size
);
Page
<
JgChangeVehicleRegistrationUnit
>
page
=
new
Page
<>(
number
,
size
);
ReginParams
reginParams
=
getSelectedOrgInfo
();
ReginParams
reginParams
=
getSelectedOrgInfo
();
ReginParams
info
=
getSelectedOrgInfo
();
String
type
=
""
;
String
type
=
""
;
if
(
info
.
getCompany
().
getLevel
().
equals
(
BaseController
.
COMPANY_TYPE_COMPANY
))
{
if
(
reginParams
.
getCompany
().
getLevel
().
equals
(
BaseController
.
COMPANY_TYPE_COMPANY
))
{
type
=
"enterprise"
;
type
=
"enterprise"
;
}
else
{
}
else
{
type
=
"supervision"
;
type
=
"supervision"
;
}
}
return
ResponseHelper
.
buildResponse
(
jgChangeVehicleRegistrationUnitServiceImpl
.
getPage
(
page
,
sort
,
dto
,
type
,
reginParams
,
client
));
return
ResponseHelper
.
buildResponse
(
jgChangeVehicleRegistrationUnitServiceImpl
.
getPage
(
page
,
dto
,
type
,
reginParams
));
}
}
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgEquipTransferController.java
View file @
ada6d160
...
@@ -14,6 +14,7 @@ import com.yeejoin.amos.feign.privilege.model.AgencyUserModel;
...
@@ -14,6 +14,7 @@ import com.yeejoin.amos.feign.privilege.model.AgencyUserModel;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
...
@@ -115,9 +116,10 @@ public class JgEquipTransferController extends BaseController {
...
@@ -115,9 +116,10 @@ public class JgEquipTransferController extends BaseController {
public
ResponseModel
<
Page
<
JgEquipTransferDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
public
ResponseModel
<
Page
<
JgEquipTransferDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
@RequestBody
(
required
=
false
)
JgEquipTransferDto
dto
)
{
@RequestBody
(
required
=
false
)
JgEquipTransferDto
dto
,
@ApiParam
(
value
=
"客户端类型: jgAudit-监管审核;jgLook-监管查看"
)
@RequestParam
(
value
=
"client"
,
required
=
false
,
defaultValue
=
"jgAudit"
)
String
client
)
{
Page
<
JgEquipTransferDto
>
page
=
new
Page
<>(
current
,
size
);
Page
<
JgEquipTransferDto
>
page
=
new
Page
<>(
current
,
size
);
return
ResponseHelper
.
buildResponse
(
jgEquipTransferServiceImpl
.
queryForJgEquipTransferPage
(
page
,
sort
,
dto
,
getSelectedOrgInfo
()));
return
ResponseHelper
.
buildResponse
(
jgEquipTransferServiceImpl
.
queryForJgEquipTransferPage
(
page
,
sort
,
dto
,
getSelectedOrgInfo
()
,
client
));
}
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
...
...
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/JgCertificateReplenishServiceImpl.java
View file @
ada6d160
...
@@ -7,7 +7,6 @@ import com.alibaba.fastjson.JSONArray;
...
@@ -7,7 +7,6 @@ import com.alibaba.fastjson.JSONArray;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
...
@@ -23,6 +22,7 @@ import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum;
...
@@ -23,6 +22,7 @@ import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum;
import
com.yeejoin.amos.boot.module.jg.api.enums.CompanyTypeEnum
;
import
com.yeejoin.amos.boot.module.jg.api.enums.CompanyTypeEnum
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgCertificateReplenishMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgCertificateReplenishMapper
;
import
com.yeejoin.amos.boot.module.jg.api.service.IJgCertificateReplenishService
;
import
com.yeejoin.amos.boot.module.jg.api.service.IJgCertificateReplenishService
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest
;
import
com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest
;
import
com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext
;
...
@@ -148,6 +148,7 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
...
@@ -148,6 +148,7 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
private
final
JgCertificateChangeRecordServiceImpl
certificateChangeRecordService
;
private
final
JgCertificateChangeRecordServiceImpl
certificateChangeRecordService
;
private
final
JgCertificateChangeRecordEqServiceImpl
certificateChangeRecordEqService
;
private
final
JgCertificateChangeRecordEqServiceImpl
certificateChangeRecordEqService
;
private
final
IdxBizJgFactoryInfoServiceImpl
idxBizJgFactoryInfoService
;
private
final
IdxBizJgFactoryInfoServiceImpl
idxBizJgFactoryInfoService
;
private
final
JgCertificateReplenishMapper
jgCertificateReplenishMapper
;
/**
/**
* 用户信息
* 用户信息
...
@@ -695,36 +696,22 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
...
@@ -695,36 +696,22 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
/**
/**
* 分页查询
* 分页查询
*/
*/
public
Page
<
JgCertificateReplenish
>
queryForJgCertificateReplenishPage
(
Page
<
JgCertificateReplenish
>
page
,
JgCertificateReplenishDto
dto
)
{
public
Page
<
JgCertificateReplenish
>
queryForJgCertificateReplenishPage
(
Page
<
JgCertificateReplenish
>
page
,
JgCertificateReplenishDto
dto
,
String
sort
,
String
client
)
{
CompanyBo
company
=
getSelectedOrgInfo
().
getCompany
();
ReginParams
reginParams
=
getSelectedOrgInfo
();
boolean
isCompany
=
!
company
.
getCompanyType
().
equals
(
JG_COMAPNY_TYPE
);
CompanyBo
company
=
reginParams
.
getCompany
();
boolean
isSupervision
=
company
.
getCompanyType
().
equals
(
JG_COMAPNY_TYPE
);
String
companyCode
=
company
.
getCompanyCode
();
String
useUnitCode
=
""
;
String
orgCode
=
"jgLook"
.
equals
(
client
)
?
reginParams
.
getCompany
().
getOrgCode
()
:
null
;
if
(
isCompany
)
{
String
type
=
"jgLook"
.
equals
(
client
)
?
null
:
company
.
getLevel
().
equals
(
BaseController
.
COMPANY_TYPE_COMPANY
)
?
"enterprise"
:
"supervision"
;
useUnitCode
=
CompanyTypeEnum
.
INDIVIDUAL
.
getName
().
equals
(
company
.
getCompanyType
())
?
company
.
getCompanyCode
().
split
(
"_"
)[
1
]
:
company
.
getCompanyCode
();
SortVo
sortMap
=
commonService
.
sortFieldConversion
(
sort
);
}
if
(
"enterprise"
.
equals
(
type
)){
String
useUnitCode
=
CompanyTypeEnum
.
INDIVIDUAL
.
getName
().
equals
(
company
.
getCompanyType
())
?
company
.
getCompanyCode
().
split
(
"_"
)[
1
]
:
company
.
getCompanyCode
();
dto
.
setUseUnitCode
(
useUnitCode
);
}
Page
<
JgCertificateReplenish
>
replenishIPage
=
jgCertificateReplenishMapper
.
queryForPage
(
page
,
sortMap
,
dto
,
type
,
companyCode
,
orgCode
);
Page
<
JgCertificateReplenish
>
result
=
new
Page
<>();
Page
<
JgCertificateReplenish
>
result
=
new
Page
<>();
IPage
<
JgCertificateReplenish
>
replenishIPage
=
this
.
lambdaQuery
()
// 监管
.
eq
(
isSupervision
,
JgCertificateReplenish:
:
getReceiveOrgCode
,
company
.
getCompanyCode
())
.
isNotNull
(
isSupervision
,
JgCertificateReplenish:
:
getInstanceId
)
// 非监管
.
eq
(
isCompany
,
JgCertificateReplenish:
:
getUseUnitCode
,
useUnitCode
)
.
eq
(
JgCertificateReplenish:
:
getIsDelete
,
Boolean
.
FALSE
)
.
like
(!
ValidationUtil
.
isEmpty
(
dto
.
getUseRegistrationCode
()),
JgCertificateReplenish:
:
getUseRegistrationCode
,
dto
.
getUseRegistrationCode
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getEquListCode
()),
JgCertificateReplenish:
:
getEquListCode
,
dto
.
getEquListCode
())
.
like
(!
ValidationUtil
.
isEmpty
(
dto
.
getApplyNo
()),
JgCertificateReplenish:
:
getApplyNo
,
dto
.
getApplyNo
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getApplyStatus
()),
JgCertificateReplenish:
:
getApplyStatus
,
dto
.
getApplyStatus
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getUseUnitCode
()),
JgCertificateReplenish:
:
getUseUnitCode
,
dto
.
getUseUnitCode
())
.
like
(!
ValidationUtil
.
isEmpty
(
dto
.
getUseUnitName
()),
JgCertificateReplenish:
:
getUseUnitName
,
dto
.
getUseUnitName
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getApplicationReason
()),
JgCertificateReplenish:
:
getApplicationReason
,
dto
.
getApplicationReason
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getLossDamageTime
()),
JgCertificateReplenish:
:
getLossDamageTime
,
dto
.
getLossDamageTime
())
.
eq
(!
ValidationUtil
.
isEmpty
(
dto
.
getAcceptDate
()),
JgCertificateReplenish:
:
getAcceptDate
,
dto
.
getAcceptDate
())
.
orderByDesc
(
JgCertificateReplenish:
:
getCreateDate
)
.
page
(
page
);
result
.
setRecords
(
replenishIPage
.
getRecords
().
stream
().
peek
(
item
->
{
result
.
setRecords
(
replenishIPage
.
getRecords
().
stream
().
peek
(
item
->
{
item
.
setApplyStatusDes
(
FlowStatusEnum
.
getNameByType
(
Long
.
parseLong
(
item
.
getApplyStatus
())));
item
.
setApplyStatusDes
(
FlowStatusEnum
.
getNameByType
(
Long
.
parseLong
(
item
.
getApplyStatus
())));
item
.
setIsCompany
(
isCompany
);
item
.
setIsCompany
(
company
.
getLevel
().
equals
(
BaseController
.
COMPANY_TYPE_COMPANY
)
);
item
.
setApplicationReason
(
"0"
.
equals
(
item
.
getApplicationReason
())
?
"遗失"
:
"损毁"
);
item
.
setApplicationReason
(
"0"
.
equals
(
item
.
getApplicationReason
())
?
"遗失"
:
"损毁"
);
}).
collect
(
Collectors
.
toList
()));
}).
collect
(
Collectors
.
toList
()));
result
.
setTotal
(
replenishIPage
.
getTotal
());
result
.
setTotal
(
replenishIPage
.
getTotal
());
...
...
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/JgChangeVehicleRegistrationUnitServiceImpl.java
View file @
ada6d160
...
@@ -22,13 +22,13 @@ import com.yeejoin.amos.boot.module.jg.api.enums.VehicleApanageEnum;
...
@@ -22,13 +22,13 @@ import com.yeejoin.amos.boot.module.jg.api.enums.VehicleApanageEnum;
import
com.yeejoin.amos.boot.module.jg.api.enums.WorkFlowStatusEnum
;
import
com.yeejoin.amos.boot.module.jg.api.enums.WorkFlowStatusEnum
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgChangeVehicleRegistrationUnitMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgChangeVehicleRegistrationUnitMapper
;
import
com.yeejoin.amos.boot.module.jg.api.service.IJgChangeVehicleRegistrationUnitService
;
import
com.yeejoin.amos.boot.module.jg.api.service.IJgChangeVehicleRegistrationUnitService
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest
;
import
com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest
;
import
com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext
;
import
com.yeejoin.amos.boot.module.jg.biz.edit.permission.FillingEditPermForCurrentUser
;
import
com.yeejoin.amos.boot.module.jg.biz.edit.permission.FillingEditPermForCurrentUser
;
import
com.yeejoin.amos.boot.module.jg.biz.event.publisher.EventPublisher
;
import
com.yeejoin.amos.boot.module.jg.biz.event.publisher.EventPublisher
;
import
com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient
;
import
com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICommonService
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICompensateFlowDataOfRedis
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICompensateFlowDataOfRedis
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgOtherInfo
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgOtherInfo
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgRegisterInfo
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgRegisterInfo
;
...
@@ -95,7 +95,7 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
...
@@ -95,7 +95,7 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
@Autowired
@Autowired
RedisUtils
redisUtils
;
RedisUtils
redisUtils
;
@Autowired
@Autowired
ICommonService
commonService
;
private
CommonServiceImpl
commonService
;
@Autowired
@Autowired
TzsServiceFeignClient
tzsServiceFeignClient
;
TzsServiceFeignClient
tzsServiceFeignClient
;
@Autowired
@Autowired
...
@@ -306,18 +306,16 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
...
@@ -306,18 +306,16 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
});
});
}
}
public
Page
<
Map
<
String
,
Object
>>
getPage
public
Page
<
Map
<
String
,
Object
>>
getPage
(
(
Page
<
JgChangeVehicleRegistrationUnit
>
page
,
JgChangeVehicleRegistrationUnitDto
dto
,
String
type
,
ReginParams
Page
<
JgChangeVehicleRegistrationUnit
>
page
,
String
sort
,
JgChangeVehicleRegistrationUnitDto
dto
,
String
type
,
ReginParams
reginParams
,
String
client
)
{
reginParams
)
{
String
orgCode
=
reginParams
.
getCompany
().
getCompanyCode
();
String
reslut
=
orgCode
;
if
(
orgCode
.
contains
(
"_"
))
{
String
[]
parts
=
orgCode
.
split
(
"_"
);
reslut
=
parts
[
1
];
}
CompanyBo
company
=
reginParams
.
getCompany
();
String
companyCode
=
company
.
getCompanyCode
().
contains
(
"_"
)
?
company
.
getCompanyCode
().
split
(
"_"
)[
1
]
:
company
.
getCompanyCode
();
type
=
"jgLook"
.
equals
(
client
)
?
null
:
type
;
String
orgCode
=
"jgLook"
.
equals
(
client
)
?
company
.
getOrgCode
()
:
null
;
String
currentUserId
=
reginParams
.
getUserModel
().
getUserId
();
String
currentUserId
=
reginParams
.
getUserModel
().
getUserId
();
return
this
.
getBaseMapper
().
getPage
(
page
,
dto
,
type
,
reslut
,
currentUserId
,
dto
.
getRoleIds
());
SortVo
sortMap
=
commonService
.
sortFieldConversion
(
sort
);
return
this
.
getBaseMapper
().
getPage
(
page
,
sortMap
,
dto
,
type
,
companyCode
,
currentUserId
,
dto
.
getRoleIds
(),
orgCode
);
}
}
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
...
...
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/JgEquipTransferServiceImpl.java
View file @
ada6d160
...
@@ -696,21 +696,25 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto,
...
@@ -696,21 +696,25 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto,
}
}
@Override
@Override
public
Page
<
JgEquipTransferDto
>
queryForJgEquipTransferPage
(
Page
<
JgEquipTransferDto
>
page
,
String
sort
,
JgEquipTransferDto
dto
,
ReginParams
reginParams
)
{
public
Page
<
JgEquipTransferDto
>
queryForJgEquipTransferPage
(
Page
<
JgEquipTransferDto
>
page
,
String
sort
,
JgEquipTransferDto
dto
,
ReginParams
reginParams
,
String
client
)
{
CompanyBo
company
=
reginParams
.
getCompany
();
CompanyBo
company
=
reginParams
.
getCompany
();
Map
<
String
,
Object
>
companyTypeMap
=
jrmInstallationNoticeService
.
getCompanyType
();
String
companyLevel
=
company
.
getLevel
();
String
company
Level
=
getStringFromMap
(
companyTypeMap
,
"companyLevel"
);
String
company
Type
=
company
.
getCompanyType
(
);
String
companyType
=
getStringFromMap
(
companyTypeMap
,
"companyType"
);
List
<
String
>
typeList
=
new
ArrayList
<>(
);
if
(
"company"
.
equals
(
companyLevel
)
&&
companyType
!=
null
)
{
if
(
"company"
.
equals
(
companyLevel
)
&&
companyType
!=
null
)
{
if
(
companyType
.
contains
(
CompanyTypeEnum
.
USE
.
getCode
())
||
companyType
.
contains
(
CompanyTypeEnum
.
INDIVIDUAL
.
getCode
()))
{
if
(
companyType
.
contains
(
CompanyTypeEnum
.
USE
.
getCode
())
||
companyType
.
contains
(
CompanyTypeEnum
.
INDIVIDUAL
.
getCode
()))
{
dto
.
setUseUnitCodeFilter
(
company
.
getCompanyCode
().
contains
(
"_"
)
?
company
.
getCompanyCode
().
split
(
"_"
)[
1
]
:
company
.
getCompanyCode
());
dto
.
setUseUnitCodeFilter
(
company
.
getCompanyCode
().
contains
(
"_"
)
?
company
.
getCompanyCode
().
split
(
"_"
)[
1
]
:
company
.
getCompanyCode
());
typeList
.
add
(
"use"
);
}
}
if
(
companyType
.
contains
(
CompanyTypeEnum
.
CONSTRUCTION
.
getCode
()))
{
if
(
companyType
.
contains
(
CompanyTypeEnum
.
CONSTRUCTION
.
getCode
()))
{
dto
.
setInstallUnitCodeFilter
(
company
.
getCompanyCode
());
dto
.
setInstallUnitCodeFilter
(
company
.
getCompanyCode
());
typeList
.
add
(
"install"
);
}
}
}
}
String
type
=
String
.
join
(
","
,
typeList
);
SortVo
sortMap
=
commonService
.
sortFieldConversion
(
sort
);
SortVo
sortMap
=
commonService
.
sortFieldConversion
(
sort
);
Page
<
JgEquipTransferDto
>
equipTransferPage
=
this
.
baseMapper
.
queryForPage
(
page
,
sortMap
,
dto
,
reginParams
.
getUserModel
().
getUserId
());
String
orgCode
=
"jgLook"
.
equals
(
client
)
?
company
.
getOrgCode
()
:
null
;
Page
<
JgEquipTransferDto
>
equipTransferPage
=
this
.
baseMapper
.
queryForPage
(
page
,
sortMap
,
dto
,
reginParams
.
getUserModel
().
getUserId
(),
type
,
orgCode
);
equipTransferPage
.
getRecords
().
forEach
(
transfer
->
{
equipTransferPage
.
getRecords
().
forEach
(
transfer
->
{
if
(
Objects
.
nonNull
(
transfer
.
getApplyStatus
()))
{
if
(
Objects
.
nonNull
(
transfer
.
getApplyStatus
()))
{
transfer
.
setApplyStatusDesc
(
FlowStatusEnum
.
getNameByType
(
Long
.
valueOf
(
transfer
.
getApplyStatus
())));
transfer
.
setApplyStatusDesc
(
FlowStatusEnum
.
getNameByType
(
Long
.
valueOf
(
transfer
.
getApplyStatus
())));
...
...
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