From 4a2835ddadb796c69f180097b95f971dbab4687d Mon Sep 17 00:00:00 2001 From: ludc Date: 星期三, 13 九月 2023 09:09:14 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/UBCS/ubcs-codeApply/src/main/java/com/vci/rmip/code/client/codeapply/Apply410/CodeApplyFor410Dialog.java | 44 ++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 42 insertions(+), 2 deletions(-) diff --git a/Source/UBCS/ubcs-codeApply/src/main/java/com/vci/rmip/code/client/codeapply/Apply410/CodeApplyFor410Dialog.java b/Source/UBCS/ubcs-codeApply/src/main/java/com/vci/rmip/code/client/codeapply/Apply410/CodeApplyFor410Dialog.java index e8b5abb..f69c4b8 100644 --- a/Source/UBCS/ubcs-codeApply/src/main/java/com/vci/rmip/code/client/codeapply/Apply410/CodeApplyFor410Dialog.java +++ b/Source/UBCS/ubcs-codeApply/src/main/java/com/vci/rmip/code/client/codeapply/Apply410/CodeApplyFor410Dialog.java @@ -31,7 +31,8 @@ private Component parentComponet = null; private Map<String, String> attrNameAndValMap = new LinkedHashMap();//瀛樺偍灞炴�у悕绉帮紙鍖呭惈鍐呴儴鍚嶇О鍜屽閮ㄥ悕绉帮級鍜屽搴旂殑鍊� private String tokenUrl= ConfigUtils.getConfigValue("410.code.token.url","http://127.0.0.1:37000/ubcs-auth/oauth/token"); - + private String[] fields; + private String[] values; /** * 瀛樺偍鍒嗙被鐨凪ap,key:鍒嗙被鍚嶇О锛寁alue锛氬垎绫诲�� */ @@ -48,6 +49,21 @@ } public CodeApplyFor410Dialog(JDialog dialog, String clsfName, String deptName) { this(dialog, "pdmUser", clsfName, deptName,new String[]{}); + } + public CodeApplyFor410Dialog(JDialog dialog, String clsfName, String deptName,String[] fields,String[] values) { + this(dialog, "pdmUser", clsfName, deptName,new String[]{},fields,values); + } + public CodeApplyFor410Dialog(Frame frame, String clsfName, String deptName,String[] fields,String[] values){ + this.setModal(true); + parentComponet = frame; + this.userName = userName; + this.clsfName = clsfName; + this.deptName = deptName; + this.fields=fields; + this.values=values; + //this.libName = libName; + init(); + } public CodeApplyFor410Dialog(Frame frame, String userName, String clsfName, String deptName, String[] libName){ super(frame, true); @@ -76,6 +92,23 @@ this.deptName = deptName; // this.libName = libName; + init(); + } catch (Exception e) { + e.printStackTrace(); + } + } + + public CodeApplyFor410Dialog(JDialog dialog, String userName, String clsfName, String deptName, String[] libName,String[] fields,String[] values) { + super(dialog, true); + VCISwingUtil.setClientMainFrame(new Frame()); + try { + this.setModal(true); + parentComponet = dialog; + this.userName = userName; + this.clsfName = clsfName; + this.deptName = deptName; + this.fields = fields; + this.values = values; init(); } catch (Exception e) { e.printStackTrace(); @@ -139,7 +172,14 @@ private void bulidPal() throws Exception { this.setDefaultCloseOperation(DISPOSE_ON_CLOSE); this.setTitle("浠g爜鐢宠"); - mainPal = new CodeApplyPanelFor410(this,tokenUserObject, true, clsfName, deptName,libName); + Map<String , String> displayValues = new HashMap<>(); + if(fields != null && fields.length > 0 && values !=null && values.length > 0){ + for (int i = 0; i < fields.length; i++) { + displayValues.put(fields[i] , values[i]); + } + } + + mainPal = new CodeApplyPanelFor410(this,tokenUserObject, true, clsfName, deptName,libName,displayValues); VCIJPanel btnPal = new VCIJPanel(); btnPal.add(okBtn); -- Gitblit v1.9.3