public static async Task <string[]> MainAsync() { RestClient.SetDomain("https://*****:*****@gmail.com", FName = $"Name{random}", LName = $"LName{random}", Password = $"Password{random}", ConfirmPassword = $"Password{random}" }); ThingDto dto = things.Get(1); dto.Household = households.Get(dto.HouseholdId); Console.WriteLine(JsonConvert.SerializeObject(dto)); // dto = complete thing, ready for use return("Oi"); }
public ThingUpdatePage(MainWindow mainWindow) { if (thingRest == null) { thingRest = new ThingRest(); } InitializeComponent(); this.mainWindow = mainWindow; currentThing = thingRest.Get(mainWindow.currentId); nameTextBox.Text = currentThing.Name; defaultPriceTextBox.Text = currentThing.DefaultPrice.ToString(); neededCheckBox.IsChecked = currentThing.Needed; householdIdTextBlock.Text = currentThing.HouseholdId.ToString(); }