Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
long-tern-care-service
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
hubin
long-tern-care-service
Commits
35ca55cb
Commit
35ca55cb
authored
Apr 22, 2021
by
蔡镇泽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
通过报告id查询评定报告人员信息
parent
63252d71
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
24 deletions
+47
-24
TaskController.java
...main/java/com/hungraim/ltc/controller/TaskController.java
+14
-2
AprPersonInfoMapper.java
...c/main/java/com/hungraim/ltc/dao/AprPersonInfoMapper.java
+1
-1
TaskService.java
...e/src/main/java/com/hungraim/ltc/service/TaskService.java
+3
-0
TaskServiceImpl.java
...n/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
+19
-11
ChDisableEvaluateMapper.xml
...ice/src/main/resources/mapper/ChDisableEvaluateMapper.xml
+10
-10
No files found.
assessment/assessment-service/src/main/java/com/hungraim/ltc/controller/TaskController.java
View file @
35ca55cb
package
com
.
hungraim
.
ltc
.
controller
;
package
com
.
hungraim
.
ltc
.
controller
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprPersonInfo
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.vo.assessment.AprEmpVO
;
import
com.hungraim.ltc.pojo.vo.assessment.AprEmpVO
;
import
com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO
;
import
com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO
;
...
@@ -82,6 +83,17 @@ public class TaskController {
...
@@ -82,6 +83,17 @@ public class TaskController {
}
}
/**
/**
* 通过报告id查询评定报告人员信息
*
* @param reportId 评定报告id
*/
@RequestMapping
(
"/personInfoList"
)
public
Result
<
List
<
ChAprPersonInfo
>>
personInfoList
(
String
reportId
)
{
List
<
ChAprPersonInfo
>
list
=
taskService
.
personInfoList
(
reportId
);
return
Result
.
success
(
list
);
}
/**
* 查询评定人员列表
* 查询评定人员列表
*
*
* @param organName 评定机构名称
* @param organName 评定机构名称
...
@@ -91,8 +103,8 @@ public class TaskController {
...
@@ -91,8 +103,8 @@ public class TaskController {
*/
*/
@RequestMapping
(
"/aprEmpList"
)
@RequestMapping
(
"/aprEmpList"
)
public
Result
<
List
<
AprEmpVO
>>
aprEmpList
(
String
organName
,
String
name
,
String
tel
,
String
groupLeader
)
{
public
Result
<
List
<
AprEmpVO
>>
aprEmpList
(
String
organName
,
String
name
,
String
tel
,
String
groupLeader
)
{
List
<
AprEmpVO
>
aprEmp
VO
S
=
taskService
.
aprEmpList
(
organName
,
name
,
tel
,
groupLeader
);
List
<
AprEmpVO
>
aprEmpS
=
taskService
.
aprEmpList
(
organName
,
name
,
tel
,
groupLeader
);
return
Result
.
success
(
aprEmp
VO
S
);
return
Result
.
success
(
aprEmpS
);
}
}
/**
/**
...
...
assessment/assessment-service/src/main/java/com/hungraim/ltc/dao/AprPeronInfoMapper.java
→
assessment/assessment-service/src/main/java/com/hungraim/ltc/dao/AprPer
s
onInfoMapper.java
View file @
35ca55cb
...
@@ -10,5 +10,5 @@ import org.springframework.stereotype.Repository;
...
@@ -10,5 +10,5 @@ import org.springframework.stereotype.Repository;
*/
*/
@Mapper
@Mapper
@Repository
@Repository
public
interface
AprPeronInfoMapper
extends
BaseMapper
<
ChAprPersonInfo
>
{
public
interface
AprPer
s
onInfoMapper
extends
BaseMapper
<
ChAprPersonInfo
>
{
}
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/TaskService.java
View file @
35ca55cb
package
com
.
hungraim
.
ltc
.
service
;
package
com
.
hungraim
.
ltc
.
service
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprPersonInfo
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.vo.assessment.AprEmpVO
;
import
com.hungraim.ltc.pojo.vo.assessment.AprEmpVO
;
import
com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO
;
import
com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO
;
...
@@ -65,4 +66,6 @@ public interface TaskService {
...
@@ -65,4 +66,6 @@ public interface TaskService {
Result
<
Object
>
taskGroup
(
Integer
pushId
,
Integer
status
);
Result
<
Object
>
taskGroup
(
Integer
pushId
,
Integer
status
);
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
();
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
();
List
<
ChAprPersonInfo
>
personInfoList
(
String
reportId
);
}
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
View file @
35ca55cb
...
@@ -36,7 +36,7 @@ public class TaskServiceImpl implements TaskService {
...
@@ -36,7 +36,7 @@ public class TaskServiceImpl implements TaskService {
@Autowired
@Autowired
private
TaskEmpMapper
taskEmpMapper
;
private
TaskEmpMapper
taskEmpMapper
;
@Autowired
@Autowired
private
AprPer
onInfoMapper
per
onInfoMapper
;
private
AprPer
sonInfoMapper
pers
onInfoMapper
;
@Autowired
@Autowired
private
TaskPushMapper
taskPushMapper
;
private
TaskPushMapper
taskPushMapper
;
@Autowired
@Autowired
...
@@ -81,20 +81,20 @@ public class TaskServiceImpl implements TaskService {
...
@@ -81,20 +81,20 @@ public class TaskServiceImpl implements TaskService {
person1Info
.
setReportId
(
report
.
getReportId
());
person1Info
.
setReportId
(
report
.
getReportId
());
person1Info
.
setEmpId
(
person1
);
person1Info
.
setEmpId
(
person1
);
person1Info
.
setFcd
(
new
Date
());
person1Info
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
person1Info
);
per
s
onInfoMapper
.
insert
(
person1Info
);
if
(
person2
!=
null
)
{
if
(
person2
!=
null
)
{
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
personInfo
.
setReportId
(
report
.
getReportId
());
personInfo
.
setReportId
(
report
.
getReportId
());
personInfo
.
setEmpId
(
person1
);
personInfo
.
setEmpId
(
person1
);
personInfo
.
setFcd
(
new
Date
());
personInfo
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
personInfo
);
per
s
onInfoMapper
.
insert
(
personInfo
);
}
}
if
(
person3
!=
null
)
{
if
(
person3
!=
null
)
{
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
personInfo
.
setReportId
(
report
.
getReportId
());
personInfo
.
setReportId
(
report
.
getReportId
());
personInfo
.
setEmpId
(
person1
);
personInfo
.
setEmpId
(
person1
);
personInfo
.
setFcd
(
new
Date
());
personInfo
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
personInfo
);
per
s
onInfoMapper
.
insert
(
personInfo
);
}
}
}
}
...
@@ -108,44 +108,44 @@ public class TaskServiceImpl implements TaskService {
...
@@ -108,44 +108,44 @@ public class TaskServiceImpl implements TaskService {
chAprReport
.
setEvaluateTime
(
evaluateDate
);
chAprReport
.
setEvaluateTime
(
evaluateDate
);
aprReportMapper
.
updateById
(
chAprReport
);
aprReportMapper
.
updateById
(
chAprReport
);
//修改鉴定报告人员(有就update,没有就insert)
//修改鉴定报告人员(有就update,没有就insert)
List
<
ChAprPersonInfo
>
personInfos
=
peronInfoMapper
.
selectList
(
new
QueryWrapper
<
ChAprPersonInfo
>().
eq
(
"report_id"
,
reportId
));
List
<
ChAprPersonInfo
>
personInfos
=
per
s
onInfoMapper
.
selectList
(
new
QueryWrapper
<
ChAprPersonInfo
>().
eq
(
"report_id"
,
reportId
));
if
(
person1
!=
null
)
{
if
(
person1
!=
null
)
{
if
(
personInfos
.
size
()
>=
1
)
{
if
(
personInfos
.
size
()
>=
1
)
{
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
personInfo
.
setEmpId
(
person1
);
personInfo
.
setEmpId
(
person1
);
peronInfoMapper
.
updateById
(
personInfo
);
per
s
onInfoMapper
.
updateById
(
personInfo
);
}
else
{
}
else
{
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setEmpId
(
person1
);
personInfo
.
setEmpId
(
person1
);
personInfo
.
setFcd
(
new
Date
());
personInfo
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
personInfo
);
per
s
onInfoMapper
.
insert
(
personInfo
);
}
}
}
}
if
(
person2
!=
null
)
{
if
(
person2
!=
null
)
{
if
(
personInfos
.
size
()
>=
2
)
{
if
(
personInfos
.
size
()
>=
2
)
{
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
personInfo
.
setEmpId
(
person2
);
personInfo
.
setEmpId
(
person2
);
peronInfoMapper
.
updateById
(
personInfo
);
per
s
onInfoMapper
.
updateById
(
personInfo
);
}
else
{
}
else
{
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setEmpId
(
person2
);
personInfo
.
setEmpId
(
person2
);
personInfo
.
setFcd
(
new
Date
());
personInfo
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
personInfo
);
per
s
onInfoMapper
.
insert
(
personInfo
);
}
}
}
}
if
(
person3
!=
null
)
{
if
(
person3
!=
null
)
{
if
(
personInfos
.
size
()
>=
3
)
{
if
(
personInfos
.
size
()
>=
3
)
{
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
ChAprPersonInfo
personInfo
=
personInfos
.
get
(
0
);
personInfo
.
setEmpId
(
person3
);
personInfo
.
setEmpId
(
person3
);
peronInfoMapper
.
updateById
(
personInfo
);
per
s
onInfoMapper
.
updateById
(
personInfo
);
}
else
{
}
else
{
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
ChAprPersonInfo
personInfo
=
new
ChAprPersonInfo
();
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setReportId
(
chAprReport
.
getReportId
());
personInfo
.
setEmpId
(
person3
);
personInfo
.
setEmpId
(
person3
);
personInfo
.
setFcd
(
new
Date
());
personInfo
.
setFcd
(
new
Date
());
peronInfoMapper
.
insert
(
personInfo
);
per
s
onInfoMapper
.
insert
(
personInfo
);
}
}
}
}
}
}
...
@@ -158,12 +158,14 @@ public class TaskServiceImpl implements TaskService {
...
@@ -158,12 +158,14 @@ public class TaskServiceImpl implements TaskService {
return
Result
.
failed
(
"评定人员必须是组长!"
);
return
Result
.
failed
(
"评定人员必须是组长!"
);
}
}
String
[]
taskIds
=
taskId
.
split
(
","
);
String
[]
taskIds
=
taskId
.
split
(
","
);
Date
assignTime
=
new
Date
();
//任务分配日期
for
(
String
id
:
taskIds
)
{
for
(
String
id
:
taskIds
)
{
ChAprTask
task
=
taskMapper
.
selectById
(
id
);
ChAprTask
task
=
taskMapper
.
selectById
(
id
);
if
(
task
==
null
)
{
if
(
task
==
null
)
{
return
Result
.
failed
(
"无效的taskId!"
);
return
Result
.
failed
(
"无效的taskId!"
);
}
}
task
.
setAprEmpId
(
empId
);
task
.
setAprEmpId
(
empId
);
task
.
setAssignTime
(
assignTime
);
int
count
=
taskMapper
.
updateById
(
task
);
int
count
=
taskMapper
.
updateById
(
task
);
if
(
count
!=
1
)
{
if
(
count
!=
1
)
{
return
Result
.
failed
(
"修改失败!"
);
return
Result
.
failed
(
"修改失败!"
);
...
@@ -201,4 +203,9 @@ public class TaskServiceImpl implements TaskService {
...
@@ -201,4 +203,9 @@ public class TaskServiceImpl implements TaskService {
public
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
()
{
public
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
()
{
return
cfgSrvDisableLevelMapper
.
selectList
(
new
QueryWrapper
<>());
return
cfgSrvDisableLevelMapper
.
selectList
(
new
QueryWrapper
<>());
}
}
@Override
public
List
<
ChAprPersonInfo
>
personInfoList
(
String
reportId
)
{
return
personInfoMapper
.
selectList
(
new
QueryWrapper
<
ChAprPersonInfo
>().
eq
(
"report_id"
,
reportId
));
}
}
}
\ No newline at end of file
assessment/assessment-service/src/main/resources/mapper/ChDisableEvaluateMapper.xml
View file @
35ca55cb
...
@@ -113,13 +113,13 @@
...
@@ -113,13 +113,13 @@
LEFT JOIN CH_APR_ORGAN organ ON task.APR_ORGAN_ID = organ.APR_ORGAN_ID
LEFT JOIN CH_APR_ORGAN organ ON task.APR_ORGAN_ID = organ.APR_ORGAN_ID
LEFT JOIN CH_DISABLE_RISK_LEVEL lev ON report.DISABLE_LEVEL_ID = lev.DISA_RISK_LEVEL_ID
LEFT JOIN CH_DISABLE_RISK_LEVEL lev ON report.DISABLE_LEVEL_ID = lev.DISA_RISK_LEVEL_ID
<where>
<where>
<if
test=
"name != null and name
=
= ''"
>
<if
test=
"name != null and name
!
= ''"
>
and info.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
and info.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
</if>
</if>
<if
test=
"certiCode != null and certiCode
=
= ''"
>
<if
test=
"certiCode != null and certiCode
!
= ''"
>
and info.CERTI_CODE = #{certiCode}
and info.CERTI_CODE = #{certiCode}
</if>
</if>
<if
test=
"tel != null and tel
=
= ''"
>
<if
test=
"tel != null and tel
!
= ''"
>
and info.tel = #{tel}
and info.tel = #{tel}
</if>
</if>
</where>
</where>
...
@@ -145,13 +145,13 @@
...
@@ -145,13 +145,13 @@
LEFT JOIN ch_apr_emp emp on task.apr_emp_id = emp.emp_id
LEFT JOIN ch_apr_emp emp on task.apr_emp_id = emp.emp_id
LEFT JOIN CH_APR_ORGAN emp_organ on emp.apr_organ_id = emp_organ.apr_organ_id
LEFT JOIN CH_APR_ORGAN emp_organ on emp.apr_organ_id = emp_organ.apr_organ_id
<where>
<where>
<if
test=
"name != null and name
=
= ''"
>
<if
test=
"name != null and name
!
= ''"
>
and emp.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
and emp.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
</if>
</if>
<if
test=
"certiCode != null and certiCode
=
= ''"
>
<if
test=
"certiCode != null and certiCode
!
= ''"
>
and emp.CERTI_CODE = #{certiCode}
and emp.CERTI_CODE = #{certiCode}
</if>
</if>
<if
test=
"tel != null and tel
=
= ''"
>
<if
test=
"tel != null and tel
!
= ''"
>
and emp.tel = #{tel}
and emp.tel = #{tel}
</if>
</if>
</where>
</where>
...
@@ -176,16 +176,16 @@
...
@@ -176,16 +176,16 @@
LEFT JOIN ch_apr_organ organ ON emp.apr_organ_id = organ.apr_organ_id
LEFT JOIN ch_apr_organ organ ON emp.apr_organ_id = organ.apr_organ_id
LEFT JOIN ch_srv_organ srvOrgan ON organ.organ_id = srvOrgan.srv_organ_id
LEFT JOIN ch_srv_organ srvOrgan ON organ.organ_id = srvOrgan.srv_organ_id
<where>
<where>
<if
test=
"organName != null and organName
=
= ''"
>
<if
test=
"organName != null and organName
!
= ''"
>
and organ.organ_name like CONCAT(CONCAT('%',#{organName}) ,'%')
and organ.organ_name like CONCAT(CONCAT('%',#{organName}) ,'%')
</if>
</if>
<if
test=
"name != null and name
=
= ''"
>
<if
test=
"name != null and name
!
= ''"
>
and emp.real_name like CONCAT(CONCAT('%',#{name}) ,'%')
and emp.real_name like CONCAT(CONCAT('%',#{name}) ,'%')
</if>
</if>
<if
test=
"tel != null and tel
=
= ''"
>
<if
test=
"tel != null and tel
!
= ''"
>
and emp.tel = #{tel}
and emp.tel = #{tel}
</if>
</if>
<if
test=
"groupLeader != null and groupLeader
=
= ''"
>
<if
test=
"groupLeader != null and groupLeader
!
= ''"
>
and emp.Group_leader = #{groupLeader}
and emp.Group_leader = #{groupLeader}
</if>
</if>
</where>
</where>
...
...
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