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
2979a0b3
Commit
2979a0b3
authored
Nov 10, 2021
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
规则配置 查询接口
parent
f15e4593
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
330 additions
and
187 deletions
+330
-187
DutyPersonShiftMapper.java
.../boot/module/common/api/mapper/DutyPersonShiftMapper.java
+3
-0
FirefightersMapper.java
...mos/boot/module/common/api/mapper/FirefightersMapper.java
+2
-0
OrgUsrMapper.java
...join/amos/boot/module/common/api/mapper/OrgUsrMapper.java
+2
-0
IDutyPersonService.java
...os/boot/module/common/api/service/IDutyPersonService.java
+3
-0
DutyPersonShiftMapper.xml
...n-api/src/main/resources/mapper/DutyPersonShiftMapper.xml
+32
-10
FirefightersMapper.xml
...mmon-api/src/main/resources/mapper/FirefightersMapper.xml
+178
-163
OrgUsrMapper.xml
...ule-common-api/src/main/resources/mapper/OrgUsrMapper.xml
+33
-0
DutyPersonController.java
...ot/module/common/biz/controller/DutyPersonController.java
+14
-0
OrgPersonController.java
...oot/module/common/biz/controller/OrgPersonController.java
+14
-0
DutyPersonServiceImpl.java
...module/common/biz/service/impl/DutyPersonServiceImpl.java
+20
-14
FirefightersServiceImpl.java
...dule/common/biz/service/impl/FirefightersServiceImpl.java
+4
-0
OrgUsrServiceImpl.java
...oot/module/common/biz/service/impl/OrgUsrServiceImpl.java
+6
-0
FirefightersController.java
...oot/module/jcs/biz/controller/FirefightersController.java
+19
-0
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/mapper/DutyPersonShiftMapper.java
View file @
2979a0b3
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
api
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.common.api.dto.DutyPersonDto
;
import
com.yeejoin.amos.boot.module.common.api.entity.DutyPersonShift
;
import
com.yeejoin.amos.boot.module.common.api.entity.DutyPersonShift
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
...
@@ -132,4 +133,6 @@ public interface DutyPersonShiftMapper extends BaseMapper<DutyPersonShift> {
...
@@ -132,4 +133,6 @@ public interface DutyPersonShiftMapper extends BaseMapper<DutyPersonShift> {
Map
<
String
,
Object
>
getFireTeamBySequenceNbr
(
long
sequenceNbr
);
Map
<
String
,
Object
>
getFireTeamBySequenceNbr
(
long
sequenceNbr
);
List
<
Map
<
String
,
Object
>>
getFirstAidForTypeCodeAndCompanyId
(
long
company
);
List
<
Map
<
String
,
Object
>>
getFirstAidForTypeCodeAndCompanyId
(
long
company
);
List
<
Map
<
String
,
Object
>>
queryByCompanyId
(
Long
companyId
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/mapper/FirefightersMapper.java
View file @
2979a0b3
...
@@ -36,4 +36,6 @@ public interface FirefightersMapper extends BaseMapper<Firefighters> {
...
@@ -36,4 +36,6 @@ public interface FirefightersMapper extends BaseMapper<Firefighters> {
List
<
FirefightersExcelDto
>
exportToExcel
(
Boolean
isDelete
,
String
name
,
String
postQualification
,
String
fireTeamId
,
List
<
FirefightersExcelDto
>
exportToExcel
(
Boolean
isDelete
,
String
name
,
String
postQualification
,
String
fireTeamId
,
String
state
,
String
areasExpertise
,
String
jobTitle
);
String
state
,
String
areasExpertise
,
String
jobTitle
);
List
<
FirefightersDto
>
queryById
(
Long
teamId
,
String
[]
gw
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/mapper/OrgUsrMapper.java
View file @
2979a0b3
...
@@ -91,4 +91,6 @@ public interface OrgUsrMapper extends BaseMapper<OrgUsr> {
...
@@ -91,4 +91,6 @@ public interface OrgUsrMapper extends BaseMapper<OrgUsr> {
List
<
Map
<
String
,
String
>>
getPersonSimpleDetail
();
List
<
Map
<
String
,
String
>>
getPersonSimpleDetail
();
List
<
Map
<
String
,
Long
>>
countDeptByCompanyId
(
@Param
(
"companyIdList"
)
List
<
String
>
companyIdList
);
List
<
Map
<
String
,
Long
>>
countDeptByCompanyId
(
@Param
(
"companyIdList"
)
List
<
String
>
companyIdList
);
List
<
Map
<
String
,
Object
>>
queryCompanyId
(
Long
id
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/service/IDutyPersonService.java
View file @
2979a0b3
...
@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.common.api.service;
...
@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.common.api.service;
import
com.yeejoin.amos.boot.module.common.api.dto.DutyPersonDto
;
import
com.yeejoin.amos.boot.module.common.api.dto.DutyPersonDto
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* @author DELL
* @author DELL
...
@@ -32,4 +33,6 @@ public interface IDutyPersonService extends IDutyCommonService {
...
@@ -32,4 +33,6 @@ public interface IDutyPersonService extends IDutyCommonService {
* @return
* @return
*/
*/
List
<
DutyPersonDto
>
findByDutyAreaId
(
Long
dutyAreaId
);
List
<
DutyPersonDto
>
findByDutyAreaId
(
Long
dutyAreaId
);
List
<
Map
<
String
,
Object
>>
queryByCompanyId
(
Long
companyId
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/resources/mapper/DutyPersonShiftMapper.xml
View file @
2979a0b3
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
and s.duty_date >= #{beginDate}
and s.duty_date >= #{beginDate}
and s.duty_date
<![CDATA[<=]]>
and s.duty_date
<![CDATA[<=]]>
#{endDate}
#{endDate}
AND s.shift_id is not null
<!--// BUG 2807 更新人员车辆排版值班的保存逻辑 如果没有填写数据则保存空数据 。
AND s.shift_id is not null
<!--// BUG 2807 更新人员车辆排版值班的保存逻辑 如果没有填写数据则保存空数据 。
同步修改 查询 导出相关逻辑 by kongfm 2021-09-14 -->
同步修改 查询 导出相关逻辑 by kongfm 2021-09-14 -->
and s.app_Key = #{appKey}
and s.app_Key = #{appKey}
GROUP BY s.duty_date,s.shift_id
<!--增添分组条件 根据班次分组技术 -->
GROUP BY s.duty_date,s.shift_id
<!--增添分组条件 根据班次分组技术 -->
...
@@ -127,7 +127,7 @@
...
@@ -127,7 +127,7 @@
<if
test=
"params != null and params!='' "
>
<if
test=
"params != null and params!='' "
>
and cd.field_value !='消防车驾驶员'
and cd.field_value !='消防车驾驶员'
</if>
</if>
AND cd.instance_id IN
AND cd.instance_id IN
<foreach
collection =
'instanceIds'
item=
'instanceId'
index=
'index'
open=
"("
close=
")"
separator=
","
>
<foreach
collection =
'instanceIds'
item=
'instanceId'
index=
'index'
open=
"("
close=
")"
separator=
","
>
#{instanceId}
#{instanceId}
</foreach>
</foreach>
...
@@ -150,7 +150,7 @@
...
@@ -150,7 +150,7 @@
cd.FIELD_VALUE
cd.FIELD_VALUE
END
END
) AS #{equipmentName},
) AS #{equipmentName},
MAX(
MAX(
CASE
CASE
WHEN cd.FIELD_CODE = #{teamName} THEN
WHEN cd.FIELD_CODE = #{teamName} THEN
...
@@ -174,7 +174,7 @@
...
@@ -174,7 +174,7 @@
cd.is_delete=0
cd.is_delete=0
group by cd.instance_id
group by cd.instance_id
) result group by ${groupByName}
) result group by ${groupByName}
</select>
</select>
<select
id=
'getInstanceIdForSpecifyDateAndEquipment'
<select
id=
'getInstanceIdForSpecifyDateAndEquipment'
resultType=
'map'
>
resultType=
'map'
>
...
@@ -201,7 +201,7 @@
...
@@ -201,7 +201,7 @@
</select>
</select>
<select
id=
'getEquipmentOperator'
resultType=
'map'
>
<select
id=
'getEquipmentOperator'
resultType=
'map'
>
SELECT
SELECT
result.userName
result.userName
FROM
FROM
(
(
SELECT
SELECT
...
@@ -235,7 +235,7 @@ FROM
...
@@ -235,7 +235,7 @@ FROM
cd.group_code = #{groupCode}
cd.group_code = #{groupCode}
AND cds.instance_id IS NOT NULL
AND cds.instance_id IS NOT NULL
AND cd.is_delete = 0
AND cd.is_delete = 0
AND cd.instance_id IN
AND cd.instance_id IN
<foreach
collection =
'instanceIds'
item=
'instanceId'
index=
'index'
open=
"("
close=
")"
separator=
","
>
<foreach
collection =
'instanceIds'
item=
'instanceId'
index=
'index'
open=
"("
close=
")"
separator=
","
>
#{instanceId}
#{instanceId}
</foreach>
</foreach>
...
@@ -243,8 +243,8 @@ FROM
...
@@ -243,8 +243,8 @@ FROM
WHERE
WHERE
result.postTypeName = #{operator} and result.name =#{duty}
result.postTypeName = #{operator} and result.name =#{duty}
</select>
</select>
<select
id =
'getPositionStaffDutyForSpecifyDate'
resultType=
"map"
>
<select
id =
'getPositionStaffDutyForSpecifyDate'
resultType=
"map"
>
SELECT
SELECT
GROUP_CONCAT(ss.userName) AS userName,
GROUP_CONCAT(ss.userName) AS userName,
...
@@ -294,7 +294,7 @@ WHERE
...
@@ -294,7 +294,7 @@ WHERE
GROUP BY
GROUP BY
ss.postTypeName
ss.postTypeName
</select>
</select>
<select
id=
'getDutyForSpecifyDate'
resultType=
"map"
>
<select
id=
'getDutyForSpecifyDate'
resultType=
"map"
>
SELECT
SELECT
ds.`name`
ds.`name`
...
@@ -307,7 +307,7 @@ AND dp.is_delete = 0
...
@@ -307,7 +307,7 @@ AND dp.is_delete = 0
AND NAME IS NOT NULL
AND NAME IS NOT NULL
GROUP BY
GROUP BY
NAME
NAME
</select>
</select>
<select
id=
'getFireTeamBySequenceNbr'
resultType=
"map"
>
<select
id=
'getFireTeamBySequenceNbr'
resultType=
"map"
>
...
@@ -341,4 +341,26 @@ AND cft.type_code = (
...
@@ -341,4 +341,26 @@ AND cft.type_code = (
AND cft.company = #{company}
AND cft.company = #{company}
</select>
</select>
<select
id=
'queryByCompanyId'
resultType=
"map"
>
SELECT
e.field_code,
e.field_name,
e.field_value
FROM
cb_dynamic_form_instance e,
(SELECT
i.*
FROM
cb_dynamic_form_instance i
,
(SELECT * FROM `cb_duty_person_shift` where to_days(duty_date) = to_days(now())) b
WHERE
i.instance_id = b.instance_id
AND
i.field_code = 'deptId'
AND
i.field_value = #{companyId}) c
WHERE
e. instance_id = c.instance_id
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/resources/mapper/FirefightersMapper.xml
View file @
2979a0b3
<?xml version="1.0" encoding="UTF-8"?>
<?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">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
<mapper
namespace=
"com.yeejoin.amos.boot.module.common.api.mapper.FirefightersMapper"
>
namespace=
"com.yeejoin.amos.boot.module.common.api.mapper.FirefightersMapper"
>
<select
id=
"getFirefightersJobTitleCount"
<select
id=
"getFirefightersJobTitleCount"
resultType=
"com.yeejoin.amos.boot.biz.common.utils.FirefightersTreeDto"
>
resultType=
"com.yeejoin.amos.boot.biz.common.utils.FirefightersTreeDto"
>
select COUNT(a.sequence_nbr) num, a.job_title_code
select COUNT(a.sequence_nbr) num,
jobTitleCode
a.job_title_code
from cb_firefighters a
jobTitleCode
where a.is_delete = 0
from cb_firefighters a
GROUP BY
where a.is_delete = 0
a.job_title_code
GROUP BY a.job_title_code
</select>
</select>
<!--消防队员列表按时间倒叙排列add desc 2021-09-08 by kongfm -->
<!--消防队员列表按时间倒叙排列add desc 2021-09-08 by kongfm -->
<select
id=
"getFirefighters"
<select
id=
"getFirefighters"
resultType=
"com.yeejoin.amos.boot.module.common.api.dto.FirefightersZhDto"
>
resultType=
"com.yeejoin.amos.boot.module.common.api.dto.FirefightersZhDto"
>
select a.*,b.areas_expertise areasExpertise ,b.areas_expertise_code
select a.*,b.areas_expertise areasExpertise ,b.areas_expertise_code
areasExpertiseCode from cb_firefighters a LEFT JOIN
areasExpertiseCode from cb_firefighters a LEFT JOIN
cb_firefighters_post b on
cb_firefighters_post b on
a.sequence_nbr=b.firefighters_id where
a.sequence_nbr=b.firefighters_id where
a.is_delete=0
a.is_delete=0
<if
test=
'par.postQualification!=null'
>
and b.post_qualification_code = #{par.postQualification}
</if>
<if
test=
'par.postQualification!=null'
>
and b.post_qualification_code = #{par.postQualification}
</if>
<if
test=
'par.areasExpertise!=null'
>
and b.areas_expertise_code= #{par.areasExpertise}
</if>
<if
test=
'par.areasExpertise!=null'
>
and b.areas_expertise_code= #{par.areasExpertise}
</if>
<if
test=
'par.name!=null'
>
and a.name like concat ('%',#{par.name},'%')
</if>
<if
test=
'par.name!=null'
>
and a.name like concat ('%',#{par.name},'%')
</if>
<if
test=
'par.state!=null'
>
and a.state_code= #{par.state}
</if>
<if
test=
'par.state!=null'
>
and a.state_code= #{par.state}
</if>
<if
test=
'par.fireTeamId!=null'
>
and a.fire_team_id= #{par.fireTeamId}
</if>
<if
test=
'par.fireTeamId!=null'
>
and a.fire_team_id= #{par.fireTeamId}
</if>
<if
test=
'par.jobTitle!=null'
>
and a.job_title_code =#{par.jobTitle}
</if>
<if
test=
'par.jobTitle!=null'
>
and a.job_title_code =#{par.jobTitle}
</if>
<if
<if
test=
'par.areasExpertiseCode!=null and par.areasExpertiseCode!="0"'
>
and b.areas_expertise_code =#{par.areasExpertiseCode}
</if>
test=
'par.areasExpertiseCode!=null and par.areasExpertiseCode!="0"'
>
and b.areas_expertise_code
<if
test=
'par.areasExpertiseCode=="0"'
>
and b.areas_expertise_code is not null
</if>
=#{par.areasExpertiseCode}
ORDER BY a.rec_date desc limit #{pageNum},#{pageSize}
</if>
</select>
<if
test=
'par.areasExpertiseCode=="0"'
>
and b.areas_expertise_code is not null
</if>
<!--消防队员列表按时间倒叙排列add desc 2021-09-08 by kongfm -->
ORDER BY a.rec_date desc limit #{pageNum},#{pageSize}
<select
id=
"getFirefightersCount"
resultType=
"Map"
>
</select>
select COUNT(a.sequence_nbr) num from cb_firefighters a LEFT JOIN
<!--消防队员列表按时间倒叙排列add desc 2021-09-08 by kongfm -->
cb_firefighters_post b on a.sequence_nbr=b.firefighters_id where
<select
id=
"getFirefightersCount"
resultType=
"Map"
>
a.is_delete=0
select COUNT(a.sequence_nbr) num from cb_firefighters a LEFT JOIN
<if
test=
'par.postQualification!=null'
>
and b.post_qualification_code = #{par.postQualification}
</if>
cb_firefighters_post b on a.sequence_nbr=b.firefighters_id where
<if
test=
'par.areasExpertise!=null'
>
and b.areas_expertise_code= #{par.areasExpertise}
</if>
a.is_delete=0
<if
test=
'par.name!=null'
>
and a.name like concat ('%',#{par.name},'%')
</if>
<if
test=
'par.postQualification!=null'
>
and b.post_qualification_code = #{par.postQualification}
</if>
<if
test=
'par.state!=null'
>
and a.state_code= #{par.state}
</if>
<if
test=
'par.areasExpertise!=null'
>
and b.areas_expertise_code= #{par.areasExpertise}
</if>
<if
test=
'par.fireTeamId!=null'
>
and a.fire_team_id= #{par.fireTeamId}
</if>
<if
test=
'par.name!=null'
>
and a.name like concat ('%',#{par.name},'%')
</if>
<if
test=
'par.jobTitle!=null'
>
and a.job_title_code =#{par.jobTitle}
</if>
<if
test=
'par.state!=null'
>
and a.state_code= #{par.state}
</if>
<if
<if
test=
'par.fireTeamId!=null'
>
and a.fire_team_id= #{par.fireTeamId}
</if>
test=
'par.areasExpertiseCode!=null and par.areasExpertiseCode!="0"'
>
and b.areas_expertise_code =#{par.areasExpertiseCode}
</if>
<if
test=
'par.jobTitle!=null'
>
and a.job_title_code =#{par.jobTitle}
</if>
<if
test=
'par.areasExpertiseCode=="0"'
>
and b.areas_expertise_code is not null
</if>
<if
test=
'par.areasExpertiseCode!=null and par.areasExpertiseCode!="0"'
>
and b.areas_expertise_code
=#{par.areasExpertiseCode}
</if>
<if
test=
'par.areasExpertiseCode=="0"'
>
and b.areas_expertise_code is not null
</if>
ORDER BY a.rec_date desc
ORDER BY a.rec_date desc
</select>
</select>
<select
id=
"listToSelectById"
resultType=
"Map"
>
<select
id=
"listToSelectById"
resultType=
"Map"
>
SELECT
SELECT IFNULL(a.personnel_photos, '') personnelPhotos,
IFNULL(a.personnel_photos, '') personnelPhotos,
a.sequence_nbr
a.sequence_nbr
sequenceNbr,
sequenceNbr,
IFNULL(a.`name`, '无') `name`,
IFNULL(a.`name`, '无') `name`,
IFNULL(a.job_title, '无')
IFNULL(a.job_title, '无')
jobTitle,
jobTitle,
IFNULL(b.administrative_position, '无')
IFNULL(b.administrative_position, '无')
administrativePosition,
administrativePosition,
IFNULL(c.`name`, '无') fireTeamName,
IFNULL(c.`name`, '无') fireTeamName,
IFNULL(a.state, '无') state,
IFNULL(a.state, '无') state,
IFNULL(b.employee_hierarchy, '无')
IFNULL(b.employee_hierarchy, '无')
employeeHierarchy,
employeeHierarchy,
IFNULL(b.areas_expertise, '无') areasExpertise,
IFNULL(b.areas_expertise, '无') areasExpertise,
IFNULL(a.gender, '无') gender,
IFNULL(a.gender, '无') gender,
IFNULL(b.post_qualification, '无')
IFNULL(b.post_qualification, '无')
postQualification, year ( from_days( datediff( now( ),
postQualification, year ( from_days( datediff( now( ),
a.birthday_time))) age
a.birthday_time))) age
FROM cb_firefighters a LEFT JOIN
FROM cb_firefighters a LEFT JOIN
cb_firefighters_post b
cb_firefighters_post b
ON a.sequence_nbr
ON a.sequence_nbr
= b.firefighters_id LEFT JOIN
= b.firefighters_id LEFT JOIN
cb_fire_team c on
cb_fire_team c on
c.sequence_nbr=a.fire_team_id
c.sequence_nbr=a.fire_team_id
WHERE a.is_delete =0
WHERE a.is_delete =0
and
and
a.sequence_nbr=#{id}
a.sequence_nbr=#{id}
</select>
</select>
<!-- BUG3553 BY kongfm 人员关系显示汉字 -->
<!-- BUG3553 BY kongfm 人员关系显示汉字 -->
<!---陈浩修改导出的数据量 2021-09-13-->
<!---陈浩修改导出的数据量 2021-09-13-->
<select
id=
"exportToExcel"
<select
id=
"exportToExcel"
resultType=
"com.yeejoin.amos.boot.module.common.api.dto.FirefightersExcelDto"
>
resultType=
"com.yeejoin.amos.boot.module.common.api.dto.FirefightersExcelDto"
>
<!-- SELECT f.*, ( SELECT cb_fire_team.NAME FROM cb_fire_team WHERE cb_fire_team.sequence_nbr
<!-- SELECT f.*, ( SELECT cb_fire_team.NAME FROM cb_fire_team WHERE cb_fire_team.sequence_nbr
= f.fire_team_id ) fireTeam, emergency_contact, da.NAME AS relationship,
= f.fire_team_id ) fireTeam, emergency_contact, da.NAME AS relationship,
emergency_contact_phone FROM cb_firefighters f LEFT JOIN cb_firefighters_contacts
emergency_contact_phone FROM cb_firefighters f LEFT JOIN cb_firefighters_contacts
fc ON f.sequence_nbr = fc.firefighters_id left join cb_data_dictionary da
fc ON f.sequence_nbr = fc.firefighters_id left join cb_data_dictionary da
on da.CODE = fc.relationship where f.is_delete = #{isDelete} -->
on da.CODE = fc.relationship where f.is_delete = #{isDelete} -->
SELECT
SELECT
f.*,
f.*,
(
(
SELECT
SELECT
cb_fire_team. NAME
cb_fire_team. NAME
FROM
FROM
cb_fire_team
cb_fire_team
WHERE
WHERE
cb_fire_team.sequence_nbr = f.fire_team_id
cb_fire_team.sequence_nbr = f.fire_team_id
) fireTeam,
) fireTeam,
emergency_contact,
emergency_contact,
(
(
SELECT
SELECT
NAME
NAME
FROM
FROM
cb_data_dictionary
cb_data_dictionary
WHERE
WHERE
CODE = fc.relationship
CODE = fc.relationship
AND type = 'RJGX'
AND type = 'RJGX'
) AS relationship,
) AS relationship,
emergency_contact_phone,
emergency_contact_phone,
fw.working_hours,
fw.working_hours,
fw.fire_working_hours,
fw.fire_working_hours,
(
(
SELECT
SELECT
NAME
NAME
FROM
FROM
cb_data_dictionary
cb_data_dictionary
WHERE
WHERE
CODE = fe.first_degree
CODE = fe.first_degree
AND type = 'XLLX'
AND type = 'XLLX'
) AS first_degree,
) AS first_degree,
(
(
SELECT
SELECT
NAME
NAME
FROM
FROM
cb_data_dictionary
cb_data_dictionary
WHERE
WHERE
CODE = fe.highest_education
CODE = fe.highest_education
AND type = 'XLLX'
AND type = 'XLLX'
) AS highest_education,
) AS highest_education,
(
(
SELECT
SELECT
NAME
NAME
FROM
FROM
cb_data_dictionary
cb_data_dictionary
WHERE
WHERE
CODE = fe.academic_degree
CODE = fe.academic_degree
AND type = 'XWLX'
AND type = 'XWLX'
) AS academic_degree,
) AS academic_degree,
fe.school,
fe.school,
fe.professional_name,
fe.professional_name,
fp.*
fp.*
FROM
FROM
cb_firefighters f
cb_firefighters f
LEFT JOIN cb_firefighters_contacts fc ON f.sequence_nbr = fc.firefighters_id
LEFT JOIN cb_firefighters_contacts fc ON f.sequence_nbr = fc.firefighters_id
LEFT JOIN cb_firefighters_workexperience fw ON f.sequence_nbr = fw.firefighters_id
LEFT JOIN cb_firefighters_workexperience fw ON f.sequence_nbr = fw.firefighters_id
LEFT JOIN cb_firefighters_education fe ON f.sequence_nbr = fe.firefighters_id
LEFT JOIN cb_firefighters_education fe ON f.sequence_nbr = fe.firefighters_id
LEFT JOIN cb_firefighters_post fp ON f.sequence_nbr = fp.firefighters_id
LEFT JOIN cb_firefighters_post fp ON f.sequence_nbr = fp.firefighters_id
WHERE
WHERE
f.is_delete = 0
f.is_delete = 0
<if
test=
"name!=null and name !='-1' and name !=''"
>
and f.`name` like concat('%',#{name},'%')
</if>
<if
test=
"name!=null and name !='-1' and name !=''"
>
and f.`name` like concat('%',#{name},'%')
</if>
<if
test=
'postQualification!=null'
>
and fp.post_qualification_code
= #{postQualification}
</if>
<if
test=
'postQualification!=null'
>
and fp.post_qualification_code
= #{postQualification}
</if>
<if
test=
'fireTeamId !=null'
>
and f.fire_team_id = #{fireTeamId}
</if>
<if
test=
'fireTeamId !=null'
>
and f.fire_team_id = #{fireTeamId}
</if>
<if
test=
'state !=null'
>
and f.state_code = #{state}
</if>
<if
test=
'state !=null'
>
and f.state_code = #{state}
</if>
<if
test=
'areasExpertise!=null'
>
and fp.areas_expertise_code = #{areasExpertise}
</if>
<if
test=
'areasExpertise!=null'
>
and fp.areas_expertise_code = #{areasExpertise}
</if>
<if
test=
'jobTitle!=null'
>
and f.job_title_code = #{jobTitle}
</if>
<if
test=
'jobTitle!=null'
>
and f.job_title_code = #{jobTitle}
</if>
</select>
</select>
<select
id=
"getFirefightersName"
resultType=
"Map"
>
<select
id=
"getFirefightersName"
resultType=
"Map"
>
SELECT
SELECT cb_firefighters.name AS name,
cb_firefighters.name AS name,
IFNULL(cb_firefighters.mobile_phone, '') AS phone
IFNULL(cb_firefighters.mobile_phone, '') AS phone
FROM cb_firefighters
FROM
WHERE cb_firefighters.is_delete = 0
cb_firefighters
AND cb_firefighters.name IS NOT NULL
WHERE
AND cb_firefighters.name != ''
cb_firefighters.is_delete = 0 AND
group by cb_firefighters.name
cb_firefighters.name IS NOT NULL AND
</select>
cb_firefighters.name != ''
group by cb_firefighters.name
<select
id=
"queryById"
resultType=
"com.yeejoin.amos.boot.module.common.api.dto.FirefightersDto"
>
</select>
SELECT
*
FROM
cb_firefighters
WHERE
fire_team_id = #{teamId}
<if
test=
"gw != null"
>
And job_title_code In
<foreach
item=
"item"
collection=
"gw"
index=
"index"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</if>
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/resources/mapper/OrgUsrMapper.xml
View file @
2979a0b3
...
@@ -685,4 +685,37 @@ LEFT JOIN (
...
@@ -685,4 +685,37 @@ LEFT JOIN (
#{companyId}
#{companyId}
</foreach>
</foreach>
</select>
</select>
<select
id=
"queryCompanyId"
resultType=
"map"
>
SELECT
d.field_code ,
d.field_name ,
d.field_value ,
s.sequence_nbr,
s.biz_org_name,
s.parent_id
FROM
cb_dynamic_form_instance d ,
( SELECT
u.*
FROM
cb_org_usr u,
cb_dynamic_form_instance i
where
u.parent_id = #{id}
AND
u.is_delete = 0
AND
u.biz_org_type = 'PERSON'
AND
i.instance_id = u.sequence_nbr
AND
i.field_code = 'administrativePositionCode'
AND
i.field_value is not NULL ) s
WHERE
d.instance_id = s.sequence_nbr
AND
d.field_code = 'telephone'
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/controller/DutyPersonController.java
View file @
2979a0b3
...
@@ -191,4 +191,18 @@ public class DutyPersonController extends BaseController {
...
@@ -191,4 +191,18 @@ public class DutyPersonController extends BaseController {
return
ResponseHelper
.
buildResponse
(
iDutyPersonService
.
findByDutyAreaId
(
dutyAreaId
));
return
ResponseHelper
.
buildResponse
(
iDutyPersonService
.
findByDutyAreaId
(
dutyAreaId
));
}
}
/**
*
*
* @return ResponseModel
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/companyId/{companyId}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询当日值班人员"
,
notes
=
"查询当日值班人员"
)
public
ResponseModel
<
List
<
Map
<
String
,
Object
>>>
queryByCompanyId
(
@PathVariable
Long
companyId
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
iDutyPersonService
.
queryByCompanyId
(
companyId
));
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/controller/OrgPersonController.java
View file @
2979a0b3
...
@@ -267,4 +267,18 @@ public class OrgPersonController {
...
@@ -267,4 +267,18 @@ public class OrgPersonController {
throw
new
RuntimeException
(
"系统异常!"
);
throw
new
RuntimeException
(
"系统异常!"
);
}
}
}
}
/**
* 机场单位下 各单位下人员岗位不为空的人员
*
* @param id
* @return
*/
@TycloudOperation
(
needAuth
=
false
,
ApiLevel
=
UserType
.
AGENCY
)
@RequestMapping
(
value
=
"/companyId/{id}"
,
method
=
RequestMethod
.
GET
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"获取人员岗位不为空的人员详情"
,
notes
=
"获取人员岗位不为空的人员详情"
)
public
ResponseModel
<
Object
>
queryCompanyId
(
HttpServletRequest
request
,
@PathVariable
Long
id
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
iOrgUsrService
.
queryCompanyId
(
id
));
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/DutyPersonServiceImpl.java
View file @
2979a0b3
...
@@ -10,6 +10,7 @@ import java.util.Map;
...
@@ -10,6 +10,7 @@ import java.util.Map;
import
java.util.Set
;
import
java.util.Set
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
import
com.yeejoin.amos.boot.module.common.api.mapper.DutyPersonShiftMapper
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
@@ -37,6 +38,8 @@ public class DutyPersonServiceImpl extends DutyCommonServiceImpl implements IDut
...
@@ -37,6 +38,8 @@ public class DutyPersonServiceImpl extends DutyCommonServiceImpl implements IDut
@Autowired
@Autowired
EquipFeignClient
equipFeign
;
EquipFeignClient
equipFeign
;
@Autowired
DutyPersonShiftMapper
dutyPersonShiftMapper
;
@Override
@Override
...
@@ -289,26 +292,29 @@ public Object BuildScheduleDetails(String dutyDay, Long shiftId, String postType
...
@@ -289,26 +292,29 @@ public Object BuildScheduleDetails(String dutyDay, Long shiftId, String postType
System
.
out
.
println
(
"ssssssssss"
);
System
.
out
.
println
(
"ssssssssss"
);
});
});
}
}
public
List
<
Map
<
String
,
Object
>>
queryByCompanyId
(
Long
companyId
){
return
dutyPersonShiftMapper
.
queryByCompanyId
(
companyId
);
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/FirefightersServiceImpl.java
View file @
2979a0b3
...
@@ -129,7 +129,11 @@ public class FirefightersServiceImpl extends BaseService<FirefightersDto, Firefi
...
@@ -129,7 +129,11 @@ public class FirefightersServiceImpl extends BaseService<FirefightersDto, Firefi
public
List
<
Map
<
String
,
String
>>
getFirefightersName
()
{
public
List
<
Map
<
String
,
String
>>
getFirefightersName
()
{
return
firefightersMapper
.
getFirefightersName
();
return
firefightersMapper
.
getFirefightersName
();
}
public
List
<
FirefightersDto
>
queryById
(
Long
teamId
,
String
[]
gw
){
return
firefightersMapper
.
queryById
(
teamId
,
gw
);
}
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/OrgUsrServiceImpl.java
View file @
2979a0b3
...
@@ -1859,4 +1859,10 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
...
@@ -1859,4 +1859,10 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
return
resultMap
;
return
resultMap
;
}
}
public
List
<
Map
<
String
,
Object
>>
queryCompanyId
(
Long
id
)
{
return
orgUsrMapper
.
queryCompanyId
(
id
);
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-jcs-biz/src/main/java/com/yeejoin/amos/boot/module/jcs/biz/controller/FirefightersController.java
View file @
2979a0b3
...
@@ -94,6 +94,7 @@ public class FirefightersController extends BaseController {
...
@@ -94,6 +94,7 @@ public class FirefightersController extends BaseController {
@Value
(
"${redis.cache.failure.time}"
)
@Value
(
"${redis.cache.failure.time}"
)
private
long
time
;
private
long
time
;
/**
/**
* 新增消防队员
* 新增消防队员
*
*
...
@@ -332,4 +333,22 @@ public class FirefightersController extends BaseController {
...
@@ -332,4 +333,22 @@ public class FirefightersController extends BaseController {
return
ResponseHelper
.
buildResponse
(
menus
);
return
ResponseHelper
.
buildResponse
(
menus
);
}
}
/**
*查询
*
* @param
* @return
* @throws Exception
*/
@TycloudOperation
(
needAuth
=
true
,
ApiLevel
=
UserType
.
AGENCY
)
@RequestMapping
(
value
=
"/gw/{id}"
,
method
=
RequestMethod
.
GET
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据id查询"
,
notes
=
"根据id查询"
)
public
ResponseModel
<
Object
>
queryById
(
@PathVariable
Long
teamId
)
throws
Exception
{
//规则提供岗位名称
String
[]
gw
=
new
String
[]{
"1202"
,
"1203"
,
"1204"
,
"1205"
,
"1206"
,
"1207"
,
"1209"
,
"1208"
,
"1210"
,
"1211"
};
return
ResponseHelper
.
buildResponse
(
iFirefightersService
.
queryById
(
teamId
,
gw
));
}
}
}
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