| | |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | @Component |
| | | public class SH2023PushService11 implements PushService11 { |
| | | |
| | | |
| | | @Autowired |
| | | private SH2023ApiRemoteService apiRemoteService; |
| | | @Autowired |
| | | private Api1101Rep api1101Rep; |
| | | @Autowired |
| | |
| | | private Api1112Rep api1112Rep; |
| | | @Autowired |
| | | private Api1113Rep api1113Rep; |
| | | @Autowired |
| | | private Api1501Rep api1501Rep; |
| | | @Autowired |
| | | private Api1502Rep api1502Rep; |
| | | @Autowired |
| | | private Api1503Rep api1503Rep; |
| | | |
| | | @Override |
| | | public String getProtocol() { |
| | |
| | | @Override |
| | | public void pushData(ApiParam param) { |
| | | |
| | | log.info("------->>>>基础信息 接口模块上报开始"); |
| | | log.info("------->>>>上海2023接口不主动上报"); |
| | | |
| | | //推送单位信息 |
| | | this.pushData1101(apiRemoteService, param); |
| | | //库区信息 |
| | | this.pushData1102(apiRemoteService, param); |
| | | //仓房信息 |
| | | this.pushData1103(apiRemoteService, param); |
| | | //廒间信息 |
| | | this.pushData1104(apiRemoteService, param); |
| | | //货位信息 |
| | | this.pushData1105(apiRemoteService, param); |
| | | //油罐信息 |
| | | this.pushData1106(apiRemoteService, param); |
| | | //设备信息 |
| | | this.pushData1107(apiRemoteService, param); |
| | | //药剂信息 |
| | | this.pushData1108(apiRemoteService, param); |
| | | //文件信息 |
| | | this.pushData1109(apiRemoteService, param); |
| | | //库区图仓房点位标注 |
| | | this.pushData1110(apiRemoteService, param); |
| | | //库区图视频监控设备点位标注 |
| | | this.pushData1111(apiRemoteService, param); |
| | | //人员信息 |
| | | this.pushData1112(apiRemoteService, param); |
| | | //企业信用信息 |
| | | this.pushData1113(apiRemoteService, param); |
| | | //财务报表 |
| | | this.pushData1114(apiRemoteService, param); |
| | | // //推送单位信息 |
| | | // this.pushData1101(apiRemoteService, param); |
| | | // //库区信息 |
| | | // this.pushData1102(apiRemoteService, param); |
| | | // //仓房信息 |
| | | // this.pushData1103(apiRemoteService, param); |
| | | // //廒间信息 |
| | | // this.pushData1104(apiRemoteService, param); |
| | | // //货位信息 |
| | | // this.pushData1105(apiRemoteService, param); |
| | | // //油罐信息 |
| | | // this.pushData1106(apiRemoteService, param); |
| | | // //设备信息 |
| | | // this.pushData1107(apiRemoteService, param); |
| | | // //药剂信息 |
| | | // this.pushData1108(apiRemoteService, param); |
| | | // //文件信息 |
| | | // this.pushData1109(apiRemoteService, param); |
| | | // //库区图仓房点位标注 |
| | | // this.pushData1110(apiRemoteService, param); |
| | | // //库区图视频监控设备点位标注 |
| | | // this.pushData1111(apiRemoteService, param); |
| | | // //人员信息 |
| | | // this.pushData1112(apiRemoteService, param); |
| | | // //企业信用信息 |
| | | // this.pushData1113(apiRemoteService, param); |
| | | // //财务报表 |
| | | // this.pushData1114(apiRemoteService, param); |
| | | |
| | | log.info("------->>>>基础信息 接口模块上报结束"); |
| | | } |
| | |
| | | log.error("-----上海市平台2023版:未获取到单位信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1101); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1101 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1101Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1101 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1101Rep.updateStatus(data.getDwdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1102(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取库区信息 |
| | | List<Api1102> list = api1102Rep.findPushData(param.getKqdm()); |
| | | List<Api1102> list = api1102Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到库区信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1102); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1102 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1102Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1102 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1102Rep.updateStatus(data.getKqdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | public void pushData1103(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取仓房信息 |
| | | List<Api1103> list = api1103Rep.findPushData(param.getKqdm()); |
| | | List<Api1103> list = api1103Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到仓房信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1103); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1103 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1103Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1103 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1103Rep.updateStatus(data.getCfdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1104(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取廒间信息 |
| | | List<Api1104> list = api1104Rep.findPushData(param.getKqdm()); |
| | | List<Api1104> list = api1104Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到廒间信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1104); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1104 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1104Rep.save(data); |
| | | ResponseDto responseDto; |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1104 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1103Rep.updateStatus(data.getAjdh(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1105(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取货位信息 |
| | | List<Api1105> list = api1105Rep.findPushData(param.getKqdm()); |
| | | List<Api1105> list = api1105Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到货位信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1105); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1105 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1105Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1105 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1105Rep.updateStatus(data.getHwdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | public void pushData1106(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取油罐信息 |
| | | List<Api1106> list = api1106Rep.findPushData(param.getKqdm()); |
| | | List<Api1106> list = api1106Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到油罐信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1106); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1106 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1106Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1106 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1106Rep.updateStatus(data.getYgdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1107(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取设备信息 |
| | | List<Api1107> list = api1107Rep.findPushData(param.getKqdm()); |
| | | List<Api1107> list = api1107Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到设备信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1107); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1107 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1107Rep.save(data); |
| | | ResponseDto responseDto; |
| | | |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1107 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1107Rep.updateStatus(data.getSbbh(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1108(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取药剂信息 |
| | | List<Api1108> list = api1108Rep.findPushData(param.getKqdm()); |
| | | List<Api1108> list = api1108Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到药剂信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1108); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1108 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1108Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1108 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1108Rep.updateStatus(data.getId(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | public void pushData1109(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取文件信息 |
| | | List<Api1109> list = api1109Rep.findPushData(param.getKqdm()); |
| | | List<Api1109> list = api1109Rep.findPushDataByTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到文件信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1109); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1109 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1109Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1109 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1109Rep.updateStatus(data.getId(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1110(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取库区图仓房点位标注 |
| | | List<Api1110> list = api1110Rep.findPushData(param.getKqdm()); |
| | | List<Api1110> list = api1110Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到库区图仓房点位标注,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1110); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1110 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1110Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1110 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1110Rep.updateStatus(data.getHwdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1111(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取库区图视频监控设备点位标注 |
| | | List<Api1111> list = api1111Rep.findPushData(param.getKqdm()); |
| | | List<Api1111> list = api1111Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到库区图视频监控设备点位标注,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1111); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1111 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1111Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1111 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1111Rep.updateStatus(data.getSpjksbid(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | */ |
| | | public void pushData1112(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取人员信息 |
| | | List<Api1112> list = api1112Rep.findPushData(param.getKqdm()); |
| | | List<Api1112> list = api1112Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到人员信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1112); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1112 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | ResponseDto responseDto; |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1112Rep.save(data); |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1112 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1112Rep.updateStatus(data.getSfzhm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | public void pushData1113(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取企业信用信息 |
| | | List<Api1113> list = api1113Rep.findPushData(param.getKqdm()); |
| | | List<Api1113> list = api1113Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到企业信用信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteCategory(Constant.API_CATEGORY_11); |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1113); |
| | | //推送,数据为集合形式 |
| | | ResponseDto responseDto = apiRemoteService.pushData(param, list); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //推送成功,更新数据上传状态 |
| | | for (Api1113 data : list) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1113Rep.save(data); |
| | | ResponseDto responseDto; |
| | | for (Api1113 data : list) { |
| | | param.setBizId(data.getBizId()); |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | api1113Rep.updateStatus(data.getDwdm(), Constant.CZBZ_U); |
| | | } |
| | | } |
| | | } |
| | |
| | | * 1114 财务报表 |
| | | */ |
| | | public void pushData1114(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //TODO |
| | | this.pushData1501(apiRemoteService, param); |
| | | this.pushData1502(apiRemoteService, param); |
| | | this.pushData1503(apiRemoteService, param); |
| | | |
| | | } |
| | | |
| | | /** |
| | | * 1501 财务报表-资产负债--单条上传 |
| | | */ |
| | | public void pushData1501(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取财务报表-资产负债 |
| | | List<Api1501> list = api1501Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到资产负债信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1114_1501); |
| | | ResponseDto responseDto; |
| | | Api1501 d; |
| | | for (Api1501 data : list) { |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1501Rep.save(data); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 1502 财务报表-现金流 |
| | | */ |
| | | public void pushData1502(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取财务报表-资产负债 |
| | | List<Api1502> list = api1502Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到现金流信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1114_1502); |
| | | ResponseDto responseDto; |
| | | for (Api1502 data : list) { |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1502Rep.save(data); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 1503 财务报表-利润信息 |
| | | */ |
| | | public void pushData1503(ApiRemoteService apiRemoteService, ApiParam param) { |
| | | //获取财务报表-资产负债 |
| | | List<Api1503> list = api1503Rep.findPushDataTime(param.getKqdm(), param.getStart(), param.getEnd()); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | log.error("-----上海市平台2023版:未获取到利润信息,不推送-----"); |
| | | return; |
| | | } |
| | | param.setInteId(SH2023Constant.SH_2023_API_CODE_1114_1503); |
| | | ResponseDto responseDto; |
| | | Api1503 d; |
| | | for (Api1503 data : list) { |
| | | responseDto = apiRemoteService.pushData(param, data); |
| | | if (responseDto.getSuccess() == 0) { |
| | | if (Constant.CZBZ_I.equals(data.getCzbz())) { |
| | | |
| | | data.setCzbz(Constant.CZBZ_U); |
| | | //更新状态 |
| | | api1503Rep.save(data); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |