Ejemplo n.º 1
0
        protected virtual async Task UpdateAuthorAsync()
        {
            await AuthorAppService.UpdateAsync(EditingAuthorId, EditingAuthor);

            await GetAuthorsAsync();

            EditAuthorModal.Hide();
        }
Ejemplo n.º 2
0
        private async Task UpdateAuthorAsync()
        {
            await AuthorAppService.UpdateAsync(EditingAuthorId, EditingAuthor);

            await GetAuthorsAsync();

            EditAuthorModal.Hide();
        }
Ejemplo n.º 3
0
        protected virtual async Task CreateEntityAsync()
        {
            await AuthorAppService.CreateAsync(NewAuthor);

            await GetAuthorsAsync();

            CreateAuthorModal.Hide();
        }
Ejemplo n.º 4
0
        private async Task CreateAuthorAsync()
        {
            await AuthorAppService.CreateAsync(NewAuthor);

            await GetAuthorsAsync();

            CreateAuthorModal.Hide();
        }
Ejemplo n.º 5
0
    private async Task UpdateAuthorAsync()
    {
        if (await EditValidationsRef.ValidateAll())
        {
            await AuthorAppService.UpdateAsync(EditingAuthorId, EditingAuthor);
            await GetAuthorsAsync();

            await EditAuthorModal.Hide();
        }
    }
Ejemplo n.º 6
0
    private async Task CreateAuthorAsync()
    {
        if (await CreateValidationsRef.ValidateAll())
        {
            await AuthorAppService.CreateAsync(NewAuthor);
            await GetAuthorsAsync();

            await CreateAuthorModal.Hide();
        }
    }
Ejemplo n.º 7
0
        private async Task DeleteAuthorAsync(AuthorDto author)
        {
            var confirmMessage = L["AuthorDeletionConfirmationMessage", author.Name];

            if (!await UiMessageService.ConfirmAsync(confirmMessage))
            {
                return;
            }

            await AuthorAppService.DeleteAsync(author.Id);

            await GetAuthorsAsync();
        }
Ejemplo n.º 8
0
        private async Task GetAuthorsAsync()
        {
            var result = await AuthorAppService.GetListAsync(
                new GetAuthorListDto
            {
                MaxResultCount = PageSize,
                SkipCount      = CurrentPage * PageSize,
                Sorting        = CurrentSorting
            }
                );

            AuthorList = result.Items;
            TotalCount = (int)result.TotalCount;
        }
Ejemplo n.º 9
0
 public ProductController(AuthorAppService authorAppService, BookAppService bookAppService)
 {
     _authorAppService = authorAppService;
     _bookAppService   = bookAppService;
 }