Browse Source

公共询价邮件推送方法更新

hejq 8 years ago
parent
commit
f4caf0faaa

+ 4 - 2
src/main/java/com/uas/platform/b2b/listener/MessageListener.java

@@ -118,8 +118,10 @@ public class MessageListener implements ApplicationListener<SaveReleaseEvent<?,
                                 // 先查询客户分配
                                 String sql = "select distinct(purc$distribute.pd_useruu) useruu from purc$distribute left join purc$vendors " +
                                         "on purc$distribute.pd_vdid = purc$vendors.ve_id where purc$vendors.ve_myenuu = " + item.getInquiry().getEnUU() +
-                                        "and purc$vendors.ve_vendenuu = " + enter.getEnuu() + "and purc$distribute.pd_useruu in " +
-                                        "(select user_uu from sec$userenterprise where sec$userenterprise.en_uu = " + enter.getEnuu() + ")";
+                                        " and purc$vendors.ve_vendenuu = " + enter.getEnuu() + " and purc$distribute.pd_useruu in " +
+                                        "(select user_uu from sec$userenterprise where sec$userenterprise.en_uu = " + enter.getEnuu() + ")" +
+                                        "and  purc$distribute.pd_useruu in (select user_uu from sec$userrole where role_id =(select role_id from " +
+                                        "sec$roles where role_enuu = " + enter.getEnuu() + " and role_desc = '业务员'))";
                                 List<UserAndEnterprise> uus = commonDao.query(sql, UserAndEnterprise.class);
                                 if(!CollectionUtils.isEmpty(uus)) {
                                     for(UserAndEnterprise uu : uus) {// 再查询单个物料的分配情况

+ 1 - 1
src/main/webapp/resources/tpl/index/account/add_userInfo.html

@@ -36,7 +36,7 @@
 		</thead>
 		<tbody>
 				<div style="overflow-y:scroll; width:100%;max-height:500px">			
-					<tr ng-repeat="user in userinfos| filter: keyword" ng-if="!user.sys && !user.transfer">
+					<tr ng-repeat="user in userinfos| filter: keyword">
 						<td width="80px;">{{user.userUU}}</td>
 						<td width="100px;">{{user.userName}}</td>
 						<td width="40px;" style="text-align: center"><input ng-model="user.distribute" name="checkbox" ng-click="checkOne()" type="checkbox"></td>