|
@@ -169,11 +169,14 @@ public interface SqlConstants {
|
|
|
" and project_id in (select project_id from project_user where user_id = #{userId})";
|
|
|
|
|
|
String UPDATE_REGION_DIRECTOR =
|
|
|
- "<script>"
|
|
|
- + "update project_user set user_id=#{userId} where project_id in"
|
|
|
- + " <foreach item='item' index='index' collection='projectIds' open='(' separator=',' close=')'>"
|
|
|
- + " #{item}"
|
|
|
- + " </foreach>"
|
|
|
- + "and mt_company_id=#{mtCompanyId} and user_role = 'REGION_DIRECTOR'"
|
|
|
- + "</script>";
|
|
|
+ "<script>" +
|
|
|
+ " update project_user set user_id=#{userId} where " +
|
|
|
+ " mt_company_id=#{mtCompanyId} and user_role = 'REGION_DIRECTOR'" +
|
|
|
+ " <if test=\"projectIds != null and projectIds.size > 0 \">" +
|
|
|
+ " and project_id in" +
|
|
|
+ " <foreach item='item' index='index' collection='projectIds' open='(' separator=',' close=')'>" +
|
|
|
+ " #{item}" +
|
|
|
+ " </foreach>" +
|
|
|
+ " </if>" +
|
|
|
+ "</script>";
|
|
|
}
|