Exemplo n.º 1
0
 public ActionResult CapitalCallSummary()
 {
     ViewData["MenuName"] = "ReportManagement";
     ViewData["SubmenuName"] = "CapitalCallSummary";
     CapitalCallSummaryModel model = new CapitalCallSummaryModel();
     model.CapitalCalls = SelectListFactory.GetEmptySelectList();
     return View(model);
 }
Exemplo n.º 2
0
 public JsonResult CapitalCallSummaryList(FormCollection collection)
 {
     CapitalCallSummaryModel model = new CapitalCallSummaryModel();
     this.TryUpdateModel(model, collection);
     string error = string.Empty;
     ResultModel resultModel = new ResultModel();
     CapitalCallReportDetail detail = null;
     if (ModelState.IsValid) {
         detail = ReportRepository.FindCapitalCall(model.CapitalCallId);
     }
     else {
         foreach (var values in ModelState.Values.ToList()) {
             foreach (var err in values.Errors.ToList()) {
                 if (string.IsNullOrEmpty(err.ErrorMessage) == false) {
                     error += err.ErrorMessage + "\n";
                 }
             }
         }
     }
     return Json(new { Error = error, Data = detail }, JsonRequestBehavior.AllowGet);
 }