public DetailViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Tag tag) : base(currentFirmaSession) { Tag = tag; PageTitle = tag.TagName; EntityName = "Tag"; EditTagUrl = SitkaRoute <TagController> .BuildUrlFromExpression(c => c.Edit(tag)); ManageTagsUrl = SitkaRoute <TagController> .BuildUrlFromExpression(c => c.Index()); UserHasTagManagePermissions = new FirmaAdminFeature().HasPermissionByFirmaSession(currentFirmaSession); BasicProjectInfoGridName = "tagProjectListGrid"; BasicProjectInfoGridSpec = new BasicProjectInfoGridSpec(currentFirmaSession, true) { ObjectNameSingular = $"{FieldDefinitionEnum.Project.ToType().GetFieldDefinitionLabel()} with this Tag", ObjectNamePlural = $"{FieldDefinitionEnum.Project.ToType().GetFieldDefinitionLabelPluralized()} with this Tag", SaveFiltersInCookie = true }; BasicProjectInfoGridDataUrl = SitkaRoute <TagController> .BuildUrlFromExpression(tc => tc.ProjectsGridJsonData(tag)); }
public void UpdateModel(ProjectFirmaModels.Models.Tag tag, FirmaSession currentFirmaSession) { tag.TagName = TagName; tag.TagDescription = TagDescription; }
public EditViewModel(ProjectFirmaModels.Models.Tag tag) { TagID = tag.TagID; TagName = tag.TagName; TagDescription = tag.TagDescription; }