//on load public Task ActivateAsync(string token, Patient patient, string username) { this.token = token; this.test = new EHR.Data.Models.Test(); this.patient = patient; this.PatientName.Content = patient.Name; getTestTypes(); //get test types from server this.TestTypeId.ItemsSource = testTypes; //set dropdown return(Task.CompletedTask); }
//load page public Test(string token, Patient patient, EHR.Data.Models.Test test) { InitializeComponent(); this.token = token; this.patient = patient; this.test = test; this.PatientName.Content = patient.Name; this.TestType.Content = test.TestType.Name; this.Results.Content = test.Results; this.Performed.Content = test.Performed; this.OrderedBy.Content = test.UserOrdered?.UserName; }