public async Task <ActionResult> Update(int id, CreateOrUpdateTrainerRequest request)
        {
            try {
                await _manager.UpdateTrainer(id, request);

                return(RedirectToAction(nameof(ShowTrainers)));
            }
            catch (ArgumentNullException) {
                return(RedirectToAction("ErrorPage", nameof(Main), new { message = "Error: can not update trainer", call = nameof(Trainer) }));
            }
            catch (DbUpdateException) {
                return(RedirectToAction("ErrorPage", nameof(Main), new { message = "Error: invalid input", call = nameof(Trainer) }));
            }
        }
        public async Task <ActionResult> Create(CreateOrUpdateTrainerRequest request)
        {
            try {
                await _manager.AddTrainer(request);

                return(RedirectToAction(nameof(ShowTrainers)));
            }
            catch (ArgumentNullException) {
                return(RedirectToAction("ErrorPage", nameof(Main), new { message = "Error: can not add new trainer", call = nameof(Trainer) }));
            }
            catch (DbUpdateException) {
                return(RedirectToAction("ErrorPage", nameof(Main), new { message = "Error: this employee alredy exists", call = nameof(Trainer) }));
            }
        }