示例#1
0
        public async Task <ObjectResult> UpdateDepozitAsync([FromBody] GeneralDepozitRequest request, [FromRoute] int id)
        {
            Depozit result = _depozitServices.DepozitRepository.Update(request.ToDTO(id));
            await _depozitServices.CommitChanges();

            return(Ok(result));
        }
示例#2
0
        public async Task <ObjectResult> CreateDepozitAsync([FromBody] GeneralDepozitRequest request)
        {
            Depozit result = await _depozitServices.DepozitRepository.CreateAsync(request.ToDTO());

            await _depozitServices.CommitChanges();

            return(Ok(result));
        }