public ActionResult ForBlood(BloodRequestViewModel viewModel)
        {
            var memberBloodGroups = SelectListItemExtension.PopulateDropdownList(_db.MemberBloodGroups.ToList<MemberBloodGroup>(), "Id", "BloodGroupName", isEdit: true, selectedValue: viewModel.RequiredBloodGroupId != 0 ? viewModel.RequiredBloodGroupId.ToString() : "0").ToList();

            viewModel.ddlMemberBloodGroups = memberBloodGroups;

            try
            {
                if (ModelState.IsValid)
                {

                    BloodRequest model = new BloodRequest { RequesterName = viewModel.RequesterName, RequesterContactNo = viewModel.RequesterContactNo, RequesterAmount = viewModel.RequesterAmount, PresentLocation = viewModel.PresentLocation, DateOfDonation = Convert.ToDateTime(viewModel.DateOfDonation), AppealMessage = viewModel.AppealMessage, RequiredBloodGroupId = viewModel.RequiredBloodGroupId };

                    _db.BloodRequests.Add(model);
                    _db.SaveChanges();

                    return RedirectToAction("Index", "BloodRequest");
                }

                //return Content(ExceptionHelper.ModelStateErrorFormat(ModelState));
                return View(viewModel);
            }
            catch (Exception ex)
            {
                ExceptionHelper.ExceptionMessageFormat(ex, true);
                return View(viewModel);
            }
        }
        //ForBlood
        public ActionResult ForBlood()
        {
            try
            {

                var memberBloodGroups = SelectListItemExtension.PopulateDropdownList(_db.MemberBloodGroups.ToList<MemberBloodGroup>(), "Id", "BloodGroupName").ToList();

                var bloodRequestViewModel = new BloodRequestViewModel { ddlMemberBloodGroups = memberBloodGroups };

                return View(bloodRequestViewModel);

            }
            catch (Exception ex)
            {
                ExceptionHelper.ExceptionMessageFormat(ex, true);
                return RedirectToAction("Index", "BloodRequest");
            }
        }
        //
        // GET: /BloodRequest/Details/By ID
        public ActionResult Details(int id)
        {
            try
            {
                var bloodRequest = _db.BloodRequests.Find(id);
                if (bloodRequest != null)
                {
                    var bloodRequestViewModel = new BloodRequestViewModel { BloodRequestId = bloodRequest.Id, RequesterName = bloodRequest.RequesterName, RequesterContactNo = bloodRequest.RequesterContactNo, RequesterAmount = bloodRequest.RequesterAmount, PresentLocation = bloodRequest.PresentLocation, DateOfDonation = bloodRequest.DateOfDonation, AppealMessage = bloodRequest.AppealMessage };

                    return PartialView("_Details", bloodRequestViewModel);
                }
                else
                {
                    return RedirectToAction("Index", "BloodRequest");
                }

            }
            catch (Exception ex)
            {
                ExceptionHelper.ExceptionMessageFormat(ex, true);
                return RedirectToAction("Index", "BloodRequest");
            }
        }
        public ActionResult Status(BloodRequestViewModel viewModel)
        {
            try
            {
                if (ModelState.IsValid)
                {
                    var model = _db.BloodRequests.Find(viewModel.BloodRequestId);

                    model.RequesterStatus = viewModel.RequesterStatus;
                    model.RequesterStatusMessage = viewModel.RequesterStatusMessage;

                    _db.Entry(model).State = EntityState.Modified;
                    _db.SaveChanges();

                    return Content(Boolean.TrueString);
                }

                return Content(ExceptionHelper.ModelStateErrorFormat(ModelState));
            }
            catch (Exception ex)
            {
                ExceptionHelper.ExceptionMessageFormat(ex, true);
                return Content("Sorry! Unable to update this member donate type.");
            }
        }