コード例 #1
0
        // GET: QualityAttributesMetrics/Create
        public ActionResult Create()
        {
            QualityAttributesMetric qualityAttributesMetric = new QualityAttributesMetric();

            ViewBag.SubjectId  = new SelectList(_oSubjectService.GetAll(sort: "Name"), "Id", "Name");
            ViewBag.FactorId   = new SelectList(_oFactorService.GetAll(sort: "Name"), "Id", "Name");
            ViewBag.CriteriaId = new SelectList(_oCriteriaService.GetAll(sort: "Name"), "Id", "Name");
            List <SelectListItem> lstQualityAttributesMetrics = new List <SelectListItem>();

            lstQualityAttributesMetrics.Add(new SelectListItem()
            {
                Text = " ", Value = Guid.Empty.ToString()
            });
            foreach (var attributesMetric in _oQualityAttributesMetricService.GetAll(sort: "Name"))
            {
                lstQualityAttributesMetrics.Add(new SelectListItem()
                {
                    Text = attributesMetric.Name, Value = attributesMetric.Id.ToString()
                });
            }

            ViewBag.AgainstId = lstQualityAttributesMetrics;

            ViewBag.RelatedToId = lstQualityAttributesMetrics;
            return(View(qualityAttributesMetric));
        }
コード例 #2
0
        // GET: Criteria/Create
        public ActionResult Create()
        {
            Criteria criteria = new Criteria();

            ViewBag.SubjectId = new SelectList(_oSubjectService.GetAll(sort: "Name"), "Id", "Name");
            ViewBag.FactorId  = new SelectList(_oFactorService.GetAll(sort: "Name"), "Id", "Name");
            return(View(criteria));
        }
コード例 #3
0
        // GET: ApplicationEvaluations/Create
        public ActionResult Create(Guid applicationId)
        {
            ApplicationEvaluation applicationEvaluation = new ApplicationEvaluation {
                ApplicationId = applicationId
            };

            ViewBag.SubjectId  = new SelectList(_oSubjectService.GetAll(sort: "Name"), "Id", "Name");
            ViewBag.FactorId   = new SelectList(_oFactorService.GetAll(sort: "Name"), "Id", "Name");
            ViewBag.CriteriaId = new SelectList(_oCriteriaService.GetAll(sort: "Name"), "Id", "Name");

            ViewBag.QualityAttributesMetricId = new SelectList(_oQualityAttributesMetricService.GetAll(sort: "Name").ToList(), "Id", "Name");
            return(PartialView(applicationEvaluation));
        }
コード例 #4
0
 // GET: Factors
 public ActionResult Index(int page = 1)
 {
     return(View(_oFactorService.GetAll(sort: "Name").ToPagedList(page, 10)));
 }