diff --git a/src/Business/Grand.Business.System/Services/Installation/InstallDataPages.cs b/src/Business/Grand.Business.System/Services/Installation/InstallDataPages.cs index 7b246262e..42b0dd01e 100644 --- a/src/Business/Grand.Business.System/Services/Installation/InstallDataPages.cs +++ b/src/Business/Grand.Business.System/Services/Installation/InstallDataPages.cs @@ -160,7 +160,18 @@ protected virtual async Task InstallPages() Body = "

Knowledgebase homepage. You can edit this in the admin site.

", PageLayoutId = defaultPageLayout.Id, Published = true - } + }, + new Page + { + SystemName = "VendorPortalInfo", + IncludeInSitemap = false, + IsPasswordProtected = false, + DisplayOrder = 1, + Title = "Welcome to our Vendor Management Hub!", + Body = "

Manage your product catalog, oversee customer orders, and streamline your shipping processes. Your vendor dashboard is the command center for your success. Stay organized, serve your customers efficiently, and watch your business thrive.

", + PageLayoutId = defaultPageLayout.Id, + Published = true + } }; await _pageRepository.InsertAsync(pages); diff --git a/src/Business/Grand.Business.System/Services/Migrations/2.2/MigrationAddLandingPage.cs b/src/Business/Grand.Business.System/Services/Migrations/2.2/MigrationAddLandingPage.cs new file mode 100644 index 000000000..6afd59d90 --- /dev/null +++ b/src/Business/Grand.Business.System/Services/Migrations/2.2/MigrationAddLandingPage.cs @@ -0,0 +1,35 @@ +using Grand.Domain.Data; +using Grand.Domain.Pages; +using Grand.Infrastructure.Migrations; +using Microsoft.Extensions.DependencyInjection; + +namespace Grand.Business.System.Services.Migrations._2._2; + +public class MigrationAddLandingPage: IMigration +{ + public int Priority => 0; + public DbVersion Version => new(2, 2); + public Guid Identity => new("0833f104-54d5-41d0-83da-375d2520f709"); + public string Name => "Add new landing page - VendorPortalInfo"; + public bool UpgradeProcess(IDatabaseContext database, IServiceProvider serviceProvider) + { + var pageLayoutRepository = serviceProvider.GetRequiredService>(); + var defaultPageLayout = + pageLayoutRepository.Table.FirstOrDefault(tt => tt.Name == "Default layout"); + + var repository = serviceProvider.GetRequiredService>(); + var page = new Page { + SystemName = "VendorPortalInfo", + IncludeInSitemap = false, + IsPasswordProtected = false, + DisplayOrder = 1, + Title = "Welcome to our Vendor Management Hub!", + Body = + "

Manage your product catalog, oversee customer orders, and streamline your shipping processes. Your vendor dashboard is the command center for your success. Stay organized, serve your customers efficiently, and watch your business thrive.

", + PageLayoutId = defaultPageLayout?.Id, + Published = true + }; + repository.Insert(page); + return true; + } +} \ No newline at end of file diff --git a/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Home/Index.cshtml b/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Home/Index.cshtml index cb60f3840..a3794c564 100644 --- a/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Home/Index.cshtml +++ b/src/Web/Grand.Web.Vendor/Areas/Vendor/Views/Home/Index.cshtml @@ -5,41 +5,41 @@ } -
-
-
-
-

@Loc["Vendor.Dashboard.Summary"] - @WorkContext.CurrentVendor.Name

-
-
-
-
-   -   - -
+
+
+
+
+

@Loc["Vendor.Dashboard.Summary"] - @WorkContext.CurrentVendor.Name

+
+
+
+
+   +   +
-
+
- -
-
-
-
-

@Loc["Vendor.Dashboard.ReportLatestOrder"]

-
-
-
- @await Component.InvokeAsync("LatestVendorOrder") -
+
+ +
+
+
+
+

@Loc["Vendor.Dashboard.ReportLatestOrder"]

+
+
+
+ @await Component.InvokeAsync("LatestVendorOrder")
+