From 684f9a1d95602a1ee9c6be7e428e4b58d3774ac4 Mon Sep 17 00:00:00 2001 From: mzr <1562242162@qq.com> Date: Wed, 12 Mar 2025 10:56:20 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=B8=E9=94=802-=E5=B7=B2=E6=9A=82=E5=81=9C?= =?UTF-8?q?=E5=BC=80=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../web/gl/verify/action/VerifyMulAction.java | 32 +++ .../gl/app/config/authorize/verify.xml | 83 ++++++++ .../gl/verify/config/action/action.xml | 199 ++++++++++++++++++ .../lightgl/verify/VerifyWebServiceImpl.java | 87 +++++--- .../gl/lightgl/verify/IVerifyWebService.java | 47 +++++ 5 files changed, 420 insertions(+), 28 deletions(-) create mode 100644 gl/src/client/nccloud/web/gl/verify/action/VerifyMulAction.java create mode 100644 gl/src/client/yyconfig/modules/gl/app/config/authorize/verify.xml create mode 100644 gl/src/client/yyconfig/modules/gl/verify/config/action/action.xml create mode 100644 gl/src/public/nccloud/pubitf/gl/lightgl/verify/IVerifyWebService.java diff --git a/gl/src/client/nccloud/web/gl/verify/action/VerifyMulAction.java b/gl/src/client/nccloud/web/gl/verify/action/VerifyMulAction.java new file mode 100644 index 0000000..986d2c1 --- /dev/null +++ b/gl/src/client/nccloud/web/gl/verify/action/VerifyMulAction.java @@ -0,0 +1,32 @@ +// +// Source code recreated from a .class file by IntelliJ IDEA +// (powered by FernFlower decompiler) +// + +package nccloud.web.gl.verify.action; + +import nc.vo.pub.BusinessException; +import nccloud.dto.gl.verify.VerifyInfoWebVO; +import nccloud.framework.core.exception.ExceptionUtils; +import nccloud.framework.service.ServiceLocator; +import nccloud.framework.web.action.itf.ICommonAction; +import nccloud.framework.web.container.IRequest; +import nccloud.framework.web.json.JsonFactory; +import nccloud.pubitf.gl.lightgl.verify.IVerifyWebService; + +public class VerifyMulAction implements ICommonAction { + public VerifyMulAction() { + } + + public Object doAction(IRequest request) { + String json = request.read(); + VerifyInfoWebVO verifyInfoWebVO = (VerifyInfoWebVO)JsonFactory.create().fromJson(json, VerifyInfoWebVO.class); + + try { + return ((IVerifyWebService)ServiceLocator.find(IVerifyWebService.class)).onVerifyMul(verifyInfoWebVO); + } catch (BusinessException e) { + ExceptionUtils.wrapException(e); + return null; + } + } +} diff --git a/gl/src/client/yyconfig/modules/gl/app/config/authorize/verify.xml b/gl/src/client/yyconfig/modules/gl/app/config/authorize/verify.xml new file mode 100644 index 0000000..2399e69 --- /dev/null +++ b/gl/src/client/yyconfig/modules/gl/app/config/authorize/verify.xml @@ -0,0 +1,83 @@ + + + + 20020NAIPT,20020VRIFY,20020VYOBS,20021DLANL,20021VYBAL,20021VYQRY + + + gl.voucher.queryBookCombineInfo + + >gl.voucher.queryAssItem + + gl.verify.query + + gl.verify.onverify + + gl.verify.onverifyMul + + gl.verify.historyquery + + gl.verify.verhistoryprint + + gl.verify.verhistoryoutput + + gl.verify.verifybeginprint + + gl.verify.verifybeginoutput + + gl.verify.unverify + + gl.verify.onRedBlue + + gl.verify.onAutoVerify + + gl.verify.onAutoRedBlue + + gl.verify.verBalanceQuery + + gl.verify.verbalanceprint + + gl.verify.verbalanceoutput + + gl.verify.verDetailQuery + + gl.verify.verDetailLinkQuery + + gl.verify.accountAgeAnalysis + + gl.verify.accountAgeAnalysisDetail + + gl.verify.badaccountrate + + gl.verify.verifyobjquery + + gl.verify.verifyobjsave + + gl.verify.verifyobjdelete + + gl.verify.verifyobjcheck + + gl.verify.verifyobjenable + + gl.verify.verifyobjdisable + + gl.verify.verifyinitquery + + gl.verify.verifyinitheadtitle + + gl.verify.verifyinitsave + + gl.verify.verifyinitimportqc + + gl.verify.verifyinitfromvoucher + + gl.verify.verifyinitexportexcel + + gl.verify.verifyinitimportexcel + + gl.verify.verifyobjcheckbu + + gl.verify.verifyobjinfo + gl.voucher.voucherRelatedApp + + + diff --git a/gl/src/client/yyconfig/modules/gl/verify/config/action/action.xml b/gl/src/client/yyconfig/modules/gl/verify/config/action/action.xml new file mode 100644 index 0000000..52e8949 --- /dev/null +++ b/gl/src/client/yyconfig/modules/gl/verify/config/action/action.xml @@ -0,0 +1,199 @@ + + + + gl.verify.rtverify + + nccloud.web.gl.verify.action.RTVerifyAction + + + gl.verify.refverify + + nccloud.web.gl.verify.action.RefVerifyAction + + + + gl.verify.query + + nccloud.web.gl.verify.action.QueryVerifyAction + + + + gl.verify.onverify + + nccloud.web.gl.verify.action.VerifyMulAction + + + + gl.verify.onverifyMul + + nccloud.web.gl.verify.action.VerifyMulAction + + + + gl.verify.historyquery + + nccloud.web.gl.verify.action.HistoryQueryAction + + + + gl.verify.verhistoryprint + + nccloud.web.gl.verify.action.VerHistoryPrintAction + + + gl.verify.verhistoryoutput + + nccloud.web.gl.verify.action.VerHistoryOutputAction + + + gl.verify.verifybeginprint + + nccloud.web.gl.verify.action.VerifyBeginPrintAction + + + gl.verify.verifybeginoutput + + nccloud.web.gl.verify.action.VerifyBeginOutputAction + + + gl.verify.unverify + + nccloud.web.gl.verify.action.UnVerifyAction + + + + gl.verify.onRedBlue + + nccloud.web.gl.verify.action.RedBlueAction + + + + gl.verify.onAutoVerify + + nccloud.web.gl.verify.action.AutoVerifyAction + + + + gl.verify.onAutoRedBlue + + nccloud.web.gl.verify.action.AutoRedBlueAction + + + + gl.verify.verBalanceQuery + + nccloud.web.gl.verify.action.VerBalanceQueryAction + + + gl.verify.verbalanceprint + + nccloud.web.gl.verify.action.VerBalancePrintAction + + + gl.verify.verbalanceoutput + + nccloud.web.gl.verify.action.VerBalanceOutputAction + + + gl.verify.verDetailQuery + + nccloud.web.gl.verify.action.VerDetailQueryAction + + + gl.verify.verDetailLinkQuery + + nccloud.web.gl.verify.action.VerDetailLinkQueryAction + + + + gl.verify.accountAgeAnalysis + + nccloud.web.gl.verify.action.AccoungAgeAnalysisAction + + + gl.verify.accountAgeAnalysisDetail + + nccloud.web.gl.verify.action.AccoungAgeAnalysisDetailAction + + + gl.verify.badaccountrate + + nccloud.web.gl.verify.action.BadAccountRateAction + + + + gl.verify.verifyobjquery + + nccloud.web.gl.verify.action.VerifyObjQueryAction + + + gl.verify.verifyobjsave + + nccloud.web.gl.verify.action.VerifyObjSaveAction + + + gl.verify.verifyobjdelete + + nccloud.web.gl.verify.action.VerifyObjDeleteAction + + + gl.verify.verifyobjcheck + + nccloud.web.gl.verify.action.VerifyObjCheckAction + + + gl.verify.verifyobjenable + + nccloud.web.gl.verify.action.VerifyObjEnableAction + + + gl.verify.verifyobjdisable + + nccloud.web.gl.verify.action.VerifyObjDisableAction + + + gl.verify.verifyinitquery + + nccloud.web.gl.verify.action.VerifyInitQueryAction + + + gl.verify.verifyinitheadtitle + + nccloud.web.gl.verify.action.VerifyInitHeadTitleAction + + + gl.verify.verifyinitsave + + nccloud.web.gl.verify.action.VerifyInitSaveAction + + + gl.verify.verifyinitimportqc + + nccloud.web.gl.verify.action.VerifyInitImportQCAction + + + gl.verify.verifyinitfromvoucher + + nccloud.web.gl.verify.action.VerifyInitFromVoucherAction + + + gl.verify.verifyinitexportexcel + + nccloud.web.gl.verify.action.VerifyInitExportExcelAction + + + gl.verify.verifyinitimportexcel + + nccloud.web.gl.verify.action.VerifyInitImportExcelAction + + + gl.verify.verifyobjcheckbu + + nccloud.web.gl.verify.action.VerifyObjCheckBUAction + + + gl.verify.verifyobjinfo + + nccloud.web.gl.verify.action.VerifyObjInfoAction + + diff --git a/gl/src/private/nccloud/pubimpl/gl/lightgl/verify/VerifyWebServiceImpl.java b/gl/src/private/nccloud/pubimpl/gl/lightgl/verify/VerifyWebServiceImpl.java index f3c509d..91c042e 100644 --- a/gl/src/private/nccloud/pubimpl/gl/lightgl/verify/VerifyWebServiceImpl.java +++ b/gl/src/private/nccloud/pubimpl/gl/lightgl/verify/VerifyWebServiceImpl.java @@ -244,8 +244,31 @@ public class VerifyWebServiceImpl implements IVerifyWebService { verifyModel.setDebitVerify(debitVerifyVOs); verifyModel.onVerify(); verifyModel.onQuery(verifyModel.getFilterVO(verifyInfoWebVO.getCondition())); - resultMap.put("credit", verifyModel.getCreditVerifyWebInfo()); - resultMap.put("debit", verifyModel.getDebitVerifyWebInfo()); + Map>[] creditInfo = verifyModel.getCreditVerifyWebInfo(); + Map>[] debitInfo = verifyModel.getDebitVerifyWebInfo(); + setCurrTypeNameForVerify(creditInfo, debitInfo); + resultMap.put("credit", creditInfo); + resultMap.put("debit", debitInfo); + return resultMap; + } + + @Override + public Map onVerifyMul(VerifyInfoWebVO verifyInfoWebVO) throws BusinessException { + Map resultMap = new HashMap(); + GlVerifyWebModel verifyModel = new GlVerifyWebModel(); + verifyModel.setPk_accountingbook((String) verifyInfoWebVO.getCondition().get("pk_accountingbook")); + verifyModel.checkVerifyObj(verifyInfoWebVO.getCondition()); + VerifyDetailVO[] creditVerifyVOs = verifyModel.transferWebToVO(verifyInfoWebVO.getCredit().toArray(new VerifyDetailWebVO[0])); + VerifyDetailVO[] debitVerifyVOs = verifyModel.transferWebToVO(verifyInfoWebVO.getDebit().toArray(new VerifyDetailWebVO[0])); + verifyModel.setCreditVerify(creditVerifyVOs); + verifyModel.setDebitVerify(debitVerifyVOs); + verifyModel.onVerifyMul(); + verifyModel.onQuery(verifyModel.getFilterVO(verifyInfoWebVO.getCondition())); + Map>[] creditInfo = verifyModel.getCreditVerifyWebInfo(); + Map>[] debitInfo = verifyModel.getDebitVerifyWebInfo(); + setCurrTypeNameForVerify(creditInfo, debitInfo); + resultMap.put("credit", creditInfo); + resultMap.put("debit", debitInfo); return resultMap; } @@ -737,23 +760,27 @@ public class VerifyWebServiceImpl implements IVerifyWebService { processCurrencyTypes(debitInfo, pk_currtypes); // ѯ - String pk_currtypeStr = String.join("','", pk_currtypes); - // NCCForUAPLogger.debug("pk_currtypeStr:" + pk_currtypeStr); - String sql = "select pk_currtype, name from bd_currtype where pk_currtype in ('" + pk_currtypeStr + "') and dr = 0"; - List results = (List) new BaseDAO().executeQuery(sql, new MapListProcessor()); + if (!pk_currtypes.isEmpty()) { + String pk_currtypeStr = String.join("','", pk_currtypes); + // NCCForUAPLogger.debug("pk_currtypeStr:" + pk_currtypeStr); + String sql = "select pk_currtype, name from bd_currtype where pk_currtype in ('" + pk_currtypeStr + "') and dr = 0"; + List results = (List) new BaseDAO().executeQuery(sql, new MapListProcessor()); - for (Map result : results) { - String pk_currtype = result.getOrDefault("pk_currtype", "") + ""; - String name = result.getOrDefault("name", "") + ""; - if (pk_currtype.isEmpty() || name.isEmpty()) { - continue; + for (Map result : results) { + String pk_currtype = result.getOrDefault("pk_currtype", "") + ""; + String name = result.getOrDefault("name", "") + ""; + if (pk_currtype.isEmpty() || name.isEmpty()) { + continue; + } + resMap.put(pk_currtype, name); } - resMap.put(pk_currtype, name); } // ñ - setCurrencyNameInArr(creditInfo, resMap); - setCurrencyNameInArr(debitInfo, resMap); + if (!resMap.isEmpty()) { + setCurrencyNameInArr(creditInfo, resMap); + setCurrencyNameInArr(debitInfo, resMap); + } } catch (Exception e) { NCCForUAPLogger.debug("setCurrTypeNameForVerify-exp:" + e.getMessage()); throw new RuntimeException(e); @@ -761,26 +788,30 @@ public class VerifyWebServiceImpl implements IVerifyWebService { } private void processCurrencyTypes(Map>[] infoArray, Set pk_currtypes) { - for (Map> map : infoArray) { - Map currtypeMap = map.get("m_pk_currtype"); - // NCCForUAPLogger.debug("infoArray-m_pk_currtype= " + currtypeMap); - if (!"".equals(currtypeMap.getOrDefault("value", ""))) { - String pk_currtype = currtypeMap.getOrDefault("value", "") + ""; - pk_currtypes.add(pk_currtype); + if (infoArray != null) { + for (Map> map : infoArray) { + Map currtypeMap = map.get("m_pk_currtype"); + // NCCForUAPLogger.debug("infoArray-m_pk_currtype= " + currtypeMap); + if (!"".equals(currtypeMap.getOrDefault("value", ""))) { + String pk_currtype = currtypeMap.getOrDefault("value", "") + ""; + pk_currtypes.add(pk_currtype); + } } } } private void setCurrencyNameInArr(Map>[] infoArray, Map resMap) { - for (Map> map : infoArray) { - Map currtypeMap = map.get("m_pk_currtype"); - String pk_currtype = currtypeMap.getOrDefault("value", "") + ""; - String m_currtypeName = resMap.get(pk_currtype); + if (infoArray != null) { + for (Map> map : infoArray) { + Map currtypeMap = map.get("m_pk_currtype"); + String pk_currtype = currtypeMap.getOrDefault("value", "") + ""; + String m_currtypeName = resMap.get(pk_currtype); - Map currtypeNameMap = new HashMap<>(); - currtypeNameMap.put("value", m_currtypeName); - currtypeNameMap.put("display", m_currtypeName); - map.put("m_currtypeName", currtypeNameMap); + Map currtypeNameMap = new HashMap<>(); + currtypeNameMap.put("value", m_currtypeName); + currtypeNameMap.put("display", m_currtypeName); + map.put("m_currtypeName", currtypeNameMap); + } } } diff --git a/gl/src/public/nccloud/pubitf/gl/lightgl/verify/IVerifyWebService.java b/gl/src/public/nccloud/pubitf/gl/lightgl/verify/IVerifyWebService.java new file mode 100644 index 0000000..b5141c9 --- /dev/null +++ b/gl/src/public/nccloud/pubitf/gl/lightgl/verify/IVerifyWebService.java @@ -0,0 +1,47 @@ +// +// Source code recreated from a .class file by IntelliJ IDEA +// (powered by FernFlower decompiler) +// + +package nccloud.pubitf.gl.lightgl.verify; + +import nc.vo.gl.pubvoucher.DetailVO; +import nc.vo.pub.BusinessException; +import nccloud.dto.gl.verify.VerifyInfoWebVO; + +import java.util.List; +import java.util.Map; + +public interface IVerifyWebService { + Map queryRtVerifyData(String var1, String var2, String var3) throws BusinessException; + + Map queryVerifyDatas(Map var1) throws BusinessException; + + Map onVerify(VerifyInfoWebVO var1) throws BusinessException; + + Map onVerifyMul(VerifyInfoWebVO var1) throws BusinessException; + + Map onAutoVerify(VerifyInfoWebVO var1) throws BusinessException; + + Map queryHistoryDatas(Map var1) throws BusinessException; + + Map unVerify(VerifyInfoWebVO var1) throws BusinessException; + + Map onRedBlue(VerifyInfoWebVO var1) throws BusinessException; + + Map onAutoRedBlue(VerifyInfoWebVO var1) throws BusinessException; + + Map verBalanceQuery(Map var1) throws BusinessException; + + Map verDetailQuery(Map var1) throws BusinessException; + + Map verDetailLinkQuery(VerifyInfoWebVO var1) throws BusinessException; + + Map onQuery(Map var1) throws BusinessException; + + Map onDetailed(Map var1) throws BusinessException; + + Map refVerify(DetailVO var1, String var2) throws BusinessException; + + List queryBadAccountRate(String var1) throws BusinessException; +}