Exemplo n.º 1
0
        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 HouseholdUpdatePage(MainWindow mainWindow)
        {
            if (householdRest == null)
            {
                householdRest = new HouseholdRest();
            }

            InitializeComponent();
            this.mainWindow = mainWindow;

            currentHousehold     = householdRest.Get(mainWindow.currentId);
            nameTextBox.Text     = currentHousehold.Name;
            address1TextBox.Text = currentHousehold.Address.Address1;
            address2TextBox.Text = currentHousehold.Address.Address2;
            cityTextBox.Text     = currentHousehold.Address.City;
            postCodeTextBox.Text = currentHousehold.Address.PostCode;
            countryTextBox.Text  = currentHousehold.Address.Country;
        }