Commit 5925d3a0edd1d1da62566122dc1d648dd0b694de
1 parent
25796dca76
Exists in
master
and in
8 other branches
孕妇分娩后 变成产妇
Showing 3 changed files with 57 additions and 27 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/MatDeliverFacade.java
View file @
5925d3a
| ... | ... | @@ -182,7 +182,7 @@ |
| 182 | 182 | babyModel.setHospitalId(patients.getHospitalId()); |
| 183 | 183 | babyModel.setDueDate(patients.getDueDate()); |
| 184 | 184 | babyModel.setDueType(patients.getDueType()); |
| 185 | - babyModel.setBuildDoctor("产科病房"); | |
| 185 | + babyModel.setBuildDoctor("a9e5507f-e7da-4ec6-b8db-9a1e4d1b7c29"); | |
| 186 | 186 | babyModel.setServiceStatus(patients.getServiceStatus()); |
| 187 | 187 | babyModel.setServiceType(patients.getServiceType()); |
| 188 | 188 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java
View file @
5925d3a
| ... | ... | @@ -14,10 +14,7 @@ |
| 14 | 14 | import com.lyms.platform.operate.web.utils.CommonsHelper; |
| 15 | 15 | import com.lyms.platform.permission.model.Users; |
| 16 | 16 | import com.lyms.platform.permission.service.UsersService; |
| 17 | -import com.lyms.platform.pojo.AntenatalExaminationModel; | |
| 18 | -import com.lyms.platform.pojo.BabyModel; | |
| 19 | -import com.lyms.platform.pojo.CommunityConfig; | |
| 20 | -import com.lyms.platform.pojo.Patients; | |
| 17 | +import com.lyms.platform.pojo.*; | |
| 21 | 18 | import com.lyms.platform.query.AntExChuQuery; |
| 22 | 19 | import com.lyms.platform.query.AntExQuery; |
| 23 | 20 | import com.lyms.platform.query.BabyModelQuery; |
| ... | ... | @@ -196,7 +193,7 @@ |
| 196 | 193 | * @param type 控制类型 1孕妇 3产妇 |
| 197 | 194 | * @return |
| 198 | 195 | */ |
| 199 | - public BaseResponse queryHighRisk(RiskPatientsQueryRequest riskPatientsQueryRequest, Boolean isHighRisk, int type,Integer userId) { | |
| 196 | + public BaseResponse queryHighRisk(RiskPatientsQueryRequest riskPatientsQueryRequest, Boolean isHighRisk, int type, Integer userId) { | |
| 200 | 197 | PatientsQuery patientsQuery = new PatientsQuery(); |
| 201 | 198 | patientsQuery.setPhone(riskPatientsQueryRequest.getPhone()); |
| 202 | 199 | patientsQuery.setCardNo(riskPatientsQueryRequest.getCardNo()); |
| ... | ... | @@ -248,7 +245,7 @@ |
| 248 | 245 | try { |
| 249 | 246 | HighScoreResult highScoreResult = antenatalExaminationFacade.findLastRisk(patients.getId()); |
| 250 | 247 | patientBaseResult.setRiskFactor(highScoreResult.getHighRisk()); |
| 251 | - patientBaseResult.setRiskScore(highScoreResult.getScore()+""); | |
| 248 | + patientBaseResult.setRiskScore(highScoreResult.getScore() + ""); | |
| 252 | 249 | } catch (Exception e) { |
| 253 | 250 | } |
| 254 | 251 | return new BaseObjectResponse().setData(patientBaseResult).setErrormsg("成功").setErrorcode(ErrorCodeConstants.SUCCESS); |
| 255 | 252 | |
| 256 | 253 | |
| 257 | 254 | |
| ... | ... | @@ -270,19 +267,19 @@ |
| 270 | 267 | chanResult.convertToResult(patients); |
| 271 | 268 | antExQuery.setParentId(patients.getId()); |
| 272 | 269 | antExQuery.setYn(YnEnums.YES.getId()); |
| 273 | - if(StringUtils.isNotEmpty(patients.getBookbuildingDoctor())){ | |
| 274 | - if(NumberUtils.isNumber(patients.getBookbuildingDoctor())){ | |
| 270 | + if (StringUtils.isNotEmpty(patients.getBookbuildingDoctor())) { | |
| 271 | + if (NumberUtils.isNumber(patients.getBookbuildingDoctor())) { | |
| 275 | 272 | Users users = usersService.getUsers(NumberUtils.toInt(patients.getBookbuildingDoctor())); |
| 276 | 273 | chanResult.setlName(users.getName()); |
| 277 | - }else{ | |
| 274 | + } else { | |
| 278 | 275 | chanResult.setlName(patients.getBookbuildingDoctor()); |
| 279 | 276 | } |
| 280 | 277 | } |
| 281 | - if(StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())){ | |
| 282 | - if(NumberUtils.isNumber(patients.getLastCheckEmployeeId())){ | |
| 278 | + if (StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())) { | |
| 279 | + if (NumberUtils.isNumber(patients.getLastCheckEmployeeId())) { | |
| 283 | 280 | Users users = usersService.getUsers(NumberUtils.toInt(patients.getLastCheckEmployeeId())); |
| 284 | 281 | chanResult.setCheckDoctor(users.getName()); |
| 285 | - }else{ | |
| 282 | + } else { | |
| 286 | 283 | chanResult.setCheckDoctor(patients.getLastCheckEmployeeId()); |
| 287 | 284 | } |
| 288 | 285 | } |
| 289 | 286 | |
| 290 | 287 | |
| ... | ... | @@ -292,9 +289,17 @@ |
| 292 | 289 | antExChuQuery.setParentId(patients.getId()); |
| 293 | 290 | antExChuQuery.setYn(YnEnums.YES.getId()); |
| 294 | 291 | List<AntenatalExaminationModel> ant = antExService.queryAntenatalExamination(antExChuQuery.convertToQuery().addOrder(Sort.Direction.DESC, "created")); |
| 292 | + | |
| 293 | + | |
| 295 | 294 | String nextCheckTime = ""; |
| 295 | +// List<AntenatalExaminationModel> examinationModels = antExService.queryAntenatalExamination(antExQuery.convertToQuery()); | |
| 296 | 296 | if (CollectionUtils.isNotEmpty(ant)) { |
| 297 | 297 | nextCheckTime = DateUtil.getyyyy_MM_dd(ant.get(0).getNextCheckTime()); |
| 298 | + } else { | |
| 299 | + List<AntExChuModel> list = antExService.queryAntExChu(antExChuQuery); | |
| 300 | + if (CollectionUtils.isNotEmpty(list)) { | |
| 301 | + nextCheckTime = DateUtil.getyyyy_MM_dd(list.get(0).getNextCheckTime()); | |
| 302 | + } | |
| 298 | 303 | } |
| 299 | 304 | chanResult.setNextCheckTime(nextCheckTime); |
| 300 | 305 | data.add(chanResult); |
| 301 | 306 | |
| 302 | 307 | |
| 303 | 308 | |
| ... | ... | @@ -312,19 +317,19 @@ |
| 312 | 317 | quanPatientsResult.convertToResult(patients); |
| 313 | 318 | antExQuery.setParentId(patients.getId()); |
| 314 | 319 | antExQuery.setYn(YnEnums.YES.getId()); |
| 315 | - if(StringUtils.isNotEmpty(patients.getBookbuildingDoctor())){ | |
| 316 | - if(NumberUtils.isNumber(patients.getBookbuildingDoctor())){ | |
| 320 | + if (StringUtils.isNotEmpty(patients.getBookbuildingDoctor())) { | |
| 321 | + if (NumberUtils.isNumber(patients.getBookbuildingDoctor())) { | |
| 317 | 322 | Users users = usersService.getUsers(NumberUtils.toInt(patients.getBookbuildingDoctor())); |
| 318 | 323 | quanPatientsResult.setlName(users.getName()); |
| 319 | - }else{ | |
| 324 | + } else { | |
| 320 | 325 | quanPatientsResult.setlName(patients.getBookbuildingDoctor()); |
| 321 | 326 | } |
| 322 | 327 | } |
| 323 | - if(StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())){ | |
| 324 | - if(NumberUtils.isNumber(patients.getLastCheckEmployeeId())){ | |
| 328 | + if (StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())) { | |
| 329 | + if (NumberUtils.isNumber(patients.getLastCheckEmployeeId())) { | |
| 325 | 330 | Users users = usersService.getUsers(NumberUtils.toInt(patients.getLastCheckEmployeeId())); |
| 326 | 331 | quanPatientsResult.setCheckDoctor(users.getName()); |
| 327 | - }else{ | |
| 332 | + } else { | |
| 328 | 333 | quanPatientsResult.setCheckDoctor(patients.getLastCheckEmployeeId()); |
| 329 | 334 | } |
| 330 | 335 | } |
| ... | ... | @@ -335,6 +340,17 @@ |
| 335 | 340 | //初诊次数 |
| 336 | 341 | int b = antExService.queryAntExChuCount(antExChuQuery.convertToQuery()); |
| 337 | 342 | quanPatientsResult.setcTimes(i + b); |
| 343 | + String nextCheckTime = ""; | |
| 344 | + List<AntenatalExaminationModel> examinationModels = antExService.queryAntenatalExamination(antExQuery.convertToQuery().addOrder(Sort.Direction.DESC, "created")); | |
| 345 | + if (CollectionUtils.isNotEmpty(examinationModels)) { | |
| 346 | + nextCheckTime = DateUtil.getyyyy_MM_dd(examinationModels.get(0).getNextCheckTime()); | |
| 347 | + } else { | |
| 348 | + List<AntExChuModel> list = antExService.queryAntExChu(antExChuQuery); | |
| 349 | + if (CollectionUtils.isNotEmpty(list)) { | |
| 350 | + nextCheckTime = DateUtil.getyyyy_MM_dd(list.get(0).getNextCheckTime()); | |
| 351 | + } | |
| 352 | + } | |
| 353 | + quanPatientsResult.setcTime(nextCheckTime); | |
| 338 | 354 | data.add(quanPatientsResult); |
| 339 | 355 | } |
| 340 | 356 | return data; |
| 341 | 357 | |
| 342 | 358 | |
| 343 | 359 | |
| ... | ... | @@ -353,19 +369,19 @@ |
| 353 | 369 | for (Patients patients : patientses) { |
| 354 | 370 | RiskPatientsResult riskPatientsResult = new RiskPatientsResult(); |
| 355 | 371 | riskPatientsResult.convertToResult(patients); |
| 356 | - if(StringUtils.isNotEmpty(patients.getBookbuildingDoctor())){ | |
| 357 | - if(NumberUtils.isNumber(patients.getBookbuildingDoctor())){ | |
| 358 | - Users users = usersService.getUsers(NumberUtils.toInt(patients.getBookbuildingDoctor())); | |
| 372 | + if (StringUtils.isNotEmpty(patients.getBookbuildingDoctor())) { | |
| 373 | + if (NumberUtils.isNumber(patients.getBookbuildingDoctor())) { | |
| 374 | + Users users = usersService.getUsers(NumberUtils.toInt(patients.getBookbuildingDoctor())); | |
| 359 | 375 | riskPatientsResult.setlName(users.getName()); |
| 360 | - }else{ | |
| 376 | + } else { | |
| 361 | 377 | riskPatientsResult.setlName(patients.getBookbuildingDoctor()); |
| 362 | 378 | } |
| 363 | 379 | } |
| 364 | - if(StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())){ | |
| 365 | - if(NumberUtils.isNumber(patients.getLastCheckEmployeeId())){ | |
| 380 | + if (StringUtils.isNotEmpty(patients.getLastCheckEmployeeId())) { | |
| 381 | + if (NumberUtils.isNumber(patients.getLastCheckEmployeeId())) { | |
| 366 | 382 | Users users = usersService.getUsers(NumberUtils.toInt(patients.getLastCheckEmployeeId())); |
| 367 | 383 | riskPatientsResult.setCheckDoctor(users.getName()); |
| 368 | - }else{ | |
| 384 | + } else { | |
| 369 | 385 | riskPatientsResult.setCheckDoctor(patients.getLastCheckEmployeeId()); |
| 370 | 386 | } |
| 371 | 387 | } |
| ... | ... | @@ -377,6 +393,17 @@ |
| 377 | 393 | //初诊次数 |
| 378 | 394 | int b = antExService.queryAntExChuCount(antExChuQuery.convertToQuery()); |
| 379 | 395 | riskPatientsResult.setcTimes(i + b); |
| 396 | + String nextCheckTime = ""; | |
| 397 | + List<AntenatalExaminationModel> examinationModels = antExService.queryAntenatalExamination(antExQuery.convertToQuery().addOrder(Sort.Direction.DESC, "created")); | |
| 398 | + if (CollectionUtils.isNotEmpty(examinationModels)) { | |
| 399 | + nextCheckTime = DateUtil.getyyyy_MM_dd(examinationModels.get(0).getNextCheckTime()); | |
| 400 | + } else { | |
| 401 | + List<AntExChuModel> list = antExService.queryAntExChu(antExChuQuery); | |
| 402 | + if (CollectionUtils.isNotEmpty(list)) { | |
| 403 | + nextCheckTime = DateUtil.getyyyy_MM_dd(list.get(0).getNextCheckTime()); | |
| 404 | + } | |
| 405 | + } | |
| 406 | + riskPatientsResult.setcTime(nextCheckTime); | |
| 380 | 407 | data.add(riskPatientsResult); |
| 381 | 408 | } |
| 382 | 409 | return data; |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/StopPregnancyFacade.java
View file @
5925d3a
| ... | ... | @@ -281,7 +281,10 @@ |
| 281 | 281 | } |
| 282 | 282 | |
| 283 | 283 | } |
| 284 | - | |
| 284 | + Map map = new HashMap(); | |
| 285 | + map.put("id","a9e5507f-e7da-4ec6-b8db-9a1e4d1b7c29"); | |
| 286 | + map.put("name","产科病房"); | |
| 287 | + list.add(map); | |
| 285 | 288 | BaseObjectResponse objectResponse = new BaseObjectResponse(); |
| 286 | 289 | objectResponse.setData(list); |
| 287 | 290 | objectResponse.setErrorcode(ErrorCodeConstants.SUCCESS); |