public void CreateTag(string tagName) { if (_tagRepository.Get(x => x.TagName == tagName) == null) { _authorizationService.CheckAccess(Permissions.CreateTag, CurrentUser, null); Tag tag = new Tag { TagName = tagName }; _tagRepository.Create(tag); } else { _notifier.Warning(T("Couldn't create tag: " + tagName + "it already exixts")); } }
private static TagEntry CreateTagEntry(Tag tag) { return new TagEntry { Tag = tag, IsChecked = false, }; }