Ejemplo n.º 1
0
        //
        // GET: /Service/Details/5
        public ActionResult Details(int id)
        {
            var r       = _serviceRepository.GetById(id);
            var numBids = _bidRepository.GetBids(id).Count();

            return(View(new ServiceRequestViewModel(r)));
        }
Ejemplo n.º 2
0
        public IActionResult GetBids()
        {
            var BidsFromRepo = _BidRepository.GetBids();

            //return Ok(_mapper.Map<IEnumerable<BidDto>>(BidsFromRepo));
            return(Ok(BidsFromRepo));
        }
        public async Task <IEnumerable <BidResource> > GetBids(int vehicleId)
        {
            var bids = await bidRepository.GetBids(vehicleId);

            return(mapper.Map <IEnumerable <Bids>, IEnumerable <BidResource> >(bids));
        }