Exemplo n.º 1
0
 public ResultsPage()
 {
     InitializeComponent();
     var sign1 = new DIA()
     {
         Value = 80
     };
     var sign2 = new SYS()
     {
         Value = 120
     };
     var sign3 = new HeartRate()
     {
         Value = 120
     };
     var state = new HeartAndPressureHealthState()
     {
         MeasurementTime = DateTime.Now,
         Signs           = new List <Sign <Guid, ushort> >()
         {
             sign1,
             sign2,
             sign3
         }
     };
     //this.BindingContext = new HealthMeasurementsViewModel()
     //{
     //    HM = new ObservableCollection<HeartAndPressureHealthState>()
     //    {
     //        state
     //    }
     //};
 }
Exemplo n.º 2
0
        public async Task <IActionResult> AddMeasurement([FromBody] HealthMeasurementViewModel model)
        {
            var hm = new HeartAndPressureHealthState()
            {
                MeasurementTime = model.DateTime,
                Signs           = model.Signs
            };
            await _service.AddHealthMeasurementAsync(model.PatientId, hm);

            return(Ok());
        }