@Test public void updateUser() throws Exception { loginUser.setId(21L); int count = loginUserDao.updateUser(loginUser); System.out.println("updateUser :-------> " + count); Assert.assertTrue(count > 0); }
public int updateUser(LoginUser user) throws SQLException { if (user == null) { return 0; } String sql = "UPDATE login_users SET user_email = ? WHERE id = ?"; return this.updataBysql(sql, Parameter.varcharOf(StringUtils.EMPTY, user.getUserEmail()), Parameter.integerOf(StringUtils.EMPTY, user.getId())); }
LoginUserDao extends BaseDao { public int updateUser(LoginUser user) throws SQLException { if (user == null) { return 0; } String sql = "UPDATE login_users SET user_email = ? WHERE id = ?"; return this.updataBysql(sql, Parameter.varcharOf(StringUtils.EMPTY, user.getUserEmail()), Parameter.integerOf(StringUtils.EMPTY, user.getId())); } }
LoginUserDao extends BaseDao { public int updateUser(LoginUser user) throws SQLException { if (user == null) { return 0; } String sql = "UPDATE login_users SET user_email = ? WHERE id = ?"; return this.updataBysql(sql, Parameter.varcharOf(StringUtils.EMPTY, user.getUserEmail()), Parameter.integerOf(StringUtils.EMPTY, user.getId())); }  }
LoginUserDao extends BaseDao { public int updateUser(LoginUser user) throws SQLException { if (user == null) { return 0; } String sql = "UPDATE login_users SET user_email = ? WHERE id = ?"; return this.updataBysql(sql, Parameter.varcharOf(StringUtils.EMPTY, user.getUserEmail()), Parameter.integerOf(StringUtils.EMPTY, user.getId())); }  Long insertUser(LoginUser user); int initAdmin(LoginUser user); int updateUserPassword(LoginUser user); List<LoginUser> getAllUsers(); LoginUser getUserById(Long userId); LoginUser getUserByNo(String userNo); LoginUser getUserByUserName(String userName); List<LoginUsersView> getUserByGroupId(Long groupId); int updateUser(LoginUser user); int deleteUser(Long userId); Long getTotalCount(Paging<LoginUser> paging); List<LoginUserView> findUserPageList(Paging<LoginUser> paging); }
LoginUserDao extends BaseDao { public int updateUser(LoginUser user) throws SQLException { if (user == null) { return 0; } String sql = "UPDATE login_users SET user_email = ? WHERE id = ?"; return this.updataBysql(sql, Parameter.varcharOf(StringUtils.EMPTY, user.getUserEmail()), Parameter.integerOf(StringUtils.EMPTY, user.getId())); }  Long insertUser(LoginUser user); int initAdmin(LoginUser user); int updateUserPassword(LoginUser user); List<LoginUser> getAllUsers(); LoginUser getUserById(Long userId); LoginUser getUserByNo(String userNo); LoginUser getUserByUserName(String userName); List<LoginUsersView> getUserByGroupId(Long groupId); int updateUser(LoginUser user); int deleteUser(Long userId); Long getTotalCount(Paging<LoginUser> paging); List<LoginUserView> findUserPageList(Paging<LoginUser> paging);  }