示例#1
0
        public async Task <ActionResult> CurrentBookingSearch()
        {
            BookingDTO bookingSearch = new BookingDTO();

            var task1 = new VehicleGroupService(AUTHTOKEN, p_mobileNo).GetDataAsync();
            var task2 = new VehicleTypeService(AUTHTOKEN, p_mobileNo).GetDataAsync();

            var result = await Task.WhenAll(task1, task2);

            bookingSearch.VehicleGroupList = result[0];
            bookingSearch.VehicleTypeList  = result[1];
            return(View(bookingSearch));
        }
示例#2
0
        public async Task <ActionResult> Ratecard()
        {
            var rateCardVm = new RateCardVm();
            var task1      = new VehicleGroupService(AUTHTOKEN, p_mobileNo).GetDataAsync();
            var task2      = new VehicleTypeService(AUTHTOKEN, p_mobileNo).GetDataAsync();

            var result = await Task.WhenAll(task1, task2);

            rateCardVm.VehicleGrouplookUpData = result[0];
            rateCardVm.VehicleTypelookUpData  = result[1];

            return(View(rateCardVm));
        }
示例#3
0
        public async Task <ActionResult> Index()
        {
            var tripEstimateVm = new TripEstimateVm();

            var task1 = new VehicleGroupService(AUTHTOKEN, p_mobileNo).GetDataAsync();
            var task2 = new VehicleTypeService(AUTHTOKEN, p_mobileNo).GetDataAsync();

            var result = await Task.WhenAll(task1, task2);

            tripEstimateVm.VehicleGrouplookUpData = result[0];
            tripEstimateVm.VehicleTypelookUpData  = result[1];
            if (ISLOGGEDIN)
            {
                tripEstimateVm.customer = (Customer)HttpContext.Session["SSN_CUSTOMER"];
            }
            else
            {
                tripEstimateVm.customer = new Customer();
            }

            ViewBag.isUserLoggedIn = ISLOGGEDIN;

            return(View(tripEstimateVm));
        }