public ActionResult CreateStage2(long id)
        {
            var loan = _controleHelper.FirstOrDefault<Loan>(l => l.Id == id);
            if (loan.IsObsolete)
                return View("LoanObsolete");

            LoanApplicationViewModel la = new LoanApplicationViewModel();
            la.Loan = new LoanForApplicationViewModel();
            la.Loan.Id = loan.Id;
            la.Loan.Name = loan.Name;
            la.Loan.Guarantee = loan.LoanGuarantee;
            la.Loan.RateOfInterest = loan.RateOfInterest;
            return View(la);
        }
        public ActionResult CreateStage2(LoanApplicationViewModel model)
        {
            try
            {
                if (!ModelState.IsValid)
                {
                    return View(model);
                }

                var result = _controleHelper.CreateEntity<LoanApplication, LoanApplicationViewModel>(model);
                if (result.Error.Any())
                {
                    ModelState.AddModelError(string.Empty, result.Error.First().ErrorMessage);
                    return View(model);
                }
                return RedirectToAction("Details", new { id = result.Entity.Id });
            }
            catch (Exception ex)
            {
                ModelState.AddModelError(string.Empty, ex.Message);
                return View(model);
            }
        }