Exemple #1
0
        public async Task <bool> CreateWishlist(WishlistCreateDTO dto)
        {
            var rao = _mapper.Map <WishlistCreateRAO>(dto);

            if (await _repository.CreateWishlist(rao))
            {
                return(true);
            }

            throw new NotImplementedException();
        }
        public async Task<IActionResult> Post([FromBody] WishlistCreateDTO wishlistDTO)
        {
            var operationResult = await wishlistService.CreateWishlist(wishlistDTO.Title, User.SubjectId());

            return CreatedAtAction(nameof(Get), new { id = operationResult.Data.Id }, operationResult);
        }