| | |
| | | Api1301 data = new Api1301(); |
| | | BeanUtils.copyProperties(entity, data); |
| | | |
| | | if (StringUtils.isEmpty(data.getId())) { |
| | | data.setId(ContextUtil.getUUID()); |
| | | } |
| | | api1301Rep.save(data); |
| | | } |
| | | |
| | |
| | | @Expose |
| | | public String delData(Api1301 data) { |
| | | |
| | | api1301Rep.deleteById(data.getId()); |
| | | api1301Rep.deleteById(data.getFxdbm()); |
| | | |
| | | return null; |
| | | } |
| | |
| | | ApiRemoteService apiService = apiPushManager.getApiRemoteService(apiConf.getPushProtocol()); |
| | | if (null == apiService) return "系统没有当前推送协议配置,执行失败"; |
| | | |
| | | if (PushProtocol.SB_SH_2023.getCode().equals(apiConf.getPushProtocol())) { |
| | | return pushDataList(items, apiService, apiConf); |
| | | } |
| | | return pushDataSingle(items, apiService, apiConf); |
| | | } |
| | | |
| | |
| | | responseDto = apiService.pushData(param, apiConf, d); |
| | | result += responseDto.toString(); |
| | | if (responseDto.getSuccess() == 0) { |
| | | //todo 代表上传成功 ,后期需要保存日志 |
| | | if ("i".equals(d.getCzbz())) { |
| | | d.setCzbz("u"); |
| | | if (Constant.CZBZ_I.equals(d.getCzbz())) { |
| | | d.setCzbz(Constant.CZBZ_U); |
| | | api1301Rep.save(d); |
| | | } |
| | | } |