public async Task <ActionResult <ShipperModel> > GetShipper(int shipperId)
        {
            var shipper = await _shipperService.GetById(shipperId);

            if (shipper == null)
            {
                return(NotFound());
            }

            return(_mapper.Map <ShipperModel>(shipper));
        }
        public IActionResult ShipmentSelect(Guid id)
        {
            var  shipment = shipperService.GetById(id);
            Cart cart     = SessionHelper.GetProductFromJson <Cart>(HttpContext.Session, "cart");

            cart.ShipperId = shipment.ID;
            SessionHelper.SetProductJson(HttpContext.Session, "cart", cart);
            return(Json(new { success = true }));
        }
Exemple #3
0
 public ActionResult <ShipperQueryDto> Get(int id)
 {
     return(Ok(ShipperService.GetById(id)));
 }
Exemple #4
0
        public IActionResult GetById(int id)
        {
            var model = _shipperService.GetById(id);

            return(new OkObjectResult(model));
        }
Exemple #5
0
        public async Task <Shipper> GetById(int id)
        {
            var shipper = await _shipperService.GetById(id);

            return(shipper);
        }