Exemple #1
0
        public async Task <IActionResult> RegisterMeasurementAsync(int clientId, [FromBody] RegisterMeasurement measurement)
        {
            // TODO: check client exists - if not return NotFound()
            await _weightService.RegisterMeasurementAsync(clientId, measurement);

            return(Ok());
        }
Exemple #2
0
 public async Task RegisterMeasurementAsync(int clientId, RegisterMeasurement measurement)
 {
     var measurementEntity = _mapper.Map <MeasurementEntity>(measurement);
     await _measurementRepository.AddAsync(clientId, measurementEntity);
 }