Esempio n. 1
0
        public string NccRenderGlobalMessages()
        {
            var globalMessageContainer = "";
            var content = ThemeHelper.GetGlobalMessages(GlobalMessage.MessageFor.Site);

            if (string.IsNullOrEmpty(content) == false)
            {
                globalMessageContainer = "<div id=\"globalMessageContainer\" class=\"ncc-global-message\">" + content + "</div>";
            }
            var themeSections = FireEvent(ThemeSection.Sections.GlobalMessageContainer, CurrentLayout, globalMessageContainer, Model);

            globalMessageContainer = themeSections.LastOrDefault()?.Content ?? "";
            ViewContext.Writer.WriteLine(globalMessageContainer);
            return(string.Empty);
        }