Package com.sogou.qadev.service.cynthia.bean

Examples of com.sogou.qadev.service.cynthia.bean.UUID


    try {
      Node templateNode = XMLUtil.getSingleNode(filterDoc, "query/template");
      if(templateNode == null){
        displayNames = FilterQueryManager.getTemplateTypeDisplayFieldsName(filterDoc,das);
      }else{
        UUID templateId = DataAccessFactory.getInstance().createUUID(XMLUtil.getAttribute(templateNode, "id").toString());
        Template template = TemplateCache.getInstance().get(templateId);
        displayNames = FilterQueryManager.getTemplateDisplayFieldsName(filterDoc,das , template);
      }
    } catch (Exception e) {
      e.printStackTrace();
View Full Code Here


   */
  public static UUID getFilterTemplateId(Filter filter){
    if (isSysFilter(filter.getId().getValue())) {
      return null;
    }
    UUID templateId = null;
    Document filterDocument = null;
    try {
      filterDocument = XMLUtil.string2Document(filter.getXml(),"UTF-8");
    } catch (UnsupportedEncodingException e) {
      e.printStackTrace();
View Full Code Here

         
          if(field.getType().equals(Type.t_selection))
          {
            if(field.getDataType().equals(DataType.dt_single))
            {
              UUID optionId = task.getSingleSelection(field.getId());
              if(optionId != null)
              {
                Option option = field.getOption(optionId);
                if(option != null)
                  fieldShowValue =  option.getName();
              }
            }
            else
            {
              UUID[] optionIdArray = task.getMultiSelection(field.getId());
              if(optionIdArray != null && optionIdArray.length > 0)
              {
                StringBuffer valueStrb = new StringBuffer();
                for(UUID optionId : optionIdArray)
                {
                  Option option = field.getOption(optionId);
                  if(option != null)
                  {
                    if(valueStrb.length() > 0)
                      valueStrb.append(",");
                   
                    valueStrb.append("[").append(option.getName()).append("]");
                  }
                }
               
                if(valueStrb.length() > 0)
                  fieldShowValue =  valueStrb.toString();
              }
            }
          }
          else if(field.getType().equals(Type.t_reference))
          {
            if(field.getDataType().equals(DataType.dt_single))
            {
             
              UUID dataId = task.getSingleReference(field.getId());
             
              if(dataId != null)
              {
                String[] titles = new DataAccessSessionMySQL().queryFieldByIds(new UUID[]{dataId} , "title" , null);
                if (titles != null && titles.length > 0) {
View Full Code Here

 
  @ResponseBody
  @RequestMapping("/getTemplateRole.do")
  public String getTemplateRole(@RequestParam("templateId") String templateIdStr) throws Exception {
    UUID templateId = DataAccessFactory.getInstance().createUUID(templateIdStr);
   
    Template template = das.queryTemplate(templateId);
    if (template == null) {
      return "";
    }
View Full Code Here

  @RequestMapping("/getQuitUser.do")
  public String getQuitUser(@RequestParam("templateId") String templateIdStr , @RequestParam("roleId") String roleIdStr) throws Exception {
    if (roleIdStr == null || roleIdStr.length() == 0 || templateIdStr == null || templateIdStr.length() == 0) {
      return "";
    }
    UUID roleId = DataAccessFactory.getInstance().createUUID(roleIdStr);
   
    Template template = das.queryTemplate(DataAccessFactory.getInstance().createUUID(templateIdStr));
   
    Flow flow = das.queryFlow(template.getFlowId());
   
View Full Code Here

  @RequestMapping("/getAllRoleUser.do")
  public String getAllRoleUser(@RequestParam("templateId") String templateIdStr , @RequestParam("roleId") String roleIdStr) throws Exception {
    if (roleIdStr == null || roleIdStr.length() == 0 || templateIdStr == null || templateIdStr.length() == 0) {
      return "";
    }
    UUID roleId = DataAccessFactory.getInstance().createUUID(roleIdStr);
   
    Template template = das.queryTemplate(DataAccessFactory.getInstance().createUUID(templateIdStr));
   
    Flow flow = das.queryFlow(template.getFlowId());
   
View Full Code Here

   * @throws Exception
   */
  @ResponseBody
  @RequestMapping("/getUserNoCloseData.do")
  public String getUserNoCloseData(@RequestParam("templateId") String templateIdStr , @RequestParam("userName") String userName) throws Exception {
    UUID templateId = DataAccessFactory.getInstance().createUUID(templateIdStr);
    Template template = das.queryTemplate(templateId);
    if (template == null || userName == null || userName.equals("") ) {
      return "";
    }
    Flow flow = das.queryFlow(template.getFlowId());
View Full Code Here

  public String getUserNoCloseData(HttpSession httpSession , @RequestParam("templateId") String templateIdStr, @RequestParam("quitUserName") String quitUserName , @RequestParam("newUserName") String newUserName ,@RequestParam("actionComment") String actionComment, @RequestParam("roleId") String roleIdStr) throws Exception {
    Key key   = ((Key)httpSession.getAttribute("key"));
    Long keyId = (Long)httpSession.getAttribute("kid");
    das = DataAccessFactory.getInstance().createDataAccessSession(key.getUsername(), keyId);
   
    UUID roleId = DataAccessFactory.getInstance().createUUID(roleIdStr);
    if (roleId == null) {
      return "请选择角色";
    }
   
    if (templateIdStr == null || templateIdStr.length() == 0 ) {
      return "表单不能为空";
    }
    UUID templateId = DataAccessFactory.getInstance().createUUID(templateIdStr);
   
   
    Template template = das.queryTemplate(templateId);
    if (template == null) {
      return "无法找到该表单";
View Full Code Here

    String templateId = request.getParameter("templateId");
    String roleIdStr = request.getParameter("roleId");
    if (roleIdStr == null || roleIdStr.length() == 0) {
      return "";
    }
    UUID roleId = DataAccessFactory.getInstance().createUUID(roleIdStr);
   
    if (templateId == null || templateId.equals("")) {
      return "";
    }
      Template template = das.queryTemplate(DataAccessFactory.getInstance().createUUID(templateId));
View Full Code Here

  @RequestMapping("/getUserTemplate.do")
  public String getUserTemplate(HttpServletRequest request , HttpSession httpSession) throws Exception {
    Key key   = ((Key)httpSession.getAttribute("key"));
    Long keyId = (Long)httpSession.getAttribute("kid");
    String templateTypeId = request.getParameter("templateTypeId");
    UUID templateTypeUUID = null;
    if (templateTypeId != null && !templateTypeId.equals("")) {
      templateTypeUUID = DataAccessFactory.getInstance().createUUID(templateTypeId);
    }
   
    das = DataAccessFactory.getInstance().createDataAccessSession(key.getUsername(), keyId);
View Full Code Here

TOP

Related Classes of com.sogou.qadev.service.cynthia.bean.UUID

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.