diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index bfd27d2..9bb82c6 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -6,7 +6,7 @@ on: - main env: - VERSION: 3.7.0 + VERSION: 3.7.1 jobs: # ЧАСТЬ 1: Собираем образы и кладем в Gitea (чтобы делиться с ребятами) diff --git a/Directory.Build.props b/Directory.Build.props index 47228d8..a473803 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,6 +1,6 @@ - 3.7.0 + 3.7.1 net10.0 preview enable diff --git a/compose.yaml b/compose.yaml index 5a143ec..d5ee5e1 100644 --- a/compose.yaml +++ b/compose.yaml @@ -49,7 +49,7 @@ services: crond -f bot: - image: git.codeanddice.ru/toutsu/gmrelay-bot:3.7.0 + image: git.codeanddice.ru/toutsu/gmrelay-bot:3.7.1 restart: always depends_on: db: @@ -67,7 +67,7 @@ services: retries: 3 discord: - image: git.codeanddice.ru/toutsu/gmrelay-discord-bot:3.7.0 + image: git.codeanddice.ru/toutsu/gmrelay-discord-bot:3.7.1 restart: always depends_on: db: @@ -86,7 +86,7 @@ services: retries: 3 web: - image: git.codeanddice.ru/toutsu/gmrelay-web:3.7.0 + image: git.codeanddice.ru/toutsu/gmrelay-web:3.7.1 restart: always depends_on: db: diff --git a/src/GmRelay.Web/Components/Layout/NavMenu.razor b/src/GmRelay.Web/Components/Layout/NavMenu.razor index 703e651..1e79fc3 100644 --- a/src/GmRelay.Web/Components/Layout/NavMenu.razor +++ b/src/GmRelay.Web/Components/Layout/NavMenu.razor @@ -82,7 +82,7 @@ - + diff --git a/src/GmRelay.Web/Services/SessionService.cs b/src/GmRelay.Web/Services/SessionService.cs index 79e5f29..9cb2a86 100644 --- a/src/GmRelay.Web/Services/SessionService.cs +++ b/src/GmRelay.Web/Services/SessionService.cs @@ -470,7 +470,9 @@ public sealed class SessionService( s.allow_direct_registration AS AllowDirectRegistration, s.description AS Description, mp.public_slug AS MasterProfileSlug, - mp.display_name AS MasterDisplayName + mp.display_name AS MasterDisplayName, + s.publication_mode AS PublicationMode, + (s.publication_mode = 'ClubOnly') AS IsMembersOnly FROM sessions s JOIN game_groups g ON g.id = s.group_id LEFT JOIN LATERAL ( @@ -548,8 +550,8 @@ public sealed class SessionService( r.System, r.IsOneShot, r.Format, r.DurationMinutes, r.CoverImageUrl, r.MaxPlayers, r.ActivePlayerCount, r.WaitlistedPlayerCount, r.AllowDirectRegistration, r.Description, - PublicationMode: "Catalog", - IsMembersOnly: false, + PublicationMode: r.PublicationMode, + IsMembersOnly: r.IsMembersOnly, r.MasterProfileSlug, r.MasterDisplayName)).ToList(); } @@ -576,7 +578,9 @@ public sealed class SessionService( s.allow_direct_registration AS AllowDirectRegistration, s.description AS Description, mp.public_slug AS MasterProfileSlug, - mp.display_name AS MasterDisplayName + mp.display_name AS MasterDisplayName, + s.publication_mode AS PublicationMode, + (s.publication_mode = 'ClubOnly') AS IsMembersOnly FROM sessions s JOIN game_groups g ON g.id = s.group_id LEFT JOIN LATERAL ( @@ -636,8 +640,8 @@ public sealed class SessionService( row.System, row.IsOneShot, row.Format, row.DurationMinutes, row.CoverImageUrl, row.MaxPlayers, row.ActivePlayerCount, row.WaitlistedPlayerCount, row.AllowDirectRegistration, row.Description, - PublicationMode: "Catalog", - IsMembersOnly: false, + PublicationMode: row.PublicationMode, + IsMembersOnly: row.IsMembersOnly, row.MasterProfileSlug, row.MasterDisplayName); } diff --git a/tests/GmRelay.Bot.Tests/Web/CampaignTemplatesNavigationTests.cs b/tests/GmRelay.Bot.Tests/Web/CampaignTemplatesNavigationTests.cs index b3248b7..cb97c5f 100644 --- a/tests/GmRelay.Bot.Tests/Web/CampaignTemplatesNavigationTests.cs +++ b/tests/GmRelay.Bot.Tests/Web/CampaignTemplatesNavigationTests.cs @@ -15,7 +15,7 @@ public sealed class CampaignTemplatesNavigationTests public async Task NavMenu_ShouldExposeCurrentProjectVersion() { var navMenu = await File.ReadAllTextAsync(FindRepositoryFile("src/GmRelay.Web/Components/Layout/NavMenu.razor")); - Assert.Contains("v3.7.0", navMenu, StringComparison.Ordinal); + Assert.Contains("v3.7.1", navMenu, StringComparison.Ordinal); } [Fact]