From 272a04994393e94b765bcc47a98d2d79cd2e66fa Mon Sep 17 00:00:00 2001 From: zoujiangtao Date: Wed, 26 Feb 2025 10:33:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E5=86=85=E5=AE=B9=EF=BC=9A?= =?UTF-8?q?=E6=95=B4=E4=BD=93=E4=BB=A3=E7=A0=81=E6=9B=B4=E6=96=B0=20?= =?UTF-8?q?=E5=A4=87=E6=B3=A8=EF=BC=9A=E6=95=B4=E4=BD=93=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=EF=BC=88=E6=96=B0=E5=A2=9E=E9=93=B6=E8=A1=8C?= =?UTF-8?q?=E6=94=B6=E4=BB=98=E5=A4=84=E7=90=86/=E7=94=B5=E5=AD=90?= =?UTF-8?q?=E5=9B=9E=E5=8D=95=E8=B0=83=E5=BA=A6=E8=AE=A1=E5=88=92=E4=BA=8C?= =?UTF-8?q?=E5=BC=80=E4=BB=A3=E7=A0=81=EF=BC=89=20=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E4=BA=BA=EF=BC=9A=E9=82=B9=E6=B1=9F=E6=B6=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../shkd/sys/sys/mservice/ApiService.java | 10 +- .../sys/sys/mservice/FundingPlanService.java | 98 +++++++++++++++++++ .../sys/plugin/api/PayBillApiSavePlugin.java | 4 +- 3 files changed, 105 insertions(+), 7 deletions(-) create mode 100644 sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/FundingPlanService.java diff --git a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/ApiService.java b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/ApiService.java index 45927f1..b76b39d 100644 --- a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/ApiService.java +++ b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/ApiService.java @@ -242,7 +242,7 @@ public class ApiService { switch (saveUrl) { // 付款处理 - case "https://biptestctny.invest.com.cn:8002/iuap-api-auth/yonbip/fi/fundpayment/save": + case "https://10.1.9.43/iuap-api-auth/yonbip/fi/fundpayment/save": // 保存 saveResponseBody = pushBill(token, saveUrl, saveRequestBody); logger.info("付款处理 → BIP保存接口 → 返回结果:{}", saveResponseBody); @@ -271,7 +271,7 @@ public class ApiService { break; // 收款处理 - case "https://biptestctny.invest.com.cn:8002/iuap-api-auth/yonbip/fi/fundcollection/save": + case "https://10.1.9.43/iuap-api-auth/yonbip/fi/fundcollection/save": saveResponseBody = pushBill(token, saveUrl, saveRequestBody); logger.info("收款处理 → BIP保存接口 → 返回结果:{}", saveResponseBody); jsonObject = JSON.parseObject(saveResponseBody); @@ -298,7 +298,7 @@ public class ApiService { break; // 银行收付处理 - case "https://biptestctny.invest.com.cn:8002/iuap-api-auth/yonbip/ctm/cmp/bankReconciliationBatchSave": + case "https://10.1.9.43/iuap-api-auth/yonbip/ctm/cmp/bankReconciliationBatchSave": saveResponseBody = pushBill(token, saveUrl, saveRequestBody); jsonObject = JSON.parseObject(saveResponseBody); code = jsonObject.getString("code"); @@ -329,7 +329,7 @@ public class ApiService { } break; // 支付结果 - case "https://biptestctny.invest.com.cn:8002/iuap-api-auth/yonbip/ctm/api/settlement/feedback": + case "https://10.1.9.43/iuap-api-auth/yonbip/ctm/api/settlement/feedback": saveResponseBody = pushBill(token, saveUrl, saveRequestBody); jsonObject = JSON.parseObject(saveResponseBody); code = jsonObject.getString("code"); @@ -355,7 +355,7 @@ public class ApiService { } break; // 电子回单 - case "https://biptestctny.invest.com.cn:8002/iuap-api-auth/yonbip/ctm/bank/tran/add": + case "https://10.1.9.43/iuap-api-auth/yonbip/ctm/bank/tran/add": logger.info("电子回单查询 → BIP推送接口 → \nToken:{}\n链接:{}\n请求体:{}", token, saveUrl, saveRequestBody); saveResponseBody = pushBill(token, saveUrl, saveRequestBody); logger.info("电子回单查询 → BIP推送接口 → 返回结果:{}", saveResponseBody); diff --git a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/FundingPlanService.java b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/FundingPlanService.java new file mode 100644 index 0000000..5661daf --- /dev/null +++ b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/mservice/FundingPlanService.java @@ -0,0 +1,98 @@ +package shkd.sys.sys.mservice; + +import kd.tmc.fpm.business.dataproc.save.ReportDataSDKService; +import kd.bos.login.actions.SerializationUtils; +import kd.tmc.fpm.business.dataproc.save.ReportDataSaveObject; +import kd.tmc.fpm.business.domain.service.FpmOperateResult; + +/** + * @Description + * @Author Tao + * @Date 2025/2/24 + */ +public class FundingPlanService { + public static void writeData() { + /** + * private @ApiParam("报表数据Id") Long reportId; + * private @ApiParam("报表数据reportDataId") Long reportDataId; + * private @ApiParam("体系ID") Long systemId; + * private @ApiParam("模板ID") Long templateId; + * private @ApiParam("模板名称") String templateName; + * private @ApiParam("编报期间ID") Long reportPeriodId; + * private @ApiParam("编报主体ID") Long reportOrgId; + * private @ApiParam("编报主体") List reportOrgIds; + * private @ApiParam("币种ID") Long currencyId; + * private @ApiParam("计划科目ID") Long subjectId; + * private @ApiParam("公司ID") Long companyId; + * private @ApiParam("结算方式ID") Long settleTypeId; + * private @ApiParam("主维度数据分录期间ID") Long entryPeriodId; + * private @ApiParam("度量值列表") List MetricMembers; + * private @ApiParam("上报计划额度") BigDecimal reportPlanAmt; + * private @ApiParam("原始计划额度(核定额度)") BigDecimal originalPlanAmt; + * private @ApiParam("计划参考值") BigDecimal planReferenceAmt; + * private @ApiParam("抵消金额") BigDecimal offsetAmt; + * private @ApiParam("实际数") BigDecimal actAmt; + * private @ApiParam("预占数") BigDecimal lockAmt; + * private @ApiParam("报表状态") ReportStatus reportStatus; + * private @ApiParam("生效状态") Boolean effectFlag; + */ + + /* // 1. 构造请求参数 + ReportDataSaveObject requestObject = new ReportDataSaveObject(); + // 报表数据Id + requestObject.setReportId(); + // 报表数据reportDataId + requestObject.setReportDataId(); + // 体系ID 必填 + requestObject.setSystemId(); + // 模板ID + requestObject.setTemplateId(); + // 模板名称 + requestObject.setTemplateName(); + // 编报期间ID + requestObject.setReportPeriodId(); + // 编报主体ID + requestObject.setReportOrgId(); + // 编报主体 + requestObject.setReportOrgIds(); + // 币种ID + requestObject.setCurrencyId(); + // 计划科目ID + requestObject.setSubjectId(); + // 公司ID + requestObject.setCompanyId(); + // 结算方式ID + requestObject.setSettleTypeId(); + // 主维度数据分录期间ID + requestObject.setEntryPeriodId(); + // 度量值列表 + requestObject.setMetricMembers(); + // 上报计划额度 + requestObject.setReportPlanAmt(); + // 原始计划额度(核定额度) + requestObject.setOriginalPlanAmt(); + // 计划参考值 + requestObject.setPlanReferenceAmt(); + // 抵消金额 + requestObject.setOffsetAmt(); + // 实际数 + requestObject.setActAmt(); + // 预占数 + requestObject.setLockAmt(); + // 报表状态 + requestObject.setReportStatus(); + // 生效状态 + requestObject.setEffectFlag(); + + // 2. 序列化请求参数 + // SerializationUtils 可使用项目包中 kd.bos.login.actions.SerializationUtils, 这里只是给个demo + String qParam = SerializationUtils.serializeToBase64(requestObject); + // 3. 调用SDK接口 + ReportDataSDKService reportDataSDKService = new ReportDataSDKService(); + String result = reportDataSDKService.batchSaveReportData(qParam); + // 4. 反序列化响应结果 + FpmOperateResult responseObject = SerializationUtils.deSerializeFromBase64(result); + System.out.println("响应结果:" + responseObject.getSuccessMessage());*/ + } + +} diff --git a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/api/PayBillApiSavePlugin.java b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/api/PayBillApiSavePlugin.java index a3eda7a..46ff1c0 100644 --- a/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/api/PayBillApiSavePlugin.java +++ b/sys/shkd-sys-sys/src/main/java/shkd/sys/sys/plugin/api/PayBillApiSavePlugin.java @@ -310,7 +310,7 @@ public class PayBillApiSavePlugin implements ApiSavePlugin { map.put("shkd_reebankuser", payeraccount); } else { Map payeraccount = new HashMap<>(); - payeraccount.put("payeraccount", ""); + payeraccount.put("payeraccount", "1111111111"); map.put("shkd_reebankuser", payeraccount); } @@ -339,7 +339,7 @@ public class PayBillApiSavePlugin implements ApiSavePlugin { map.put("shkd_reebankorg", payeraccount); } else { Map payeraccount = new HashMap<>(); - payeraccount.put("bankaccountnumber", ""); + payeraccount.put("bankaccountnumber", "1111111111"); map.put("shkd_reebankorg", payeraccount); } }