diff --git a/WebContent/Tenwa/Core/FlowManager/BaseFlowList/BaseFlowApplyListStart.jspf b/WebContent/Tenwa/Core/FlowManager/BaseFlowList/BaseFlowApplyListStart.jspf index 3a74541dd..63e7531fb 100644 --- a/WebContent/Tenwa/Core/FlowManager/BaseFlowList/BaseFlowApplyListStart.jspf +++ b/WebContent/Tenwa/Core/FlowManager/BaseFlowList/BaseFlowApplyListStart.jspf @@ -19,6 +19,19 @@ <%/*~BEGIN~可编辑区~[Describe=其它操作;]~*/%> <% + //KKK here update of is before check user in the other -- by K + boolean bFlag = false; + List roles = CurUser.getRoleTable(); + String distributorRole = QuartzPropertiesUtil.get("distributor_role"); + distributorRole = distributorRole == null ? "" : distributorRole; + for(String role : roles) { + if(distributorRole.indexOf(role) != -1) { + bFlag = true; + break; + } + } + //KKK 2.setVisible not show object -- by K + String sApplyType = CurPage.getParameter("ApplyType"); String sPhaseType = CurPage.getParameter("PhaseType"); if(sApplyType == null) sApplyType = ""; @@ -35,6 +48,11 @@ doTemp.setVisible("flow_key", false); doTemp.setVisible("CONTRACT_NO", true); } + //setVisible show Or show don't + if(!("1010".equals(sPhaseType)) && bFlag) { + doTemp.setVisible("ACTION", false); + } + //doTemp.appendJboWhere(applyManager.getWhereClause()+" order by objectNo desc "); doTemp.appendJboWhere(applyManager.getWhereClause()); ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request); @@ -43,14 +61,16 @@ dwTemp.ReadOnly = "1";//编辑模式 dwTemp.genHTMLObjectWindow(""); String sButtons[][] = applyManager.getButtonArr(); - + //vivotab //control distributor(temporary) List buttonLists = Arrays.asList(sButtons); buttonLists = new ArrayList(buttonLists); int num1 = 0; - boolean flag1 = false; + boolean flag1 = false; int num2 = 0; boolean flag2 = false; + int num3 = 0; + boolean flag3 = false; for(int i = 0; i < sButtons.length; i ++) { for(int j = 0; j < sButtons[i].length; j ++) { if("viewFlowGraph()".equals(sButtons[i][j])) { @@ -62,10 +82,17 @@ num2 = i; flag2 = true; break; + } + //jingXiaoShang power limit by K 2018/08/11 + if(!("1010".equals(sPhaseType)) && "viewTab()".equals(sButtons[i][j])) { + num3 = i; + flag3 = true; + break; } } } - boolean bFlag = false; + //KKK this code look top top top + /* boolean bFlag = false; List roles = CurUser.getRoleTable(); String distributorRole = QuartzPropertiesUtil.get("distributor_role"); distributorRole = distributorRole == null ? "" : distributorRole; @@ -74,7 +101,7 @@ bFlag = true; break; } - } + } */ if(bFlag) { if(flag1) { String[] removeB1 = buttonLists.get(num1); @@ -84,6 +111,10 @@ String[] removeB2 = buttonLists.get(num2); buttonLists.remove(removeB2); } + if(flag3) {//jingXiaoShang power limit by K 2018/08/11 + String[] removeB3 = buttonLists.get(num3); + buttonLists.remove(removeB3); + } } sButtons = new String[buttonLists.size()][]; for(int i = 0; i < buttonLists.size(); i ++) {