Package kr.or.javacafe.member.domain

Examples of kr.or.javacafe.member.domain.User


    return "manage/managerInfo";
  }

  @RequestMapping(value = "/managerInfo/view/{userId}", method = RequestMethod.GET)
  public String managerInfoEdit(@PathVariable String userId, Model model) {
    User param = new User();
    param.setId(userId);
   
    model.addAttribute("user", memberBO.viewUser(param));
   
    return "manage/managerInfoEdit";
  }
View Full Code Here


    Bbs objBbsInfo = boardBO.getBbsInfo(bbsId);
   
    // 게시판 권한 정보
    String strRoleRead = "";
    String strRoleWrite = "";   
    User objUserInfo = RoleUtil.getUserInfo();
    if (objUserInfo == null) {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", "G0");
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", "G0");
    } else {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", objUserInfo.getRoleGrpId());
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", objUserInfo.getRoleGrpId());
    }     
    // 목록 조회시 [읽기권한]이 없는 경우 로그인 페이지로 이동시킨다.
    if (strRoleRead == "") throw new UsernameNotFoundException("목록 조회시 접근한 게시판에 Read 권한이 존재하지않습니다.");

View Full Code Here

    Bbs objBbsInfo = boardBO.getBbsInfo(bbsId);

    // 게시판 권한 정보
    String strRoleRead = "";
    String strRoleWrite = "";   
    User objUserInfo = RoleUtil.getUserInfo();
    if (objUserInfo == null) {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", "G0");
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", "G0");
    } else {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", objUserInfo.getRoleGrpId());
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", objUserInfo.getRoleGrpId());
    }     
    // 내용 조회시 [읽기권한]이 없는 경우 로그인 페이지로 이동시킨다.
    if (strRoleRead == "") throw new UsernameNotFoundException("내용 조회시 접근한 게시판에 Read 권한이 존재하지않습니다.");


    // 게시판 정보
    Article article = new Article();
    article.setBbsId(bbsId);

    // Page 정보
    if (page == null) page = "1";
    if (page.equals("")) page = "1";
    int totalRows = boardBO.getListArticleCount(article);
    int rowRange = m_intRowRange;
    int pageRange = m_intPageRange;
    int pageNum = Integer.parseInt(page);
    String pageURL = "/board/list/BBS_ID/" + bbsId;

    PagingHelper pHelper = PagingHelper.instance;
    pHelper.init(totalRows, rowRange, pageRange, pageNum);

    String pageHTML = pHelper.getPagingHTML(single, pageURL);
   
    int startNum = pHelper.getStartRownum();
    int endNum = pHelper.getEndRownum();

    Article objViewArticle = null;
    Article objNextArticle = null;
    Article objPrevArticle = null;

    article.setStartBbsThread(startNum);
    article.setEndBbsThread(endNum);
    List<Article> objArticleList = boardBO.listArticle(article);
    for (int i = 0; i < objArticleList.size(); i++) {
      if (objArticleList.get(i).getAtcNo() == new Integer(atcNo)) {
       
        objViewArticle = objArticleList.get(i);
        boardBO.hitArticle(new Integer(atcNo));
       
        if (i > 0)
          objNextArticle = objArticleList.get(i - 1);
       
        if (i < (objArticleList.size() - 1))
          objPrevArticle = objArticleList.get(i + 1);
      }
    }


    // 사용자 정보
    String strId = "";
    if (objUserInfo != null) strId = objUserInfo.getId();
   
    // 권한정보
    String strAuth = "";
    if (objUserInfo != null) {
      strAuth = objUserInfo.getRoleGrpId();
    }
   
    model.addAttribute("userRole", strAuth);
    model.addAttribute("boardRoleRead", strRoleRead);
    model.addAttribute("boardRoleWrite", strRoleWrite);
View Full Code Here

    Bbs objBbsInfo = boardBO.getBbsInfo(bbsId);

    // 게시판 권한 정보
    String strRoleRead = "";
    String strRoleWrite = "";   
    User objUserInfo = RoleUtil.getUserInfo();
    if (objUserInfo == null) {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", "G0");
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", "G0");
    } else {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", objUserInfo.getRoleGrpId());
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", objUserInfo.getRoleGrpId());
    }     
    // 내용 추가시 [쓰기권한]이 없는 경우 로그인 페이지로 이동시킨다.
    if (strRoleWrite == "") throw new UsernameNotFoundException("내용 작성시 접근한 게시판에 Write 권한이 존재하지않습니다.");

    // 사용자 정보
    String strId = "";
    if (objUserInfo != null) strId = objUserInfo.getId();

    Article article = null;
    if (atcNo.equals("")) {
      // 신규 등록
      article = new Article();
      article.setBbsId(bbsId);
      article.setRegrEmpNo(strId);
      article.setRegIp(request.getRemoteAddr());
      article.setModIp(request.getRemoteAddr());
    } else {
      // 답글 등록
      article = boardBO.viewArticle(new Integer(atcNo));
    }

   
    model.addAttribute("userRole", objUserInfo.getRoleGrpId());
    model.addAttribute("boardRoleRead", strRoleRead);
    model.addAttribute("boardRoleWrite", strRoleWrite);
    model.addAttribute("single", single);
   
    model.addAttribute("objBbsInfo", objBbsInfo);
View Full Code Here

    Bbs objBbsInfo = boardBO.getBbsInfo(bbsId);
   
    // 게시판 권한 정보
    String strRoleRead = "";
    String strRoleWrite = "";   
    User objUserInfo = RoleUtil.getUserInfo();
    if (objUserInfo == null) {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", "G0");
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", "G0");
    } else {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", objUserInfo.getRoleGrpId());
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", objUserInfo.getRoleGrpId());
    }     
    // 내용 수정시 [쓰기권한]이 없는 경우 로그인 페이지로 이동시킨다.
    if (strRoleWrite == "") throw new UsernameNotFoundException("내용 수정시 접근한 게시판에 Read 권한이 존재하지않습니다.");

    // 게시판 정보
    Article article = boardBO.viewArticle(new Integer(atcNo));
    article.setModIp(request.getRemoteAddr());

    // 사용자 정보
    String strId = "";
    if (objUserInfo != null) strId = objUserInfo.getId();

    model.addAttribute("userRole", objUserInfo.getRoleGrpId());
    model.addAttribute("boardRoleRead", strRoleRead);
    model.addAttribute("boardRoleWrite", strRoleWrite);
    model.addAttribute("single", single);
   
    model.addAttribute("objBbsInfo", objBbsInfo);
View Full Code Here

    Bbs objBbsInfo = boardBO.getBbsInfo(bbsId);
   
    // 게시판 권한 정보
    String strRoleRead = "";
    String strRoleWrite = "";   
    User objUserInfo = RoleUtil.getUserInfo();
    if (objUserInfo == null) {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", "G0");
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", "G0");
    } else {
      strRoleRead = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "R", objUserInfo.getRoleGrpId());
      strRoleWrite = RoleUtil.getRoleByBoardRead(objBbsInfo.getBbsRole(), "W", objUserInfo.getRoleGrpId());
    }     
    // 내용 삭제시 쓰기권한이 없는 경우 로그인 페이지로 이동시킨다.
    if (strRoleWrite == "") throw new UsernameNotFoundException("내용 삭제시 접근한 게시판에 Read 권한이 존재하지않습니다.");

    // REAL 디렉토리 파일 삭제
View Full Code Here

TOP

Related Classes of kr.or.javacafe.member.domain.User

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.