Package org.osforce.connect.entity.commons

Examples of org.osforce.connect.entity.commons.Template


      @PrefParam String categoryCode, @PrefParam String templateCode,
      @ModelAttribute @Valid RegisterBean registerBean, BindingResult result,
      @RequestAttr Site site, Model model, WebRequest request) {
    ProjectCategory category = categoryService.getProjectCategory(site, categoryCode);
    //
    Template template = templateService.getTemplate(category.getId(), templateCode);
    List<ProjectFeature> modules = ModuleUtil.parseToModules(template.getContent());
    Project project = new Project();
    // set project category
    project.setCategory(category);
    // set features
    project.setFeatures(modules);
View Full Code Here


      ProjectCategory category = categoryService.getProjectCategory(site, categoryCode);
      project.setCategory(category);
      project.setEnteredBy(user);
      project.setModifiedBy(user);
      //
      Template template = templateService.getTemplate(category.getId(), templateCode);
      List<ProjectFeature> modules = ModuleUtil.parseToModules(template.getContent());
      request.setAttribute(AttributeKeys.PROJECT_FEATURE_LIST_KEY_READABLE, modules, WebRequest.SCOPE_SESSION);
      model.addAttribute(AttributeKeys.PROJECT_KEY_READABLE, project);
    }
    return "system/project-form";
  }
View Full Code Here

  }
 
  @RequestMapping("/features/form-view")
  public String doFeaturesForm(@PrefParam String templateCode,
      @RequestAttr Project project, Model model) {
    Template template = templateService.getTemplate(project.getCategoryId(), templateCode);
    List<ProjectFeature> features = ModuleUtil.parseToModules(template.getContent());
    for(ProjectFeature feature : features) {
      ProjectFeature tmp = featureService.getProjectFeature(feature.getCode(), project.getId());
      if(tmp!=null) {
        feature.setId(tmp.getId());
        feature.setLabel(tmp.getLabel());
View Full Code Here

TOP

Related Classes of org.osforce.connect.entity.commons.Template

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.