diff --git a/src/Yavsc.Server/Services/ChatHubConnexionManager.cs b/src/Yavsc.Server/Services/ChatHubConnexionManager.cs index 5e823087..d47c7af8 100644 --- a/src/Yavsc.Server/Services/ChatHubConnexionManager.cs +++ b/src/Yavsc.Server/Services/ChatHubConnexionManager.cs @@ -130,7 +130,6 @@ namespace Yavsc.Services public bool Part(string cxId, string roomName, string reason) { ChatRoomInfo chanInfo; - var userName = ChatUserNames[cxId]; if (Channels.TryGetValue(roomName, out chanInfo)) { if (!chanInfo.Users.Contains(cxId)) diff --git a/src/Yavsc.Server/Settings/SiteSettings.cs b/src/Yavsc.Server/Settings/SiteSettings.cs index 5939c31b..92eea715 100644 --- a/src/Yavsc.Server/Settings/SiteSettings.cs +++ b/src/Yavsc.Server/Settings/SiteSettings.cs @@ -8,6 +8,7 @@ namespace Yavsc public string Title { get; set; } = "Yavsc"; public string Slogan { get; set; } = ""; + public string Banner { get; set; } = ""; public string StyleSheet { get; set; } = "site.css"; public string FavIcon { get; set; } = "favicon.ico"; diff --git a/src/Yavsc.Server/ViewModels/BlogSpot/BlogPostEdit.cs b/src/Yavsc.Server/ViewModels/BlogSpot/BlogPostEdit.cs index f384664c..e6f2af67 100644 --- a/src/Yavsc.Server/ViewModels/BlogSpot/BlogPostEdit.cs +++ b/src/Yavsc.Server/ViewModels/BlogSpot/BlogPostEdit.cs @@ -3,18 +3,23 @@ using Yavsc.Models.Blog; namespace Yavsc.ViewModels.Blog; -public class BlogPostEditViewModel : BlogPostBase + +public class BlogPostCreateViewModel : BlogPostBase +{ + public bool Publish { get; set; } +} + +public class BlogPostEditViewModel : BlogPostCreateViewModel { [Required] - public required long Id { get; set; } + public required long Id { get; set; } - public bool Publish { get; set; } public BlogPostEditViewModel() { - + } diff --git a/src/Yavsc/Controllers/Communicating/BlogspotController.cs b/src/Yavsc/Controllers/Communicating/BlogspotController.cs index 2098db64..0c1de2e3 100644 --- a/src/Yavsc/Controllers/Communicating/BlogspotController.cs +++ b/src/Yavsc/Controllers/Communicating/BlogspotController.cs @@ -95,7 +95,7 @@ namespace Yavsc.Controllers [Authorize()] public IActionResult Create(string title) { - var result = new BlogPostBase + var result = new BlogPostCreateViewModel { Title = title }; diff --git a/src/Yavsc/Views/Home/Index.cshtml b/src/Yavsc/Views/Home/Index.cshtml index f2580e3e..5e9580bb 100755 --- a/src/Yavsc/Views/Home/Index.cshtml +++ b/src/Yavsc/Views/Home/Index.cshtml @@ -51,7 +51,7 @@ @act.Description
@if (act.Children.Count>0) { - + @foreach (Activity c in act.Children) { @Html.DisplayFor(subact=>c) } diff --git a/src/Yavsc/Views/Shared/_Layout.cshtml b/src/Yavsc/Views/Shared/_Layout.cshtml index 84c5f210..a686a35d 100644 --- a/src/Yavsc/Views/Shared/_Layout.cshtml +++ b/src/Yavsc/Views/Shared/_Layout.cshtml @@ -16,7 +16,10 @@ @await RenderSectionAsync("header", false) - +