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
9f81190c
Commit
9f81190c
authored
Jan 10, 2023
by
maqing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
日常生活活动能力查询
parent
109c6810
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
142 additions
and
17 deletions
+142
-17
TaskController.java
...main/java/com/hungraim/ltc/controller/TaskController.java
+5
-6
ChAprReportFractionMapper.java
.../java/com/hungraim/ltc/dao/ChAprReportFractionMapper.java
+14
-0
ChAprReportFractionService.java
.../com/hungraim/ltc/service/ChAprReportFractionService.java
+23
-0
TaskService.java
...e/src/main/java/com/hungraim/ltc/service/TaskService.java
+3
-6
ChAprReportFractionServiceImpl.java
...raim/ltc/service/impl/ChAprReportFractionServiceImpl.java
+38
-0
TaskServiceImpl.java
...n/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
+44
-4
ChAprReportFraction.java
...graim/ltc/pojo/entity/assessment/ChAprReportFraction.java
+4
-0
ReportUpdateVO.java
...rc/main/java/com/hungraim/ltc/pojo/vo/ReportUpdateVO.java
+2
-1
ReportDetailVO.java
...a/com/hungraim/ltc/pojo/vo/assessment/ReportDetailVO.java
+3
-0
TaskReportVO.java
...ava/com/hungraim/ltc/pojo/vo/assessment/TaskReportVO.java
+6
-0
No files found.
assessment/assessment-service/src/main/java/com/hungraim/ltc/controller/TaskController.java
View file @
9f81190c
...
...
@@ -5,10 +5,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.hungraim.ltc.dto.QueryDto
;
import
com.hungraim.ltc.pojo.entity.SysConfig.ChFndAttach
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReport
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprTask
;
import
com.hungraim.ltc.pojo.entity.assessment.ChRefuseReason
;
import
com.hungraim.ltc.pojo.entity.assessment.ChTaskReportFractionDtl
;
import
com.hungraim.ltc.pojo.entity.assessment.*
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.vo.ReportUpdateVO
;
import
com.hungraim.ltc.pojo.vo.assessment.*
;
...
...
@@ -155,6 +152,8 @@ public class TaskController {
String
polNo
=
reportDetailVo
.
getPolNo
();
String
remark
=
reportDetailVo
.
getRemark
();
List
<
ChFndAttach
>
fileDataList
=
reportDetailVo
.
getFileDataList
();
List
<
ChAprReportFraction
>
chTaskReportFractionDtls
=
reportDetailVo
.
getChAprReportFractions
();
if
(
person1
==
null
)
{
return
Result
.
failed
(
"鉴定人员1不能为空!"
);
}
...
...
@@ -174,7 +173,7 @@ public class TaskController {
}
catch
(
ParseException
e
)
{
return
Result
.
failed
(
"评估时间格式不正确!"
);
}
Result
<
Object
>
objectResult
=
taskService
.
addReport
(
taskId
,
person1
,
person2
,
person3
,
evaluateDate
,
disableLevelId
,
polNo
,
remark
,
fileDataList
);
Result
<
Object
>
objectResult
=
taskService
.
addReport
(
taskId
,
person1
,
person2
,
person3
,
evaluateDate
,
disableLevelId
,
polNo
,
remark
,
fileDataList
,
chTaskReportFractionDtls
);
if
(!
ResultCode
.
SUCCESS
.
getCode
().
equals
(
objectResult
.
getCode
()))
{
//失败
return
Result
.
failed
(
objectResult
.
getMsg
());
...
...
@@ -214,7 +213,7 @@ public class TaskController {
}
catch
(
ParseException
e
)
{
return
Result
.
failed
(
"评估时间格式不正确!"
);
}
taskService
.
updateReport
(
vo
.
getReportId
(),
vo
.
getPerson1
(),
vo
.
getPerson2
(),
vo
.
getPerson3
(),
evaluateDate
,
vo
.
getDisableLevelId
(),
vo
.
getPolNo
(),
vo
.
getRemark
(),
vo
.
getFileDataList
(),
vo
.
getCh
TaskReportFractionDtl
());
taskService
.
updateReport
(
vo
.
getReportId
(),
vo
.
getPerson1
(),
vo
.
getPerson2
(),
vo
.
getPerson3
(),
evaluateDate
,
vo
.
getDisableLevelId
(),
vo
.
getPolNo
(),
vo
.
getRemark
(),
vo
.
getFileDataList
(),
vo
.
getCh
AprReportFractions
());
return
Result
.
success
();
}
...
...
assessment/assessment-service/src/main/java/com/hungraim/ltc/dao/ChAprReportFractionMapper.java
0 → 100644
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
dao
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.springframework.stereotype.Repository
;
/**
* @author mq
*/
@Mapper
@Repository
public
interface
ChAprReportFractionMapper
extends
BaseMapper
<
ChAprReportFraction
>
{
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/ChAprReportFractionService.java
0 → 100644
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
java.util.List
;
/**
* @author mq
*/
public
interface
ChAprReportFractionService
extends
IService
<
ChAprReportFraction
>
{
/**
* 批量修改
* @return
*/
void
updateChAprReportFraction
(
List
<
ChAprReportFraction
>
chAprReportFractions
);
/**
* 批量新增
* @param chAprReportFractions
*/
void
insertChAprReportFraction
(
List
<
ChAprReportFraction
>
chAprReportFractions
);
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/TaskService.java
View file @
9f81190c
...
...
@@ -3,10 +3,7 @@ package com.hungraim.ltc.service;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.hungraim.ltc.pojo.entity.SysConfig.ChFndAttach
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReport
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprTask
;
import
com.hungraim.ltc.pojo.entity.assessment.ChRefuseReason
;
import
com.hungraim.ltc.pojo.entity.assessment.ChTaskReportFractionDtl
;
import
com.hungraim.ltc.pojo.entity.assessment.*
;
import
com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel
;
import
com.hungraim.ltc.pojo.vo.assessment.*
;
import
com.hungraim.ltc.util.Result
;
...
...
@@ -32,9 +29,9 @@ public interface TaskService {
List
<
AprEmpVO
>
aprEmpList
(
String
provincial
,
String
city
,
String
area
,
String
organName
,
String
name
,
String
tel
,
String
groupLeader
);
Result
<
Object
>
addReport
(
Integer
taskId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateTime
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
);
Result
<
Object
>
addReport
(
Integer
taskId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateTime
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
ChAprReportFraction
>
chAprReportFractions
);
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
Ch
TaskReportFractionDtl
>
chTaskReportFractionDtl
s
);
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
Ch
AprReportFraction
>
chAprReportFraction
s
);
Result
<
Object
>
allotTask
(
String
taskId
,
String
empId
);
...
...
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/impl/ChAprReportFractionServiceImpl.java
0 → 100644
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.hungraim.ltc.dao.ChAprReportFractionMapper
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
com.hungraim.ltc.service.ChAprReportFractionService
;
import
lombok.AllArgsConstructor
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* @author mq
*/
@Service
@Slf4j
@AllArgsConstructor
public
class
ChAprReportFractionServiceImpl
extends
ServiceImpl
<
ChAprReportFractionMapper
,
ChAprReportFraction
>
implements
ChAprReportFractionService
{
@Autowired
ChAprReportFractionMapper
chAprReportFractionMapper
;
@Override
public
void
updateChAprReportFraction
(
List
<
ChAprReportFraction
>
chAprReportFractions
)
{
this
.
updateBatchById
(
chAprReportFractions
);
}
@Override
public
void
insertChAprReportFraction
(
List
<
ChAprReportFraction
>
chAprReportFractions
)
{
this
.
saveBatch
(
chAprReportFractions
,
chAprReportFractions
.
size
());
}
}
assessment/assessment-service/src/main/java/com/hungraim/ltc/service/impl/TaskServiceImpl.java
View file @
9f81190c
...
...
@@ -14,6 +14,7 @@ import com.hungraim.ltc.pojo.entity.disable.ChCfgSrvDisableLevel;
import
com.hungraim.ltc.pojo.entity.disable.ChDisableInfo
;
import
com.hungraim.ltc.pojo.vo.assessment.*
;
import
com.hungraim.ltc.pojo.vo.system.AttachUpdateVo
;
import
com.hungraim.ltc.service.ChAprReportFractionService
;
import
com.hungraim.ltc.service.TaskService
;
import
com.hungraim.ltc.service.TppesApiException
;
import
com.hungraim.ltc.util.AttachType
;
...
...
@@ -51,6 +52,10 @@ public class TaskServiceImpl implements TaskService {
private
final
RefuseReasonMapper
refuseReasonMapper
;
private
final
AttachFeignService
attachFeignService
;
private
final
ChAprReportFractionService
chAprReportFractionService
;
private
final
ChAprReportFractionMapper
chAprReportFractionMapper
;
private
final
ChTaskReportFractionDtlMapper
chTaskReportFractionDtlMapper
;
/**
...
...
@@ -90,7 +95,34 @@ public class TaskServiceImpl implements TaskService {
*/
@Override
public
List
<
TaskReportVO
>
taskReportList
(
String
name
,
String
certiCode
,
String
tel
)
{
return
taskMapper
.
taskReportList
(
name
,
certiCode
,
tel
);
List
<
TaskReportVO
>
taskReportVOS
=
taskMapper
.
taskReportList
(
name
,
certiCode
,
tel
);
Map
<
Object
,
Object
>
typeMap
=
new
HashMap
<>();
Map
<
Object
,
Object
>
taskReportProxyMap
=
new
HashMap
<>();
for
(
int
i
=
0
;
i
<
taskReportVOS
.
size
();
i
++)
{
String
reportId
=
taskReportVOS
.
get
(
i
).
getReportId
();
List
<
ChAprReportFraction
>
chAprReportFractions
=
chAprReportFractionMapper
.
selectList
(
new
LambdaQueryWrapper
<
ChAprReportFraction
>().
eq
(
ChAprReportFraction:
:
getReportId
,
reportId
));
Map
<
String
,
Object
>
typeHashMap
=
new
HashMap
<>();
for
(
ChAprReportFraction
chAprReportFraction:
chAprReportFractions
)
{
String
taskReportType
=
chAprReportFraction
.
getTaskReportType
();
if
(!
typeHashMap
.
containsKey
(
taskReportType
)){
List
<
ChAprReportFraction
>
typeList
=
chAprReportFractions
.
stream
().
filter
(
c
->
c
.
getTaskReportType
().
equals
(
taskReportType
)).
collect
(
Collectors
.
toList
());
Map
<
String
,
Object
>
hashMap
=
new
HashMap
<>();
for
(
ChAprReportFraction
chTaskReportFraction:
typeList
)
{
String
taskReportProxy
=
chTaskReportFraction
.
getTaskReportProxy
();
if
(!
hashMap
.
containsKey
(
taskReportProxy
)){
List
<
ChAprReportFraction
>
collect
=
typeList
.
stream
().
filter
(
c
->
c
.
getTaskReportProxy
().
equals
(
taskReportProxy
)).
collect
(
Collectors
.
toList
());
hashMap
.
put
(
taskReportProxy
,
collect
);
}
}
taskReportVOS
.
get
(
i
).
getChAprReportFractions
().
put
(
taskReportType
,
hashMap
);
//typeHashMap.put(taskReportType,hashMap);
}
}
}
return
taskReportVOS
;
}
/**
...
...
@@ -133,14 +165,14 @@ public class TaskServiceImpl implements TaskService {
*/
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Override
public
Result
<
Object
>
addReport
(
Integer
taskId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateTime
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
)
{
public
Result
<
Object
>
addReport
(
Integer
taskId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateTime
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
ChAprReportFraction
>
chAprReportFractions
)
{
List
<
ChAprReport
>
chAprReports
=
aprReportMapper
.
selectList
(
new
LambdaQueryWrapper
<
ChAprReport
>().
eq
(
ChAprReport:
:
getStatus
,
4
).
eq
(
ChAprReport:
:
getTaskId
,
taskId
));
if
(
chAprReports
!=
null
&&
chAprReports
.
size
()
>
0
)
{
return
Result
.
failed
(
"已存在的评定任务报告!"
);
}
//插入评定任报告
ChAprReport
report
=
new
ChAprReport
();
report
.
setTaskId
(
taskId
);
//
report.setTaskId(taskId);
report
.
setEffTime
(
new
Date
());
report
.
setRemark
(
remark
);
report
.
setDisableLevelId
(
disableLevelId
);
...
...
@@ -173,6 +205,9 @@ public class TaskServiceImpl implements TaskService {
personInfo
.
setFcd
(
new
Date
());
personInfoMapper
.
insert
(
personInfo
);
}
if
(!
chAprReportFractions
.
isEmpty
()
&&
chAprReportFractions
.
size
()>
0
){
chAprReportFractionService
.
updateChAprReportFraction
(
chAprReportFractions
);
}
// 更新评定任务状态为已完成,并记录完成时间
ChAprTask
task
=
new
ChAprTask
();
task
.
setTaskId
(
taskId
);
...
...
@@ -197,7 +232,7 @@ public class TaskServiceImpl implements TaskService {
*/
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Override
public
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
Ch
TaskReportFractionDtl
>
chTaskReportFractionDtl
s
)
{
public
void
updateReport
(
Integer
reportId
,
Integer
person1
,
Integer
person2
,
Integer
person3
,
Date
evaluateDate
,
Integer
disableLevelId
,
String
polNo
,
String
remark
,
List
<
ChFndAttach
>
fileDataList
,
List
<
Ch
AprReportFraction
>
chAprReportFraction
s
)
{
//update鉴定报告
ChAprReport
chAprReport
=
aprReportMapper
.
selectById
(
reportId
);
chAprReport
.
setDisableLevelId
(
disableLevelId
);
...
...
@@ -248,6 +283,11 @@ public class TaskServiceImpl implements TaskService {
personInfoMapper
.
insert
(
personInfo
);
}
}
if
(!
chAprReportFractions
.
isEmpty
()
&&
chAprReportFractions
.
size
()>
0
){
chAprReportFractionService
.
updateChAprReportFraction
(
chAprReportFractions
);
}
}
...
...
common/common-core/src/main/java/com/hungraim/ltc/pojo/entity/assessment/ChAprReportFraction.java
View file @
9f81190c
...
...
@@ -36,4 +36,8 @@ public class ChAprReportFraction {
* 标准
*/
private
String
taskReportEvaluation
;
/**
* c1(日常生活活动能力),c2(认知能力),c3(感知觉与沟通能力)分类
*/
private
String
taskReportType
;
}
common/common-core/src/main/java/com/hungraim/ltc/pojo/vo/ReportUpdateVO.java
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
pojo
.
vo
;
import
com.hungraim.ltc.pojo.entity.SysConfig.ChFndAttach
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
com.hungraim.ltc.pojo.entity.assessment.ChTaskReportFractionDtl
;
import
lombok.Data
;
...
...
@@ -22,5 +23,5 @@ public class ReportUpdateVO {
String
polNo
;
String
remark
;
List
<
ChFndAttach
>
fileDataList
;
List
<
Ch
TaskReportFractionDtl
>
chTaskReportFractionDtl
;
List
<
Ch
AprReportFraction
>
chAprReportFractions
;
}
common/common-core/src/main/java/com/hungraim/ltc/pojo/vo/assessment/ReportDetailVO.java
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
pojo
.
vo
.
assessment
;
import
com.hungraim.ltc.pojo.entity.SysConfig.ChFndAttach
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
com.hungraim.ltc.pojo.entity.assessment.ChTaskReportFractionDtl
;
import
lombok.Data
;
import
java.util.List
;
...
...
@@ -16,4 +18,5 @@ public class ReportDetailVO {
String
polNo
;
String
remark
;
List
<
ChFndAttach
>
fileDataList
;
List
<
ChAprReportFraction
>
chAprReportFractions
;
}
common/common-core/src/main/java/com/hungraim/ltc/pojo/vo/assessment/TaskReportVO.java
View file @
9f81190c
package
com
.
hungraim
.
ltc
.
pojo
.
vo
.
assessment
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.hungraim.ltc.pojo.entity.assessment.ChAprReportFraction
;
import
lombok.Data
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
/**
* 评定报告录入列表
...
...
@@ -63,6 +66,9 @@ public class TaskReportVO {
private
String
acptSrvArea
;
//评定结果
private
String
riskLevel
;
private
Map
<
String
,
Object
>
chAprReportFractions
;
//录入时间
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
timezone
=
"GMT+8"
)
private
Date
effTime
;
...
...
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