Package com.exedosoft.plat

Examples of com.exedosoft.plat.SessionContext


*/
public class SuiteBottom implements DOIView {

  public String getHtmlCode(DOIModel aModel) {
   
    SessionContext us = DOGlobals.getInstance().getSessoinContext();
    String readonly = null;
    if(us!=null && us.getUser()!=null){
      readonly = us.getUser().getValue("readonly");
    }
   
   
   

View Full Code Here


*/
public class SuiteRight implements DOIView {

  public String getHtmlCode(DOIModel aModel) {
   
    SessionContext us = DOGlobals.getInstance().getSessoinContext();
    String readonly = null;
    if(us!=null && us.getUser()!=null){
      readonly = us.getUser().getValue("readonly");
    }
   
   
   

View Full Code Here

      }

      pi.setWfiName(ptName);
      pi.setStartTime(new java.sql.Timestamp(System.currentTimeMillis()));

      SessionContext us = DOGlobals.getInstance().getSessoinContext();

      if(us.getUser()!=null){
        pi.setStartUser(us.getUser().getUid());
      }

      if (isRun) {
        pi.setExeStatus(Integer.valueOf(ProcessInstance.STATUS_RUN));
      }
View Full Code Here

        && !theForward.getNodeStateShowBack().trim().equals("")) {
      state = theForward.getNodeStateShowBack();
    }

    if (backType != -1) {
      SessionContext us = DOGlobals.getInstance().getSessoinContext();
      BOInstance formI = us.getFormInstance();
      String rTxt = "";
      PTNode node = this.getNode();
      if (formI != null && node != null) {
        if (node.getRejectTxt() != null
            && !"".equals(node.getRejectTxt().trim())) {
View Full Code Here

   */
  void storePropertyValues() throws WFException {

    // WFDAO dao = new WFDAO();
    // dao.setAutoClose(false);
    SessionContext us = DOGlobals.getInstance().getSessoinContext();

    if (us.getUser() != null) {
      setPerformer(us.getUser().getUid());
    }

    setNodeDate(new java.sql.Timestamp(System.currentTimeMillis()));

    BOInstance formI = us.getFormInstance();

    // //////////////从界面获取用户的录入,更新变量对应的值
    try {
      if (formI != null) {
        for (Iterator it = this.getProcessInstance()
View Full Code Here

  }

  // /////////////////////上一个节点决定下一个节点的执行,把决定对象的权限写入权限表
  private void storeNextNodeAuthorization(NodeInstance nextNodeInstance) {

    SessionContext us = DOGlobals.getInstance().getSessoinContext();
    BOInstance formI = us.getFormInstance();
    // if (nextPerformerUid == null || "".equals(nextPerformerUid.trim())) {
    // nextPerformerUid = formI.getValue("doNextPerformerUid2");
    // }
    // if (nextPerformerUid == null || "".equals(nextPerformerUid.trim())) {
    // nextPerformerUid = formI.getValue("doNextPerformerUid3");
View Full Code Here

    // //////////////////PTNode.AUTH_TYPE_SCHEDULE_USER/ROLE的情况
    if (this.getAuthType() != null
        && (this.getAuthType().intValue() == PTNode.AUTH_TYPE_SCHEDULE_USER || this
            .getAuthType().intValue() == PTNode.AUTH_TYPE_SCHEDULE_ROLE)) {
      SessionContext context = DOGlobals.getInstance()
          .getSessoinContext();
      String accessOrg = this.getScheduleOUUid();
      if (accessOrg != null) {

        if (this.getAuthType().intValue() == PTNode.AUTH_TYPE_SCHEDULE_USER) {
          String contextUserUid = context.getUser().getUid();
          if (accessOrg.equals(contextUserUid)) {
            return true;
          } else {
            return false;
          }
        } else {
          List<OrgParterValue> parters = (List<OrgParterValue>) DOGlobals
              .getInstance().getSessoinContext().getUser()
              .getObjectValue(LoginMain.ALLAUTH);
          for (Iterator<OrgParterValue> it = parters.iterator(); it
              .hasNext();) {
            OrgParterValue pv = it.next();
            if (pv.getName().equals(accessOrg)) {
              return true;
            }
          }
          return false;
        }
      }
    }

    // ////////////////PTNode.AUTH_TYPE_AUTHTABLE的情况 和其他SpecName 约定
    if (tNode != null) {

      // ////////通过specName 确定权限,比如表单的拥有者等。可以通过表单字段确定表单的拥有者
      if (this.getAuthType() != null
          && this.getAuthType().intValue() == PTNode.AUTH_TYPE_DATA_OWNER
          && tNode.getSpecName() != null) {

        SessionContext context = DOGlobals.getInstance()
            .getSessoinContext();
        String contextUserUid = null;
        if (context.getUser() != null) {
          contextUserUid = context.getUser().getUid();
        }
        String accessUser = null;

        if (tNode.getSpecName().equals("creator")) {// /流程创建者
          accessUser = this.getProcessInstance().getCreator();
View Full Code Here

      user.putValue("deptcode", biDept.getValue("code"));
    }
   
   

    SessionContext us = (SessionContext) request.getSession().getAttribute(
        "userInfo");
    if(us == null){
      us = new SessionContext();
      request.getSession().setAttribute("userInfo", us);
    }


 
    us.setSysTreeRoot(user.getValue("user_name"));
    us.setUser(user);
    us.setIp(DOGlobals.getInstance().getServletContext().getRequest()
        .getRemoteAddr());
    us.setSessionuid(DOGlobals.getInstance().getServletContext().getRequest().getSession().getId());
   
// 
//    BOInstance aInsertLog = new BOInstance();
//    aInsertLog.putValue("userName", user.getName());
//    aInsertLog.putValue("ip", us.getIp());
View Full Code Here

      user.putValue("deptcode", biDept.getValue("code"));
    }
   
   

    SessionContext us = (SessionContext) request.getSession().getAttribute(
        "userInfo");
    if(us == null){
      us = new SessionContext();
      request.getSession().setAttribute("userInfo", us);
    }


 
    us.setSysTreeRoot(user.getValue("user_name"));
    us.setUser(user);
    us.setIp(DOGlobals.getInstance().getServletContext().getRequest()
        .getRemoteAddr());
    us.setSessionuid(DOGlobals.getInstance().getServletContext().getRequest().getSession().getId());
   
// 
//    BOInstance aInsertLog = new BOInstance();
//    aInsertLog.putValue("userName", user.getName());
//    aInsertLog.putValue("ip", us.getIp());
View Full Code Here

        user.putValue(this.service.getBo().getKeyCol(), userName);
      } catch (Exception e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
      }
      SessionContext sc = LoginMain.makeLogin(user, DOGlobals.getInstance()
          .getServletContext().getRequest());
      String deptuid = "";
     
      DOService findDeptByUserId = DOService.getService("findDeptByUserId");
      deptuid = findDeptByUserId.invokeSelectGetAValue(sc.getUser().getUid());
      sc.getUser().putValue("deptuid", deptuid);
      //保存用户名和密码
      sc.getUser().putValue("username_email", userName);
      sc.getUser().putValue("password_email", pwd);
      return "success";
    } else {
      this.setEchoValue(I18n.instance().get("当前工作流上下文丢失,请重新操作!"));

      this.setEchoValue("用户名或密码错误,请重试!");
View Full Code Here

TOP

Related Classes of com.exedosoft.plat.SessionContext

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.