コード例 #1
0
        public string CreateTemplateWithSliders(PerformanceEvaluationTemplate _template)
        {
            var template = new PerformanceEvaluationTemplate();

            template.Title        = _template.Title;
            template.Description  = _template.Description;
            template.Instructions = _template.Instructions;
            template.AccountID    = SecurityContextManager.Current.CurrentAccount.ID;
            template.ChangedBy    = ((Person)SecurityContextManager.Current.CurrentUser).ID;
            template.DateCreated  = DateTime.Now;
            template.EnteredBy    = ((Person)SecurityContextManager.Current.CurrentUser).ID;
            template.LastUpdated  = DateTime.Now;
            _service.SaveTemplate(template);
            return("1:Template Successfully Created!:/Evaluations/Template/" + template.ID.ToString());
        }
コード例 #2
0
        public string CreateTemplate(PerformanceEvaluationTemplate _template)
        {
            var template = new PerformanceEvaluationTemplate();

            template.Title        = _template.Title;
            template.Description  = _template.Description;
            template.Instructions = _template.Instructions;
            template.AccountID    = SecurityContextManager.Current.CurrentAccount.ID;
            template.ChangedBy    = ((Person)SecurityContextManager.Current.CurrentUser).ID;
            template.DateCreated  = DateTime.Now;
            template.EnteredBy    = ((Person)SecurityContextManager.Current.CurrentUser).ID;
            template.LastUpdated  = DateTime.Now;
            _service.SaveTemplate(template);
            ICacheStorage _cache = new MemcacheCacheAdapter();

            _cache.Remove(SecurityContextManager
                          .Current
                          .CurrentUser.AccountID.ToString() + "_EvaluationTemplateList");

            return("1:Template Successfully Created!:/Evaluations/Templates/" + template.ID.ToString());
        }
コード例 #3
0
 public void DeleteTemplate(PerformanceEvaluationTemplate item)
 {
     new PerformanceEvaluationTemplateRepository().Delete(item);
 }
コード例 #4
0
 public PerformanceEvaluationTemplate SaveTemplate(PerformanceEvaluationTemplate item)
 {
     return(new PerformanceEvaluationTemplateRepository().SaveOrUpdate(item));
 }