public IActionResult AddEscort(long RequestID, int page, string returnAction)
        {
            var req    = _repository.GetRequestByID(GetRequestorBadge(), RequestID);
            var escort = tb_request_escort.CreateRequestEscort(req);
            var vm     = SingleRequestEscortViewModel.CreateFromEscort(escort);

            vm.RequestAction = returnAction;
            vm.ReturnAction  = Globals.RouteActions.Escorts;
            return(View(vm));
        }
        public IActionResult EditEscort(long requestid, int escortno, int page, string returnAction)
        {
            var req = _repository.GetRequestByID(GetRequestorBadge(), requestid);
            var vm  = SingleRequestEscortViewModel.CreateFromEscort(req.RequestEscorts.Where(e => e.EscortNo == escortno).First());

            vm.RequestAction = returnAction;    // preserve Request workflow
            vm.ReturnAction  = Globals.RouteActions.Escorts;
            ViewBag.Page     = page;
            if (vm != null)
            {
                return(View(vm));
            }
            else
            {
                Response.StatusCode = (int)HttpStatusCode.BadRequest;
                ModelState.AddModelError("", "Escort not found.");
                return(View(vm));
            }
        }