예제 #1
0
        private async Task SaveChanges()
        {
            var command = new UpdateUsersCommandVm {
                Users = UsersList
            };

            await HttpClient.PutJsonAsync <UpdateUsersCommandVm>("api/users", command);

            ToastedService.ShowSuccess("Настройки пользователей сохранены", "Готово");
        }
예제 #2
0
        protected async Task Submit()
        {
            var command = new UpsertCheckResultCommandVm {
                CheckResult = CheckList
            };

            var result = await HttpClient.PostAsJsonAsync($"api/check", command, JsonOptions);

            if (result.IsSuccessStatusCode)
            {
                Navigation.NavigateTo($"/contract/{Id}/detail");
                ToastedService.ShowSuccess("Заводские испытания проведены", "Готово");
            }
        }