@Override public Long saveOrUpdateHX_user(HX_user hx_user, String userId, String nickName) { HX_userPO hx_userPO = new HX_userPO(); if (hx_user != null) { hx_userPO.setHx_password(hx_user.getPassword()); hx_userPO.setHx_username(hx_user.getUsername()); hx_userPO.setNickname(nickName); hx_userPO.setUserId(Long.valueOf(userId)); } return hX_userDao.createHX_user(hx_userPO); }
@Override public void updateHX_user(HX_user hx_user) { HX_userPO hx_userPO = new HX_userPO(); if (hx_user != null) { hx_userPO.setHx_password(hx_user.getPassword()); hx_userPO.setHx_username(hx_user.getUsername()); hx_userPO.setNickname(hx_user.getNickName()); hx_userPO.setUserId(Long.valueOf(hx_user.getUserId())); hx_userPO.setId(hx_user.getId()); } hX_userDao.updateHX_user(hx_userPO); }