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
34441f86
Commit
34441f86
authored
Apr 23, 2021
by
蔡镇泽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
评定任务分组管理(整组操作)
parent
e6fef9ad
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
127 additions
and
41 deletions
+127
-41
TaskController.java
...main/java/com/hungraim/ltc/controller/TaskController.java
+39
-3
TaskMapper.java
...ervice/src/main/java/com/hungraim/ltc/dao/TaskMapper.java
+2
-0
TaskService.java
...e/src/main/java/com/hungraim/ltc/service/TaskService.java
+5
-1
TaskServiceImpl.java
...n/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
+30
-5
ChDisableEvaluateMapper.xml
...ice/src/main/resources/mapper/ChDisableEvaluateMapper.xml
+39
-32
TaskGroupInfoVO.java
.../com/hungraim/ltc/pojo/vo/assessment/TaskGroupInfoVO.java
+12
-0
No files found.
assessment/assessment-service/src/main/java/com/hungraim/ltc/controller/TaskController.java
View file @
34441f86
...
@@ -194,8 +194,8 @@ public class TaskController {
...
@@ -194,8 +194,8 @@ public class TaskController {
* @param empId 评定人员id
* @param empId 评定人员id
*/
*/
@RequestMapping
(
"/allotTask"
)
@RequestMapping
(
"/allotTask"
)
public
Result
allotTask
(
String
taskId
,
Integer
empId
)
{
public
Result
allotTask
(
String
taskId
,
String
empId
)
{
if
(
StringUtils
.
isBlank
(
taskId
)
&&
empId
!=
null
)
{
if
(
StringUtils
.
isBlank
(
taskId
)
&&
StringUtils
.
isBlank
(
empId
)
)
{
return
Result
.
failed
(
"id不能为空!"
);
return
Result
.
failed
(
"id不能为空!"
);
}
}
Result
<
Object
>
objectResult
=
taskService
.
allotTask
(
taskId
,
empId
);
Result
<
Object
>
objectResult
=
taskService
.
allotTask
(
taskId
,
empId
);
...
@@ -220,6 +220,42 @@ public class TaskController {
...
@@ -220,6 +220,42 @@ public class TaskController {
}
}
/**
/**
* 评定任务分组管理列表详情
*
* @param groupNumber 组号
*/
@RequestMapping
(
"/taskGroupList"
)
public
Result
<
List
<
TaskGroupInfoVO
>>
taskGroupInfoList
(
String
groupNumber
)
{
if
(
StringUtils
.
isBlank
(
groupNumber
))
{
return
Result
.
failed
(
"组号不能为空!"
);
}
List
<
TaskGroupInfoVO
>
groupInfoList
=
taskService
.
taskGroupInfoList
(
groupNumber
);
return
Result
.
success
(
groupInfoList
);
}
/**
* 评定任务分组管理(整组操作)
*
* @param groupNumber 组号
* @param status 分组状态 未分配(拒绝(重新分配)):0;已分配:1;已接受:2;已完成:3;拒绝(中止):4,拒绝(终止):5
*/
@RequestMapping
(
"/taskGroupByGroup"
)
public
Result
taskGroupByGroup
(
String
groupNumber
,
Integer
status
)
{
if
(
StringUtils
.
isBlank
(
groupNumber
))
{
return
Result
.
failed
(
"组号不能为空!"
);
}
if
(
status
==
null
||
status
<
0
||
status
>
5
)
{
Result
.
failed
(
"状态异常!"
);
}
Result
<
Object
>
objectResult
=
taskService
.
taskGroupByGroup
(
groupNumber
,
status
);
if
(!
ResultCode
.
SUCCESS
.
getCode
().
equals
(
objectResult
.
getCode
()))
{
//失败
return
Result
.
failed
(
objectResult
.
getMsg
());
}
return
Result
.
success
();
}
/**
* 评定任务分组管理
* 评定任务分组管理
*
*
* @param pushId 任务清单id
* @param pushId 任务清单id
...
@@ -231,7 +267,7 @@ public class TaskController {
...
@@ -231,7 +267,7 @@ public class TaskController {
Result
.
failed
(
"状态异常!"
);
Result
.
failed
(
"状态异常!"
);
}
}
if
(
pushId
==
null
)
{
if
(
pushId
==
null
)
{
Result
.
failed
(
"任务
清单id
不能为空!"
);
Result
.
failed
(
"任务
组
不能为空!"
);
}
}
Result
<
Object
>
objectResult
=
taskService
.
taskGroup
(
pushId
,
status
);
Result
<
Object
>
objectResult
=
taskService
.
taskGroup
(
pushId
,
status
);
if
(!
ResultCode
.
SUCCESS
.
getCode
().
equals
(
objectResult
.
getCode
()))
{
if
(!
ResultCode
.
SUCCESS
.
getCode
().
equals
(
objectResult
.
getCode
()))
{
...
...
assessment/assessment-service/src/main/java/com/hungraim/ltc/dao/TaskMapper.java
View file @
34441f86
...
@@ -48,4 +48,6 @@ public interface TaskMapper extends BaseMapper<ChAprTask> {
...
@@ -48,4 +48,6 @@ public interface TaskMapper extends BaseMapper<ChAprTask> {
List
<
AprEmpVO
>
aprEmpList
(
String
organName
,
String
name
,
String
tel
,
String
groupLeader
);
List
<
AprEmpVO
>
aprEmpList
(
String
organName
,
String
name
,
String
tel
,
String
groupLeader
);
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
);
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
);
List
<
TaskGroupInfoVO
>
taskGroupInfoList
(
String
groupNumber
);
}
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/TaskService.java
View file @
34441f86
...
@@ -55,7 +55,7 @@ public interface TaskService {
...
@@ -55,7 +55,7 @@ public interface TaskService {
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
);
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
);
Result
<
Object
>
allotTask
(
String
taskId
,
Integer
empId
);
Result
<
Object
>
allotTask
(
String
taskId
,
String
empId
);
List
<
TaskGroupVO
>
taskGroupList
(
String
name
,
String
certiCode
,
String
tel
);
List
<
TaskGroupVO
>
taskGroupList
(
String
name
,
String
certiCode
,
String
tel
);
...
@@ -64,4 +64,8 @@ public interface TaskService {
...
@@ -64,4 +64,8 @@ public interface TaskService {
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
();
List
<
ChCfgSrvDisableLevel
>
cfgSrvDisableLevelList
();
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
);
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
);
List
<
TaskGroupInfoVO
>
taskGroupInfoList
(
String
groupNumber
);
Result
<
Object
>
taskGroupByGroup
(
String
groupNumber
,
Integer
status
);
}
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
View file @
34441f86
...
@@ -153,7 +153,7 @@ public class TaskServiceImpl implements TaskService {
...
@@ -153,7 +153,7 @@ public class TaskServiceImpl implements TaskService {
}
}
@Override
@Override
public
Result
<
Object
>
allotTask
(
String
taskId
,
Integer
empId
)
{
public
Result
<
Object
>
allotTask
(
String
taskId
,
String
empId
)
{
ChAprEmp
chAprEmp
=
aprEmpMapper
.
selectById
(
empId
);
ChAprEmp
chAprEmp
=
aprEmpMapper
.
selectById
(
empId
);
if
(
chAprEmp
==
null
||
chAprEmp
.
getGroupLeader
()
==
null
||
chAprEmp
.
getGroupLeader
()
!=
0
)
{
if
(
chAprEmp
==
null
||
chAprEmp
.
getGroupLeader
()
==
null
||
chAprEmp
.
getGroupLeader
()
!=
0
)
{
//不是组长
//不是组长
...
@@ -166,7 +166,7 @@ public class TaskServiceImpl implements TaskService {
...
@@ -166,7 +166,7 @@ public class TaskServiceImpl implements TaskService {
if
(
task
==
null
)
{
if
(
task
==
null
)
{
return
Result
.
failed
(
"无效的taskId!"
);
return
Result
.
failed
(
"无效的taskId!"
);
}
}
task
.
setAprEmpId
(
empId
);
task
.
setAprEmpId
(
Integer
.
parseInt
(
empId
)
);
task
.
setAssignTime
(
assignTime
);
task
.
setAssignTime
(
assignTime
);
int
count
=
taskMapper
.
updateById
(
task
);
int
count
=
taskMapper
.
updateById
(
task
);
if
(
count
!=
1
)
{
if
(
count
!=
1
)
{
...
@@ -175,9 +175,9 @@ public class TaskServiceImpl implements TaskService {
...
@@ -175,9 +175,9 @@ public class TaskServiceImpl implements TaskService {
//生成组
//生成组
ChAprTaskPush
taskPush
=
new
ChAprTaskPush
();
ChAprTaskPush
taskPush
=
new
ChAprTaskPush
();
taskPush
.
setTime
(
new
Date
());
taskPush
.
setTime
(
new
Date
());
taskPush
.
setGroupNumber
(
SerialNumberUtils
.
getSerialNumber
(
empId
.
toString
()
));
taskPush
.
setGroupNumber
(
SerialNumberUtils
.
getSerialNumber
(
empId
));
taskPush
.
setTaskId
(
Long
.
getLong
(
id
));
taskPush
.
setTaskId
(
Long
.
getLong
(
id
));
taskPush
.
setEmpId
(
empId
.
longValue
(
));
taskPush
.
setEmpId
(
Long
.
getLong
(
empId
));
taskPush
.
setStatus
((
short
)
1
);
taskPush
.
setStatus
((
short
)
1
);
taskPush
.
setIsManual
((
short
)
1
);
taskPush
.
setIsManual
((
short
)
1
);
taskPushMapper
.
insert
(
taskPush
);
taskPushMapper
.
insert
(
taskPush
);
...
@@ -194,7 +194,7 @@ public class TaskServiceImpl implements TaskService {
...
@@ -194,7 +194,7 @@ public class TaskServiceImpl implements TaskService {
public
Result
<
Object
>
taskGroup
(
Integer
pushId
,
Integer
status
)
{
public
Result
<
Object
>
taskGroup
(
Integer
pushId
,
Integer
status
)
{
ChAprTaskPush
chAprTaskPush
=
taskPushMapper
.
selectById
(
pushId
);
ChAprTaskPush
chAprTaskPush
=
taskPushMapper
.
selectById
(
pushId
);
if
(
chAprTaskPush
==
null
)
{
if
(
chAprTaskPush
==
null
)
{
return
Result
.
failed
(
"不存在的
分
组!"
);
return
Result
.
failed
(
"不存在的组!"
);
}
}
chAprTaskPush
.
setStatus
(
status
.
shortValue
());
chAprTaskPush
.
setStatus
(
status
.
shortValue
());
taskPushMapper
.
updateById
(
chAprTaskPush
);
taskPushMapper
.
updateById
(
chAprTaskPush
);
...
@@ -210,4 +210,28 @@ public class TaskServiceImpl implements TaskService {
...
@@ -210,4 +210,28 @@ public class TaskServiceImpl implements TaskService {
public
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
)
{
public
List
<
PersonInfoVO
>
personInfoList
(
String
reportId
)
{
return
taskMapper
.
personInfoList
(
reportId
);
return
taskMapper
.
personInfoList
(
reportId
);
}
}
@Override
public
List
<
TaskGroupInfoVO
>
taskGroupInfoList
(
String
groupNumber
)
{
return
taskMapper
.
taskGroupInfoList
(
groupNumber
);
}
@Override
public
Result
<
Object
>
taskGroupByGroup
(
String
groupNumber
,
Integer
status
)
{
List
<
ChAprTaskPush
>
pushList
=
taskPushMapper
.
selectList
(
new
QueryWrapper
<
ChAprTaskPush
>().
eq
(
"group_number"
,
groupNumber
));
if
(
pushList
==
null
||
pushList
.
size
()
<=
0
)
{
return
Result
.
failed
(
"不存在的组!"
);
}
short
status1
=
pushList
.
get
(
0
).
getStatus
();
for
(
ChAprTaskPush
push
:
pushList
)
{
if
(
status1
!=
push
.
getStatus
())
{
return
Result
.
failed
(
"该组状态不一致,不可整组操作!"
);
}
}
for
(
ChAprTaskPush
push
:
pushList
)
{
push
.
setStatus
(
status
.
shortValue
());
taskPushMapper
.
updateById
(
push
);
}
return
Result
.
success
();
}
}
}
\ No newline at end of file
assessment/assessment-service/src/main/resources/mapper/ChDisableEvaluateMapper.xml
View file @
34441f86
...
@@ -146,38 +146,6 @@
...
@@ -146,38 +146,6 @@
</where>
</where>
</select>
</select>
<select
id=
"taskGroupList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.TaskGroupVO"
>
SELECT
push.TASK_PUSH_ID taskPushId,
push.assign_time assignTime,
task.task.apr_organ_id aprOrganId,
organ.organ_name organName,
emp_organ.organ_name empOrganName,
push.ROUTE_START_LOCATION routeStatrtLocation,
push.Group_number groupNumber,
emp.real_name realName,
emp.certi_code certiCode,
emp.tel tel,
push.status status
FROM
ch_apr_task_push push
LEFT JOIN ch_apr_task task ON push.TASK_ID = task.TASK_ID
LEFT JOIN CH_APR_ORGAN organ on task.apr_organ_id = organ.apr_organ_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
<where>
<if
test=
"name != null and name != ''"
>
and emp.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
</if>
<if
test=
"certiCode != null and certiCode != ''"
>
and emp.CERTI_CODE = #{certiCode}
</if>
<if
test=
"tel != null and tel != ''"
>
and emp.tel = #{tel}
</if>
</where>
</select>
<select
id=
"aprEmpList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.AprEmpVO"
>
<select
id=
"aprEmpList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.AprEmpVO"
>
SELECT emp.emp_id empId,
SELECT emp.emp_id empId,
srvOrgan.srv_organ_name srvOrganName,
srvOrgan.srv_organ_name srvOrganName,
...
@@ -212,6 +180,45 @@
...
@@ -212,6 +180,45 @@
</where>
</where>
</select>
</select>
<select
id=
"taskGroupList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.TaskGroupVO"
>
SELECT
push.TASK_PUSH_ID taskPushId,
push.assign_time assignTime,
task.task.apr_organ_id aprOrganId,
organ.organ_name organName,
emp_organ.organ_name empOrganName,
push.ROUTE_START_LOCATION routeStatrtLocation,
push.Group_number groupNumber,
emp.real_name realName,
emp.certi_code certiCode,
emp.tel tel,
push.status status
FROM
ch_apr_task_push push
LEFT JOIN ch_apr_task task ON push.TASK_ID = task.TASK_ID
LEFT JOIN CH_APR_ORGAN organ on task.apr_organ_id = organ.apr_organ_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
<where>
<if
test=
"name != null and name != ''"
>
and emp.REAL_NAME like CONCAT(CONCAT('%',#{name}) ,'%')
</if>
<if
test=
"certiCode != null and certiCode != ''"
>
and emp.CERTI_CODE = #{certiCode}
</if>
<if
test=
"tel != null and tel != ''"
>
and emp.tel = #{tel}
</if>
</where>
</select>
<select
id=
"taskGroupInfoList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.TaskGroupInfoVO"
>
select task.task_id taskId
from ch_apr_task_push push
left join ch_apr_organ organ on task.apr_organ_id = organ.apr_organ_id
where push.group_number = #{groupNumber}
</select>
<select
id=
"personInfoList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.PersonInfoVO"
>
<select
id=
"personInfoList"
resultType=
"com.hungraim.ltc.pojo.vo.assessment.PersonInfoVO"
>
SELECT emp.emp_id empId,
SELECT emp.emp_id empId,
organ.organ_name orgaName,
organ.organ_name orgaName,
...
...
common/common-core/src/main/java/com/hungraim/ltc/pojo/vo/assessment/TaskGroupInfoVO.java
0 → 100644
View file @
34441f86
package
com
.
hungraim
.
ltc
.
pojo
.
vo
.
assessment
;
import
lombok.Data
;
/**
* 评定任务分组管理列表详情
*/
@Data
public
class
TaskGroupInfoVO
{
//
}
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