Package org.jresearch.gossip.beans.forum

Examples of org.jresearch.gossip.beans.forum.Message


                    (currForum.getLocked() == IConst.Forum.STATUS_COMPLETELY_LOCKED)) &&
                    (!isUserMod)) {
                return (mapping.findForward(IConst.TOKEN.DENIED));
            }

            Message mess = dao.getMessage(messageForm.getMid());
            session.removeAttribute(IConst.REQUEST.CURR_THREAD);

            if (mess == null) {
                return (new ActionForward("/ShowThread.do?fid=" +
                    messageForm.getFid() + "&tid=" + messageForm.getTid() +
                    "&block=" + messageForm.getBlock(), true));
            } else {
                // check user access rights
                if (dao.checkMod(Integer.parseInt(messageForm.getFid()), user) ||
                        (user.getName().equals(mess.getSender()) &&
                        (currThread.getLocked() == IConst.Topic.STATUS_UNLOCKED))) {
                    dao.updateMessage(messageForm);

                    //subscribe user to e-mail from this thread...
                    if (IConst.VALUES.TRUE.equals(messageForm.getSubscribe())) {
View Full Code Here


                user.getStatus() > 7);

            Iterator it = recordsData.getRecords().iterator();

            while (it.hasNext()) {
                Message mess = (Message) it.next();
                mess.setSenderInfo(userdao.getSenderInfo(mess.getSender()));
            }

            request.setAttribute(IConst.REQUEST.RECORDS_DATA, recordsData);
        } catch (SQLException sqle) {
            getServlet().log("Connection.process", sqle);
View Full Code Here

     
      int fid = Integer.parseInt(pmForm.getFid());
      boolean isUserMod = dao.checkMod(fid, user);
      Topic currThread = dao.getThreadInfo(Integer.parseInt(pmForm
          .getTid()));
      Message mess = dao.getMessage(pmForm.getMid());
      if (mess == null) {
        return (new ActionForward("/ShowThread.do?fid="
            + pmForm.getFid() + "&tid=" + pmForm.getTid()
            + "&block=" + pmForm.getBlock(), true));
      } else {
        // check user access rights
        getServlet().log("check user access rights ");
        if (isUserMod
            || (user.getName().equals(mess.getSender()) && (currThread
                .getLocked() == IConst.Topic.STATUS_UNLOCKED))) {
          return super.process(mapping, form, request, response);
        } else {
          return (mapping.findForward(IConst.TOKEN.DENIED));
        }
View Full Code Here

TOP

Related Classes of org.jresearch.gossip.beans.forum.Message

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.