diff --git a/WebContent/Tenwa/Lease/Flow/RentCollection/rentcollection/rentCollectionList.jsp b/WebContent/Tenwa/Lease/Flow/RentCollection/rentcollection/rentCollectionList.jsp index 87d5d9cd7..522d65546 100644 --- a/WebContent/Tenwa/Lease/Flow/RentCollection/rentcollection/rentCollectionList.jsp +++ b/WebContent/Tenwa/Lease/Flow/RentCollection/rentcollection/rentCollectionList.jsp @@ -21,14 +21,16 @@ roleid = bo.getAttribute("roleid").toString(); roleList.add(roleid); } - - String distributorIds = Sqlca.getString("select concat(distributor_no,'\\',\\'') from distributor_info where orgid = '" + CurUser.getOrgID() + "'"); - String querySql = " and o.distributor_id in ('"+distributorIds+"')"; - String roleidq = Sqlca.getString("select ROLEID from USER_ROLE where USERID='"+CurUser.getUserID()+"'"); - if(!"800R00000043".equals(roleidq)){//重催组用户可以看到全部的 - querySql += " or odi.part_dept='" + userid + "'"; + //经销商用户查看当前渠道所有数据 + String distributorNo = Sqlca.getString("select distributor_no from distributor_info where orgid = '" + CurUser.getOrgID() + "'"); + if(!StringX.isEmpty(distributorNo)){ + doTemp.appendJboWhere(" o.distributor_id = '"+distributorNo+"'"); + } + //重催组角色查看所有,其余角色查看分配给当前角色数据 + String roleidq = Sqlca.getString("select group_concat(roleid) from USER_ROLE where USERID='"+CurUser.getUserID()+"'"); + if(!StringX.isEmpty(roleidq) && !roleidq.contains("800R00000043")){ + doTemp.appendJboWhere(" odi.part_dept='" + userid + "'"); } - doTemp.appendJboWhere(querySql); ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request); dwTemp.Style="1"; //--设置为Grid风格--