parent
8da55ea63b
commit
33e48c8111
|
|
@ -188,7 +188,7 @@ public class ElderApi {
|
|||
IPage<OrgAllInfoApiEntity> list = orgApplyInfoApi.queryOrgAllInfo(pageNo, pageSize, orgCode, null);
|
||||
|
||||
List<OrgAllInfoApiEntity> records = list.getRecords();
|
||||
System.out.println("1111111111111111111:"+orgCode+"----------"+records);
|
||||
System.out.println("1111111111111111111:" + orgCode + "----------" + records);
|
||||
if (records == null || records.size() == 0) {
|
||||
return Result.ok(null);
|
||||
}
|
||||
|
|
@ -198,16 +198,17 @@ public class ElderApi {
|
|||
JSONObject orgInfo = null;
|
||||
try {
|
||||
orgInfo = sysBaseAPI.getOrgInfo(orgCode, "payable_amount");
|
||||
System.out.println("2222222222222222222222:"+orgInfo);
|
||||
System.out.println("2222222222222222222222:" + orgInfo);
|
||||
} finally {
|
||||
DynamicDataSourceContextHolder.clear();
|
||||
}
|
||||
result.setNuId(nuId);
|
||||
if (orgInfo != null && StringUtils.isNotBlank(orgInfo.getString("payableAmount"))) {
|
||||
result.setPayableAmount(new BigDecimal(orgInfo.getString("payableAmount")));
|
||||
System.out.println("2222222222222222222222:"+orgInfo);
|
||||
System.out.println("2222222222222222222222:" + orgInfo);
|
||||
} else {
|
||||
result.setNuCanUse("1");
|
||||
result.setMsg("护理单元暂时无法绑定");
|
||||
result.setMsg("未设置缴费金额");
|
||||
return Result.ok(result);
|
||||
}
|
||||
|
||||
|
|
@ -215,7 +216,6 @@ public class ElderApi {
|
|||
if (baseInfo == null) {
|
||||
return Result.ok(null);
|
||||
}
|
||||
result.setNuId(nuId);
|
||||
result.setNuStatus(baseInfo.getStatus());//使用状态 0未使用 1占用 2入住 3退住 4留床
|
||||
|
||||
//===!!!如果改变绑定规则 业务端同时也需要修改!!!===
|
||||
|
|
@ -340,8 +340,8 @@ public class ElderApi {
|
|||
}
|
||||
}
|
||||
|
||||
ElderInfoEntity elderInfoEn1 = elderInfoApi.getElederInfo(elderInfoEntity.getOrgCode(),elderInfoEntity.getIdCard());
|
||||
if(elderInfoEn1!=null && StringUtils.isNotBlank(elderInfoEn1.getNuId())){
|
||||
ElderInfoEntity elderInfoEn1 = elderInfoApi.getElederInfo(elderInfoEntity.getOrgCode(), elderInfoEntity.getIdCard());
|
||||
if (elderInfoEn1 != null && StringUtils.isNotBlank(elderInfoEn1.getNuId())) {
|
||||
return Result.error("此长者入住中,不可变更");
|
||||
}
|
||||
|
||||
|
|
@ -395,8 +395,8 @@ public class ElderApi {
|
|||
if (NuRedisUtils.existKey(ukey)) {
|
||||
return Result.error("提交过于频繁,请稍后重试");
|
||||
}
|
||||
ElderInfoEntity elderInfoEn = elderInfoApi.getElederInfo(elderInfoEntity.getOrgCode(),elderInfoEntity.getIdCard());
|
||||
if(elderInfoEn!=null && StringUtils.isNotBlank(elderInfoEn.getNuId()) && !StringUtils.equals(elderInfoEntity.getNuId(),elderInfoEn.getNuId()) && StringUtils.equals("zz",elderInfoEntity.getModifyType())){
|
||||
ElderInfoEntity elderInfoEn = elderInfoApi.getElederInfo(elderInfoEntity.getOrgCode(), elderInfoEntity.getIdCard());
|
||||
if (elderInfoEn != null && StringUtils.isNotBlank(elderInfoEn.getNuId()) && !StringUtils.equals(elderInfoEntity.getNuId(), elderInfoEn.getNuId()) && StringUtils.equals("zz", elderInfoEntity.getModifyType())) {
|
||||
return Result.error("此长者入住中,不可变更");
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -438,7 +438,7 @@ public class CommonController {
|
|||
* @return
|
||||
*/
|
||||
@PostMapping(value = "/static/upload/export")
|
||||
public Result<?> upload(@RequestParam(value = "name", defaultValue = "aaa") String secureKey, @RequestParam(value = "size",defaultValue = "1") String fileSize, HttpServletRequest request, HttpServletResponse response) throws Exception {
|
||||
public Result<?> upload(@RequestParam(value = "name", defaultValue = "aaa") String secureKey, @RequestParam(value = "size", defaultValue = "1") String fileSize, HttpServletRequest request, HttpServletResponse response) throws Exception {
|
||||
Result<?> result = new Result<>();
|
||||
//先验证秘钥是否正确
|
||||
if (!SafetyUtil.validateSecureKey(secureKey)) {
|
||||
|
|
@ -453,13 +453,18 @@ public class CommonController {
|
|||
//验证文件名称、大小是否可具备存储“资格”
|
||||
{
|
||||
boolean contains = redisUtil.sGet("canuploadparams").contains(file.getOriginalFilename() + "-" + fileSize);
|
||||
if (!contains) {
|
||||
String[] s = file.getOriginalFilename().split("_");
|
||||
boolean containsSub = false;
|
||||
if (s.length > 1) {
|
||||
containsSub = redisUtil.sGet("canuploadparams").contains(file.getOriginalFilename().split("_")[1] + "-" + fileSize);
|
||||
}
|
||||
if (contains || containsSub) {
|
||||
//删除set中元素
|
||||
redisUtil.setRemove("canuploadparams", file.getOriginalFilename() + "-" + fileSize);
|
||||
} else {
|
||||
result.setMessage("上传失败!");
|
||||
result.setSuccess(false);
|
||||
return result;
|
||||
} else {
|
||||
//删除set中元素
|
||||
redisUtil.setRemove("canuploadparams", file.getOriginalFilename() + "-" + fileSize);
|
||||
}
|
||||
}
|
||||
String savePath = "";
|
||||
|
|
|
|||
Loading…
Reference in New Issue