public bool Create(ScheduleItemForCreationDto scheduleItemForCreation) { try { ScheduleItem DataEntity = _mapper.Map <ScheduleItem>(scheduleItemForCreation); _repository.Create(DataEntity); _repository.Save(); return(true); } catch (Exception ex) { _logger.LogError($"Something went wrong inside CreateScheduleItem action: {ex.Message}"); throw new Exception(); } }