IS.Model.Service.AuditoryService.Create C# (CSharp) Method

Create() public method

Создает аудиторию.
public Create ( AuditoryItem auditory ) : int
auditory IS.Model.Item.Auditory.AuditoryItem Аудитория.
return int
        public int Create(AuditoryItem auditory)
        {
            if(string.IsNullOrEmpty(auditory.FullName))
            {
                throw new Exception("Поле 'FullName' не должно быть пустым.");
            }
            if (string.IsNullOrEmpty(auditory.Memo))
            {
                throw new Exception("Поле 'Memo' не должно быть пустым.");
            }
            return _auditoryRepository.Create(auditory);
        }