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
72564851
Commit
72564851
authored
May 18, 2023
by
曹盼盼
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改企业列表
parent
062a4aef
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
82 additions
and
5 deletions
+82
-5
TzBaseEnterpriseInfoMapper.java
...oot/module/tzs/api/mapper/TzBaseEnterpriseInfoMapper.java
+2
-0
TzBaseEnterpriseInfoMapper.xml
.../src/main/resources/mapper/TzBaseEnterpriseInfoMapper.xml
+69
-0
TzBaseEnterpriseInfoServiceImpl.java
...tzs/biz/service/impl/TzBaseEnterpriseInfoServiceImpl.java
+11
-5
No files found.
amos-boot-system-tzs/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/api/mapper/TzBaseEnterpriseInfoMapper.java
View file @
72564851
...
...
@@ -43,4 +43,6 @@ public interface TzBaseEnterpriseInfoMapper extends BaseMapper<TzBaseEnterpriseI
IPage
<
TzBaseEnterpriseInfoDto
>
page
(
Page
<
TzBaseEnterpriseInfoDto
>
page
,
TzBaseEnterpriseInfoDto
tzBaseEnterpriseInfoDto
);
IPage
<
TzBaseEnterpriseInfoDto
>
pageList
(
Page
<
TzBaseEnterpriseInfoDto
>
page
,
TzBaseEnterpriseInfoDto
tzBaseEnterpriseInfoDto
,
List
orgCodeList
);
}
amos-boot-system-tzs/amos-boot-module-tzs-api/src/main/resources/mapper/TzBaseEnterpriseInfoMapper.xml
View file @
72564851
...
...
@@ -88,6 +88,75 @@
</where>
</select>
<select
id=
"pageList"
resultType=
"com.yeejoin.amos.boot.module.tzs.api.dto.TzBaseEnterpriseInfoDto"
>
SELECT
*,
CONCAT(province,'/',city,'/',district) AS region,
CONCAT(street,'/',address) AS full_address
FROM
tz_base_enterprise_info
<where>
<if
test=
"tzBaseEnterpriseInfoDto.unitType!=null and tzBaseEnterpriseInfoDto.unitType!='' "
>
AND unit_type = #{tzBaseEnterpriseInfoDto.unitType}
</if>
<if
test=
"tzBaseEnterpriseInfoDto.useUnit!=null and tzBaseEnterpriseInfoDto.useUnit!='' "
>
AND use_unit LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.useUnit},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.useUnitCertificate!=null and tzBaseEnterpriseInfoDto.useUnitCertificate!='' "
>
AND use_unit_certificate = #{tzBaseEnterpriseInfoDto.useUnitCertificate}
</if>
<if
test=
"tzBaseEnterpriseInfoDto.useCode!=null and tzBaseEnterpriseInfoDto.useCode!='' "
>
AND use_code LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.useCode},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.superviseOrgCode!=null and tzBaseEnterpriseInfoDto.superviseOrgCode!='' "
>
AND supervise_org_code LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.superviseOrgCode},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.region!=null and tzBaseEnterpriseInfoDto.region!='' "
>
AND CONCAT(province,'/',city,'/',district) LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.region},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.legalPerson!=null and tzBaseEnterpriseInfoDto.legalPerson!='' "
>
AND legal_person LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.legalPerson},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.legalPhone!=null and tzBaseEnterpriseInfoDto.legalPhone!='' "
>
AND legal_phone LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.legalPhone},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.superviseOrgCode!=null and tzBaseEnterpriseInfoDto.superviseOrgCode!='' "
>
AND supervise_org_code LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.superviseOrgCode},'%')
</if>
<if
test=
"tzBaseEnterpriseInfoDto.address!=null and tzBaseEnterpriseInfoDto.address!='' "
>
AND supervise_org_code LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.address},'%')
</if>
<if
test=
"orgCodeList != null and ! orgCodeList.isEmpty() and orgCodeList.size() > 0"
>
1=1
<foreach
collection=
"orgCodeList"
item=
"item"
index=
"index"
>
<if
test=
"index==0"
>
AND
</if>
<if
test=
"index!= 0"
>
OR
</if>
supervise_org_code LIKE CONCAT('%',#{item},'%')
</foreach>
</if>
AND is_delete = 0
</where>
</select>
<select
id=
"selectByUseUnit"
resultType=
"com.yeejoin.amos.boot.module.tzs.api.entity.TzBaseEnterpriseInfo"
>
select * from tz_base_enterprise_info where use_unit = #{useUnit}
</select>
...
...
amos-boot-system-tzs/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/biz/service/impl/TzBaseEnterpriseInfoServiceImpl.java
View file @
72564851
...
...
@@ -7,6 +7,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.github.pagehelper.util.PageObjectUtil
;
import
com.yeejoin.amos.boot.biz.common.entity.DataDictionary
;
import
com.yeejoin.amos.boot.biz.common.service.impl.DataDictionaryServiceImpl
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
...
...
@@ -125,6 +126,7 @@ public class TzBaseEnterpriseInfoServiceImpl
@Override
public
IPage
<
TzBaseEnterpriseInfoDto
>
page
(
PageParam
pageParam
,
TzBaseEnterpriseInfoDto
tzBaseEnterpriseInfoDto
)
{
List
<
String
>
orgCodeList
=
new
ArrayList
<>();
if
(
tzBaseEnterpriseInfoDto
.
getSuperviseKey
()
!=
null
)
{
FeignClientResult
<
CompanyModel
>
result
=
Privilege
.
companyClient
.
seleteOne
(
Long
.
valueOf
(
tzBaseEnterpriseInfoDto
.
getSuperviseKey
()));
...
...
@@ -134,12 +136,16 @@ public class TzBaseEnterpriseInfoServiceImpl
}
Page
<
TzBaseEnterpriseInfoDto
>
page
=
new
Page
<>(
pageParam
.
getCurrent
(),
pageParam
.
getSize
());
List
<
JSONObject
>
companyType1
=
equipmentCategoryService
.
getCompanyType
();
JSONObject
companyType
=
companyType1
.
get
(
0
);
String
orgCode
=
companyType
.
getString
(
"orgCode"
);
if
(!
ValidationUtil
.
isEmpty
(
orgCode
))
{
tzBaseEnterpriseInfoDto
.
setSuperviseOrgCode
(
orgCode
);
if
(!
ValidationUtil
.
isEmpty
(
companyType1
))
{
for
(
JSONObject
jsonObject
:
companyType1
)
{
String
orgCode
=
jsonObject
.
getString
(
"orgCode"
);
if
(!
ValidationUtil
.
isEmpty
(
orgCode
))
{
orgCodeList
.
add
(
orgCode
);
}
}
}
return
this
.
baseMapper
.
page
(
page
,
tzBaseEnterpriseInfoDto
);
return
this
.
baseMapper
.
pageList
(
page
,
tzBaseEnterpriseInfoDto
,
orgCodeList
);
}
@Override
...
...
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