Commit 923aa379 authored by Quxl's avatar Quxl

x

parent b4fa2dfe
......@@ -77,14 +77,16 @@ public class AdminUserServiceImpl implements AdminUserService {
@Transactional
public void saveGroupFuns(Integer group_id, Integer[] fun_id) {
jdbcTemplate.executeUpdate("delete from fc_user_group_funs where group_id = ?", group_id);
List<Fc_user_group_funs> list = new ArrayList<Fc_user_group_funs>();
for(Integer i : fun_id) {
Fc_user_group_funs gf = new Fc_user_group_funs();
gf.setGroup_id(group_id);
gf.setFun_id(i);
list.add(gf);
if(fun_id != null && fun_id.length > 0) {
List<Fc_user_group_funs> list = new ArrayList<Fc_user_group_funs>();
for(Integer i : fun_id) {
Fc_user_group_funs gf = new Fc_user_group_funs();
gf.setGroup_id(group_id);
gf.setFun_id(i);
list.add(gf);
}
jdbcTemplate.batchSave(list);
}
jdbcTemplate.batchSave(list);
}
@Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment