Examples of AwardType


Examples of org.sete.domain.type.AwardType

        spct.setLongDescription("Physics Long Description");
        types.add(spct);
    }

    private static void createAwardTypes(List<AbstractLookupType> types) {
        AwardType at = new AwardType();
        at.setId(25);
        at.setKey("firstPlace");
        at.setLabel("First Place Label");
        at.setDescription("First Place Description");
        at.setLongDescription("First Place Long Description");
        types.add(at);

        at = new AwardType();
        at.setId(26);
        at.setKey("secondPlace");
        at.setLabel("Second Place Label");
        at.setDescription("Second Place Description");
        at.setLongDescription("Second Place Long Description");
        types.add(at);

        at = new AwardType();
        at.setId(27);
        at.setKey("thirdPlace");
        at.setLabel("Third Place Label");
        at.setDescription("Third Place Description");
        at.setLongDescription("Third Place Long Description");
        types.add(at);
    }
View Full Code Here

Examples of org.sete.domain.type.AwardType

      score.setScore(scoreValue);
      projectDao.saveProjectScore(score);
      sp.setScore(score);
    }
   
    AwardType awtp = TypeUtil.forKey(AwardType.class, spvo.getAwardType());
    Award aw = new Award();
    aw.setAwardType(awtp);
    projectDao.saveAward(aw);
    Set<Award> awards = sp.getAwards();
    TreeSet<Award> noDups = new TreeSet<Award>(new Comparator<Award>() {
View Full Code Here

Examples of org.sete.domain.type.AwardType

                                         PrivilegeActionType.Key.READ_WRITE_KEY.getKey()));
       
        checkAuthorization(userHasPrivilege(request.getSession(), vo));

        //find the object for the key
        final AwardType at = TypeUtil.forKey(AwardType.class, request.getParameter("key"));
       
        //and put it in the form
        ((CreateAwardTypeForm)form).setType( at.getLabel() );
        ((CreateAwardTypeForm)form).setDescription( at.getDescription() );
       
        return mapping.findForward(WebConstants.FORWARD_VIEW);
    }
View Full Code Here

Examples of org.sete.domain.type.AwardType

  }
}

public void submitProjectToAward(ScoreProjectVo spvo) {
      ScienceProject sp = projectDao.findById(spvo.getProjectId());
      AwardType awtp = TypeUtil.forKey(AwardType.class, spvo.getAwardType());
      Award aw = new Award();
      aw.setAwardType(awtp);
      projectDao.saveAward(aw);
      Set<Award> awards = sp.getAwards();
      TreeSet<Award> noDups = new TreeSet<Award>(new Comparator<Award>() {
View Full Code Here

Examples of org.sete.domain.type.AwardType

/**
* Loads all Science Projects affiliated with a give award type and status (Scored, in_progress..)
*/
public List<ScienceProjectVo> loadAllSciencProjectsFor(String awardType, Key scored_key) {
  ScienceProjectStatusType spst = ScienceProjectStatusType.forKey(scored_key);
  AwardType awtp = TypeUtil.forKey(AwardType.class, awardType);
 
  List<ScienceProject> projects = projectDao.findByAwardType(awtp, spst);
    List<ScienceProjectVo> projectVos = new ArrayList<ScienceProjectVo>();
    ScienceProjectVo vo = null;
    List<String> students = null;
View Full Code Here

Examples of org.sete.domain.type.AwardType

{
    private AwardTypeDao awardTypeDao;
   
    public void createNewAwardType(AwardTypeVo vo)
    {
        final AwardType at = new AwardType();
        at.setLabel( vo.getType() ) ;
        at.setDescription( vo.getDescription() ) ;
       
        final String keyEscaped = vo.getType().toLowerCase().replace(' ', '_') ;
        at.setKey( keyEscaped ) ;
       
        awardTypeDao.createAwardType( at );
    }
View Full Code Here

Examples of org.sete.domain.type.AwardType

    public void deleteAwardType(final String key)
    {
        assert null != key;

        final String keyEscaped = key.toLowerCase().replace(' ', '_') ;
        final AwardType at = TypeUtil.forKey(AwardType.class, keyEscaped);
        awardTypeDao.deleteAwardType(at);
    }
View Full Code Here

Examples of org.sete.domain.type.AwardType

    public void modifyAwardType(AwardTypeVo vo)
    {
        assert null != vo;
       
        final String keyEscaped = vo.getType().toLowerCase().replace(' ', '_') ;       
        final AwardType at = TypeUtil.forKey(AwardType.class, keyEscaped);
        at.setDescription( vo.getDescription() );
       
        awardTypeDao.saveAwardType(at);
    }
View Full Code Here

Examples of org.sete.domain.type.AwardType

                                         PrivilegeActionType.Key.READ_WRITE_KEY.getKey()));
       
        checkAuthorization(userHasPrivilege(request.getSession(), vo));

        //find the object for the key
        final AwardType at = TypeUtil.forKey(AwardType.class, request.getParameter("key"));
       
        //and put it in the form
        ((CreateAwardTypeForm)form).setType( at.getLabel() );
        ((CreateAwardTypeForm)form).setDescription( at.getDescription() );
       
        return mapping.findForward("view");
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.