| | |
| | | |
| | | @Override |
| | | public ResponseDto pushData(ApiParam param, ApiConfs conf, Object data) { |
| | | if (Constant.API_CODE_1501.equals(param.getInteId()) |
| | | || Constant.API_CODE_1502.equals(param.getInteId()) |
| | | || Constant.API_CODE_1503.equals(param.getInteId())) { |
| | | if (Constant.API_CODE_1114_1501.equals(param.getInteId()) |
| | | || Constant.API_CODE_1114_1502.equals(param.getInteId()) |
| | | || Constant.API_CODE_1114_1503.equals(param.getInteId())) { |
| | | return pushFinanceData(param, conf, data); |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | List<GDFinanceDto> list = null; |
| | | if (Constant.API_CODE_1501.equals(param.getInteId())) { |
| | | if (Constant.API_CODE_1114_1501.equals(param.getInteId())) { |
| | | list = copyApi1501((Api1501) data); |
| | | } else if (Constant.API_CODE_1502.equals(param.getInteId())) { |
| | | } else if (Constant.API_CODE_1114_1502.equals(param.getInteId())) { |
| | | list = copyApi1502((Api1502) data); |
| | | } else if (Constant.API_CODE_1503.equals(param.getInteId())) { |
| | | } else if (Constant.API_CODE_1114_1503.equals(param.getInteId())) { |
| | | list = copyApi1503((Api1503) data); |
| | | } |
| | | GD2022ResponseDto responseDto; |
| | |
| | | } |
| | | if (Constant.API_CODE_1208.equals(inteId)) { |
| | | Gd2022Api1208 api1208 = new Gd2022Api1208(); |
| | | BeanUtils.copyProperties(data, api1208); |
| | | //包装储粮是,核查包存粮包数 |
| | | if(null == api1208.getBclbs()){ |
| | | api1208.setBclbs(0); |
| | |
| | | String tyhwbm = apiCommonService.getTyhwbm(api1208.getHwdm()); |
| | | api1208.setTyhwbm(tyhwbm); |
| | | } |
| | | BeanUtils.copyProperties(data, api1208); |
| | | return JSON.toJSONString(api1208); |
| | | } |
| | | if (Constant.API_CODE_1209.equals(inteId)) { |
| | |
| | | if (Constant.API_CODE_1309.equals(inteId)) { |
| | | Api1309 apiData = (Api1309) data; |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(apiData.getTydwbm())){ |
| | | if(StringUtils.isEmpty(apiData.getWgdwtybm())){ |
| | | String tydwbm = apiCommonService.getTydwbm(apiData.getQydm()); |
| | | apiData.setTydwbm(tydwbm); |
| | | apiData.setWgdwtybm(tydwbm); |
| | | } |
| | | apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | return JSON.toJSONString(apiData); |
| | |
| | | lcsl += gd2022Api1404.getLhsl(); |
| | | } |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(gd2022Api1404.getTyhwbm())){ |
| | | if(StringUtils.isEmpty(gd2022Api1404.getLhhwtybm())){ |
| | | String tyhwbm = apiCommonService.getTyhwbm(gd2022Api1404.getLhhwdm()); |
| | | gd2022Api1404.setTyhwbm(tyhwbm); |
| | | gd2022Api1404.setLhhwtybm(tyhwbm); |
| | | } |
| | | gd2022Api1404.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | dtls.add(gd2022Api1404); |
| | | } |
| | | } |
| | | |
| | | api1403.setRotationInQty(lrsl); |
| | | api1403.setRotationOutQty(lcsl); |
| | | api1403.setDtls(dtls); |
| | |
| | | //设置上传文件id |
| | | api1403.setFileStorageId((String) responseDto.getData()); |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(api1403.getTydwbm())){ |
| | | if(StringUtils.isEmpty(api1403.getJhxddwtybm())){ |
| | | String tydwbm = apiCommonService.getTydwbm(api1403.getJhxddw()); |
| | | api1403.setTydwbm(tydwbm); |
| | | api1403.setJhxddwtybm(tydwbm); |
| | | } |
| | | api1403.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | return JSON.toJSONString(api1403); |
| | |
| | | apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | return JSON.toJSONString(apiData); |
| | | } |
| | | if (ApiCodeConstant.API_2001.equals(inteId)) { |
| | | Gd2022Api2001 apiData = (Gd2022Api2001) data; |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(apiData.getTycfbm())){ |
| | | String tycfbm = apiCommonService.getTycfbm(apiData.getCfdm()); |
| | | apiData.setTycfbm(tycfbm); |
| | | } |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(apiData.getTyajbm())){ |
| | | String tyajbm = apiCommonService.getTyajbm(apiData.getAjdm()); |
| | | apiData.setTyajbm(tyajbm); |
| | | } |
| | | apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | return JSON.toJSONString(apiData); |
| | | } |
| | | if (ApiCodeConstant.API_2002.equals(inteId)) { |
| | | Gd2022Api2002 apiData = (Gd2022Api2002) data; |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(apiData.getTycfbm())){ |
| | | String tycfbm = apiCommonService.getTycfbm(apiData.getCfdm()); |
| | | apiData.setTycfbm(tycfbm); |
| | | } |
| | | //校验统一编码是否为空,为空则查询信息进行赋值 |
| | | if(StringUtils.isEmpty(apiData.getTyajbm())){ |
| | | String tyajbm = apiCommonService.getTyajbm(apiData.getAjdm()); |
| | | apiData.setTyajbm(tyajbm); |
| | | } |
| | | apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); |
| | | return JSON.toJSONString(apiData); |
| | | } |
| | | return JSON.toJSONString(data); |
| | | } |
| | | |