|
@ -589,10 +589,10 @@ public class RehabilitationManageService {
|
|
* @param taskExecutor 任务执行者 0全部;1我的任务 2他人任务
|
|
* @param taskExecutor 任务执行者 0全部;1我的任务 2他人任务
|
|
*/
|
|
*/
|
|
public ObjEnvelop calendarPlanDetail(String executeStartTime, String executeEndTime, String planId, Integer searchTask,
|
|
public ObjEnvelop calendarPlanDetail(String executeStartTime, String executeEndTime, String planId, Integer searchTask,
|
|
Integer status, String doctorCode, String taskExecutor,String patient) throws Exception {
|
|
|
|
String sql = " select d.* from base_service_item_plan d where ";
|
|
|
|
|
|
Integer status, String doctorCode, String taskExecutor,String patient,String diseaseId) throws Exception {
|
|
|
|
String sql = " select d.* from base_service_item_plan d,wlyy_patient_rehabilitation_plan p where d.plan_id=p.id ";
|
|
if(StringUtils.isNotBlank(patient)){
|
|
if(StringUtils.isNotBlank(patient)){
|
|
sql += " d.patient = '" + patient + "' ";
|
|
|
|
|
|
sql += " and d.patient = '" + patient + "' ";
|
|
}else {
|
|
}else {
|
|
String[] planIdlist = planId.split(",");
|
|
String[] planIdlist = planId.split(",");
|
|
StringBuilder planCondition = new StringBuilder();
|
|
StringBuilder planCondition = new StringBuilder();
|
|
@ -600,7 +600,10 @@ public class RehabilitationManageService {
|
|
for (int i = 1; i < planIdlist.length; i++) {
|
|
for (int i = 1; i < planIdlist.length; i++) {
|
|
planCondition.append(",'" + planIdlist[i] + "'");
|
|
planCondition.append(",'" + planIdlist[i] + "'");
|
|
}
|
|
}
|
|
sql += " d.plan_id in (" + planCondition + " ) ";
|
|
|
|
|
|
sql += " and d.plan_id in (" + planCondition + " ) ";
|
|
|
|
}
|
|
|
|
if(StringUtils.isNotBlank(diseaseId)){
|
|
|
|
sql += " and p.disease = '" + diseaseId + "' ";
|
|
}
|
|
}
|
|
if (StringUtils.isNotBlank(executeStartTime)) {
|
|
if (StringUtils.isNotBlank(executeStartTime)) {
|
|
sql += " and d.plan_time>='" + executeStartTime + "' ";
|
|
sql += " and d.plan_time>='" + executeStartTime + "' ";
|
|
@ -694,11 +697,11 @@ public class RehabilitationManageService {
|
|
* @param taskExecutor 任务执行者 0全部;1我的任务 2他人任务
|
|
* @param taskExecutor 任务执行者 0全部;1我的任务 2他人任务
|
|
*/
|
|
*/
|
|
public ObjEnvelop calendarPlanDetailList(String planId, Integer searchTask, Integer status, String doctorCode,
|
|
public ObjEnvelop calendarPlanDetailList(String planId, Integer searchTask, Integer status, String doctorCode,
|
|
String executeStartTime, String executeEndTime, String taskExecutor,String patient) {
|
|
|
|
|
|
String executeStartTime, String executeEndTime, String taskExecutor,String patient,String diseaseId) {
|
|
|
|
|
|
String sql = " select d.* from base_service_item_plan d where ";
|
|
|
|
|
|
String sql = " select d.* from base_service_item_plan d,wlyy_patient_rehabilitation_plan p where d.plan_id=p.id ";
|
|
if(StringUtils.isNotBlank(patient)){
|
|
if(StringUtils.isNotBlank(patient)){
|
|
sql += " d.patient = '" + patient + "' ";
|
|
|
|
|
|
sql += " and d.patient = '" + patient + "' ";
|
|
}else {
|
|
}else {
|
|
String[] planIdlist = planId.split(",");
|
|
String[] planIdlist = planId.split(",");
|
|
StringBuilder planCondition = new StringBuilder();
|
|
StringBuilder planCondition = new StringBuilder();
|
|
@ -706,7 +709,10 @@ public class RehabilitationManageService {
|
|
for (int i = 1; i < planIdlist.length; i++) {
|
|
for (int i = 1; i < planIdlist.length; i++) {
|
|
planCondition.append(",'" + planIdlist[i] + "'");
|
|
planCondition.append(",'" + planIdlist[i] + "'");
|
|
}
|
|
}
|
|
sql += " d.plan_id in (" + planCondition + " ) ";
|
|
|
|
|
|
sql += " and d.plan_id in (" + planCondition + " ) ";
|
|
|
|
}
|
|
|
|
if(StringUtils.isNotBlank(diseaseId)){
|
|
|
|
sql += " and p.disease = '" + diseaseId + "' ";
|
|
}
|
|
}
|
|
|
|
|
|
if (searchTask != null) {
|
|
if (searchTask != null) {
|
|
@ -1624,7 +1630,7 @@ public class RehabilitationManageService {
|
|
public ObjEnvelop appCalendarPlanDetailList(String planId, Integer searchTask, Integer status, String executeStartTime, String executeEndTime) {
|
|
public ObjEnvelop appCalendarPlanDetailList(String planId, Integer searchTask, Integer status, String executeStartTime, String executeEndTime) {
|
|
|
|
|
|
Map<String, Object> resultMap = new HashMap<>();
|
|
Map<String, Object> resultMap = new HashMap<>();
|
|
ObjEnvelop objEnvelop = calendarPlanDetailList(planId, searchTask, status, null, executeStartTime, executeEndTime, "0",null);
|
|
|
|
|
|
ObjEnvelop objEnvelop = calendarPlanDetailList(planId, searchTask, status, null, executeStartTime, executeEndTime, "0",null,null);
|
|
Integer finishCount = rehabilitationDetailDao.findByStatusAndPlanId(1, planId);
|
|
Integer finishCount = rehabilitationDetailDao.findByStatusAndPlanId(1, planId);
|
|
Integer allCount = rehabilitationDetailDao.findAllByPlanId(planId);
|
|
Integer allCount = rehabilitationDetailDao.findAllByPlanId(planId);
|
|
resultMap.put("planDetailList", objEnvelop.getObj());
|
|
resultMap.put("planDetailList", objEnvelop.getObj());
|
|
@ -2686,7 +2692,7 @@ public class RehabilitationManageService {
|
|
|
|
|
|
|
|
|
|
param.put("taskExecutor", taskExecutor);
|
|
param.put("taskExecutor", taskExecutor);
|
|
ObjEnvelop objEnvelop = calendarPlanDetailList(planIds.toString(), searchTask, status, doctorCode, executeStartTime, executeEndTime, taskExecutor,null);
|
|
|
|
|
|
ObjEnvelop objEnvelop = calendarPlanDetailList(planIds.toString(), searchTask, status, doctorCode, executeStartTime, executeEndTime, taskExecutor,null,null);
|
|
|
|
|
|
org.json.JSONObject result = new org.json.JSONObject(objEnvelop);
|
|
org.json.JSONObject result = new org.json.JSONObject(objEnvelop);
|
|
if (result.getInt("status") == 200) {
|
|
if (result.getInt("status") == 200) {
|