示例#1
0
        public async Task <IActionResult> DeleteAsync(int id)
        {
            var result = await _promoService.DeleteAsync(id);

            if (!result.Success)
            {
                return(BadRequest(result.Message));
            }
            var promoResource = _mapper.Map <Promo, PromoResource>(result.Resource);

            return(Ok(promoResource));
        }