Exemple #1
0
        public IActionResult Index(string searchCode, string searchDescription)
        {
            var coupons = _repos.GetAllCoupons(searchCode, searchDescription);
            var model   = CouponModelFactory.CreateCouponIndex(coupons);

            return(Ok(model));
        }
 public void GetAllCoupons()
 {
     _couponRepository.GetAllCoupons();
 }
Exemple #3
0
        public IEnumerable <CouponDto> GetAllCoupons()
        {
            var couponEntities = _couponRepository.GetAllCoupons();

            return(_dtoMapper.Map(couponEntities));
        }