From 420201e3b8a930f009d74676ee7d8ac7b610e48f Mon Sep 17 00:00:00 2001 From: masoodafar-web Date: Sun, 4 Oct 2026 23:34:16 +0330 Subject: [PATCH] feat(landing-settings): add toggle switches for steps and features visibility - Introduced toggle switches to enable or disable the display of the "How It Works" and "Platform Features" sections in the landing settings. - Updated the LandingSettingsModel to include properties for managing the visibility of these sections. --- .../Components/LandingSettingsEditor.razor | 20 +++++++++++++++++++ .../SettingsModels/PageSettingsModels.cs | 2 ++ 2 files changed, 22 insertions(+) diff --git a/src/BackOffice/Pages/Content/Components/LandingSettingsEditor.razor b/src/BackOffice/Pages/Content/Components/LandingSettingsEditor.razor index 12bd702..483944d 100644 --- a/src/BackOffice/Pages/Content/Components/LandingSettingsEditor.razor +++ b/src/BackOffice/Pages/Content/Components/LandingSettingsEditor.razor @@ -56,6 +56,10 @@ @* ── Steps ── *@ + + + نمایش بخش «چگونه کار می‌کند؟» + + + + نمایش بخش «امکانات پلتفرم» + Model.FeaturedBlogEnabled ?? true; set => Model.FeaturedBlogEnabled = value; } + + private bool _stepsEnabled + { + get => Model.StepsEnabled ?? false; + set => Model.StepsEnabled = value; + } + + private bool _featuresEnabled + { + get => Model.FeaturesEnabled ?? false; + set => Model.FeaturesEnabled = value; + } } diff --git a/src/BackOffice/Pages/Content/Components/SettingsModels/PageSettingsModels.cs b/src/BackOffice/Pages/Content/Components/SettingsModels/PageSettingsModels.cs index a5f2ae2..e233cb1 100644 --- a/src/BackOffice/Pages/Content/Components/SettingsModels/PageSettingsModels.cs +++ b/src/BackOffice/Pages/Content/Components/SettingsModels/PageSettingsModels.cs @@ -9,8 +9,10 @@ public class LandingSettingsModel public string? HeroButtonPrimaryText { get; set; } public string? HeroButtonSecondaryText { get; set; } public List TrustBadges { get; set; } = new(); + public bool? StepsEnabled { get; set; } public string? StepsTitle { get; set; } public List Steps { get; set; } = new(); + public bool? FeaturesEnabled { get; set; } public string? FeaturesTitle { get; set; } public List Features { get; set; } = new(); public string? StatsTitle { get; set; }