public boolean deleteReq(int uidx) { UserMapper userMapper = sqlSession.getMapper(UserMapper.class); if (userMapper != null) { try { userMapper.deleteRequest(uidx); sqlSession.commit(); return true; } catch (Exception e) { return false; } } return false; }
public boolean approveReq(int uidx) { UserMapper userMapper = sqlSession.getMapper(UserMapper.class); if (userMapper != null) { try { userMapper.approveRequest(uidx); userMapper.updateUpdate(uidx); userMapper.deleteRequest(uidx); return true; } catch (Exception e) { e.toString(); return false; } } else { return false; } }