|
|
|
|
@ -163,47 +163,6 @@ public class ApmRecordController extends BladeController { |
|
|
|
|
return R.data(page); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// /**
|
|
|
|
|
// * 新增
|
|
|
|
|
// */
|
|
|
|
|
// @PostMapping("/save")
|
|
|
|
|
// @ApiOperationSupport(order = 5)
|
|
|
|
|
// @ApiOperation(value = "新增", notes = "传入apmConfig")
|
|
|
|
|
// public R save(@RequestBody List<ApmRecord> apmRecordList) {
|
|
|
|
|
// if (Func.isEmpty(apmRecordList)) {
|
|
|
|
|
// return R.fail(ErrorMsgEnum.APMRECORD_SAVE_OBJ_IS_NULL.getValue());
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// Date apmDay = null;
|
|
|
|
|
// String cardNo = null;
|
|
|
|
|
// for (ApmRecord record : apmRecordList) {
|
|
|
|
|
// if (apmDay == null) {
|
|
|
|
|
// apmDay = record.getApmDay();
|
|
|
|
|
// }
|
|
|
|
|
// if (cardNo == null) {
|
|
|
|
|
// cardNo = record.getCupCardNo();
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// if (!DateUtil.format(apmDay, DateUtil.PATTERN_DATE).equals(DateUtil.format(record.getApmDay(), DateUtil.PATTERN_DATE))) {
|
|
|
|
|
// return R.fail("预约失败, 一次只能预约同一天的体检项目");
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// if (!cardNo.equals(record.getCupCardNo())) {
|
|
|
|
|
// return R.fail("预约失败, 一次只能预约同一个人");
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// record.setApmTime(DateUtil.now());
|
|
|
|
|
// record.setApmStatus(BusinessConstant.RECORD_STATUS_UNREGISTER);
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// String checkMsg = recordService.checkApmRecordSave(apmRecordList);
|
|
|
|
|
// if (Func.isBlank(checkMsg)) {
|
|
|
|
|
// recordService.saveBatch(apmRecordList);
|
|
|
|
|
// return R.status(true);
|
|
|
|
|
// }
|
|
|
|
|
// return R.fail(checkMsg);
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 新增 |
|
|
|
|
*/ |
|
|
|
|
@ -219,6 +178,7 @@ public class ApmRecordController extends BladeController { |
|
|
|
|
for (Map<String, Object> item : apmRecordMapList) { |
|
|
|
|
ApmRecord record = BeanUtil.copy(item, ApmRecord.class); |
|
|
|
|
record.setApmDay(DateUtil.parse(item.get("apmDay").toString(), DateUtil.PATTERN_DATE)); |
|
|
|
|
record.setCreateDept(Long.parseLong(item.get("createDept").toString())); |
|
|
|
|
if (apmDay == null) { |
|
|
|
|
apmDay = record.getApmDay(); |
|
|
|
|
} |
|
|
|
|
|