Skip to content

Commit eb7ed25

Browse files
Refactor namespaces and add Grand.Web.Models project
1 parent 3b67dec commit eb7ed25

File tree

166 files changed

+50
-43
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

166 files changed

+50
-43
lines changed

GrandNode.sln

+7
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Grand.Module.Api", "src\Mod
139139
EndProject
140140
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Grand.Module.ScheduledTasks", "src\Modules\Grand.Module.ScheduledTasks\Grand.Module.ScheduledTasks.csproj", "{136F1E35-8B20-465C-8D42-30A5A0D0DA1F}"
141141
EndProject
142+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Grand.Web.Models", "src\Web\Grand.Web.Models\Grand.Web.Models.csproj", "{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0}"
143+
EndProject
142144
Global
143145
GlobalSection(SolutionConfigurationPlatforms) = preSolution
144146
Debug|Any CPU = Debug|Any CPU
@@ -368,6 +370,10 @@ Global
368370
{136F1E35-8B20-465C-8D42-30A5A0D0DA1F}.Debug|Any CPU.Build.0 = Debug|Any CPU
369371
{136F1E35-8B20-465C-8D42-30A5A0D0DA1F}.Release|Any CPU.ActiveCfg = Release|Any CPU
370372
{136F1E35-8B20-465C-8D42-30A5A0D0DA1F}.Release|Any CPU.Build.0 = Release|Any CPU
373+
{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
374+
{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0}.Debug|Any CPU.Build.0 = Debug|Any CPU
375+
{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0}.Release|Any CPU.ActiveCfg = Release|Any CPU
376+
{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0}.Release|Any CPU.Build.0 = Release|Any CPU
371377
EndGlobalSection
372378
GlobalSection(SolutionProperties) = preSolution
373379
HideSolutionNode = FALSE
@@ -429,6 +435,7 @@ Global
429435
{75F9D855-026B-4BCB-90CE-3800F02FA0A7} = {583FFBBD-421C-4FB7-BBDA-F9CAF35A354A}
430436
{E0B26803-010B-4198-8016-002242076B61} = {583FFBBD-421C-4FB7-BBDA-F9CAF35A354A}
431437
{136F1E35-8B20-465C-8D42-30A5A0D0DA1F} = {583FFBBD-421C-4FB7-BBDA-F9CAF35A354A}
438+
{7A07FB5A-4F1E-4D32-BAF6-D4E87BE35EF0} = {BF4543A8-0731-4FDD-BB6B-0ADB9561F981}
432439
EndGlobalSection
433440
GlobalSection(ExtensibilityGlobals) = postSolution
434441
SolutionGuid = {88B478F4-FD3B-4C24-9E84-4FAAF0254397}

src/Web/Grand.Web.Common/Binders/CustomAttributesBinder.cs src/Core/Grand.Infrastructure/ModelBinding/CustomAttributesBinder.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.Models;
22
using Microsoft.AspNetCore.Mvc.ModelBinding;
33
using System.Text.RegularExpressions;
44

5-
namespace Grand.Web.Common.Binders;
5+
namespace Grand.Infrastructure.ModelBinding;
66

77
public class CustomAttributesBinder : IModelBinder
88
{

src/Web/Grand.Web.Common/Page/Paging/BasePageableModel.cs src/Core/Grand.Infrastructure/Models/BasePageableModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
using Grand.Domain;
44
using Grand.SharedKernel.Attributes;
55

6-
namespace Grand.Web.Common.Page.Paging;
6+
namespace Grand.Infrastructure.Models;
77

88
public abstract class BasePageableModel : IPageableModel
99
{

src/Web/Grand.Web.Common/Models/CustomAttributeModel.cs src/Core/Grand.Infrastructure/Models/CustomAttributeModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace Grand.Web.Common.Models;
1+
namespace Grand.Infrastructure.Models;
22

33
public class CustomAttributeModel
44
{

src/Web/Grand.Web.Common/Page/Paging/IPageableModel.cs src/Core/Grand.Infrastructure/Models/IPageableModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
using Grand.SharedKernel.Attributes;
44

5-
namespace Grand.Web.Common.Page.Paging;
5+
namespace Grand.Infrastructure.Models;
66

77
/// <summary>
88
/// A collection of objects that has been split into pages.

src/Plugins/Theme.Modern/Theme.Modern.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<Private>false</Private>
3535
<ExcludeAssets>all</ExcludeAssets>
3636
</ProjectReference>
37-
<ProjectReference Include="..\..\Web\Grand.Web\Grand.Web.csproj">
37+
<ProjectReference Include="..\..\Web\Grand.Web.Models\Grand.Web.Models.csproj">
3838
<Private>false</Private>
3939
<ExcludeAssets>all</ExcludeAssets>
4040
</ProjectReference>

src/Plugins/Theme.Modern/Views/Modern/_ViewImports.cshtml

-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
@using Grand.Web.Common.Extensions
1515
@using Grand.Web.Common.Security.Captcha
1616
@using Grand.Web.Common.Themes
17-
@using Grand.Web.Extensions
1817
@using Grand.Web.Models.Blogs
1918
@using Grand.Web.Models.Catalog
2019
@using Grand.Web.Models.Checkout

src/Web/Grand.Web.Admin/Controllers/CustomerController.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
using Grand.Web.Admin.Models.Orders;
2424
using Grand.Web.Common.DataSource;
2525
using Grand.Web.Common.Filters;
26-
using Grand.Web.Common.Models;
2726
using Grand.Web.Common.Security.Authorization;
2827
using Microsoft.AspNetCore.Mvc;
28+
using Grand.Infrastructure.Models;
2929

3030
namespace Grand.Web.Admin.Controllers;
3131

src/Web/Grand.Web.Admin/Models/Orders/AddProductToOrderModel.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
using Grand.Web.Common.Binders;
2-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.ModelBinding;
2+
using Grand.Infrastructure.Models;
33
using Microsoft.AspNetCore.Mvc;
44

55
namespace Grand.Web.Admin.Models.Orders;

src/Web/Grand.Web.Common/Binders/CustomAttributesBinderProvider.cs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.ModelBinding;
2+
using Grand.Infrastructure.Models;
23
using Microsoft.AspNetCore.Mvc.ModelBinding;
34
using Microsoft.AspNetCore.Mvc.ModelBinding.Binders;
45

src/Web/Grand.Web.Common/TagHelpers/PageNavigationTagHelper.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using Grand.Business.Core.Interfaces.Common.Localization;
2+
using Grand.Infrastructure.Models;
23
using Grand.Web.Common.Extensions;
3-
using Grand.Web.Common.Page.Paging;
44
using Microsoft.AspNetCore.Mvc.Rendering;
55
using Microsoft.AspNetCore.Mvc.ViewFeatures;
66
using Microsoft.AspNetCore.Razor.TagHelpers;

src/Web/Grand.Web/Models/Blogs/BlogPagingFilteringModel.cs src/Web/Grand.Web.Models/Blogs/BlogPagingFilteringModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Blogs;
44

src/Web/Grand.Web/Models/Catalog/BrandPagingModel.cs src/Web/Grand.Web.Models/Catalog/BrandPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Catalog;
44

src/Web/Grand.Web/Models/Catalog/CatalogPagingFilteringModel.cs src/Web/Grand.Web.Models/Catalog/CatalogPagingFilteringModel.cs

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
using Grand.Domain.Catalog;
44
using Grand.Infrastructure.Extensions;
55
using Grand.Infrastructure.Models;
6-
using Grand.Web.Common.Page.Paging;
76
using Microsoft.AspNetCore.Http;
87
using Microsoft.AspNetCore.Mvc.Rendering;
98

src/Web/Grand.Web/Models/Catalog/CategoryPagingModel.cs src/Web/Grand.Web.Models/Catalog/CategoryPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Catalog;
44

src/Web/Grand.Web/Models/Catalog/CollectionPagingModel.cs src/Web/Grand.Web.Models/Catalog/CollectionPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Catalog;
44

src/Web/Grand.Web/Models/Catalog/ProductModel.cs src/Web/Grand.Web.Models/Catalog/ProductModel.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
using Grand.Web.Common.Binders;
2-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.ModelBinding;
2+
using Grand.Infrastructure.Models;
33
using Microsoft.AspNetCore.Mvc;
44

55
namespace Grand.Web.Models.Catalog;

src/Web/Grand.Web/Models/Catalog/VendorPagingModel.cs src/Web/Grand.Web.Models/Catalog/VendorPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Catalog;
44

src/Web/Grand.Web/Models/Common/AddressModel.cs src/Web/Grand.Web.Models/Common/AddressModel.cs

-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
using Grand.Infrastructure.ModelBinding;
22
using Grand.Infrastructure.Models;
3-
using Grand.Web.Common.Binders;
4-
using Grand.Web.Common.Models;
53
using Microsoft.AspNetCore.Mvc;
64
using Microsoft.AspNetCore.Mvc.Rendering;
75
using System.ComponentModel.DataAnnotations;

src/Web/Grand.Web/Models/Common/PagerModel.cs src/Web/Grand.Web.Models/Common/PagerModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Common;
44

src/Web/Grand.Web/Models/Contact/ContactAttributeChangeModel.cs src/Web/Grand.Web.Models/Contact/ContactAttributeChangeModel.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
using Grand.Web.Common.Binders;
2-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.ModelBinding;
2+
using Grand.Infrastructure.Models;
33
using Microsoft.AspNetCore.Mvc;
44

55
namespace Grand.Web.Models.Contact;

src/Web/Grand.Web/Models/Contact/ContactUsModel.cs src/Web/Grand.Web.Models/Contact/ContactUsModel.cs

-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
using Grand.Domain.Common;
33
using Grand.Infrastructure.ModelBinding;
44
using Grand.Infrastructure.Models;
5-
using Grand.Web.Common.Binders;
6-
using Grand.Web.Common.Models;
75
using Microsoft.AspNetCore.Mvc;
86

97
namespace Grand.Web.Models.Contact;

src/Web/Grand.Web/Models/Customer/CustomerInfoModel.cs src/Web/Grand.Web.Models/Customer/CustomerInfoModel.cs

-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
using Grand.Infrastructure.ModelBinding;
33
using Grand.Infrastructure.Models;
44
using Grand.SharedKernel;
5-
using Grand.Web.Common.Binders;
6-
using Grand.Web.Common.Models;
75
using Grand.Web.Models.Newsletter;
86
using Microsoft.AspNetCore.Mvc;
97
using Microsoft.AspNetCore.Mvc.Rendering;

src/Web/Grand.Web/Models/Customer/DocumentPagingModel.cs src/Web/Grand.Web.Models/Customer/DocumentPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Customer;
44

src/Web/Grand.Web/Models/Customer/RegisterModel.cs src/Web/Grand.Web.Models/Customer/RegisterModel.cs

-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
using Grand.Infrastructure.ModelBinding;
22
using Grand.Infrastructure.Models;
33
using Grand.SharedKernel;
4-
using Grand.Web.Common.Binders;
5-
using Grand.Web.Common.Models;
64
using Grand.Web.Models.Newsletter;
75
using Microsoft.AspNetCore.Mvc;
86
using Microsoft.AspNetCore.Mvc.Rendering;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
<Import Project="..\..\Build\Grand.Common.props" />
3+
<ItemGroup>
4+
<ProjectReference Include="..\..\Business\Grand.Business.Core\Grand.Business.Core.csproj" />
5+
<ProjectReference Include="..\..\Core\Grand.Infrastructure\Grand.Infrastructure.csproj" />
6+
<ProjectReference Include="..\..\Core\Grand.SharedKernel\Grand.SharedKernel.csproj" />
7+
</ItemGroup>
8+
</Project>

src/Web/Grand.Web/Models/News/NewsPagingFilteringModel.cs src/Web/Grand.Web.Models/News/NewsPagingFilteringModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.News;
44

src/Web/Grand.Web/Models/Orders/OrderPagingModel.cs src/Web/Grand.Web.Models/Orders/OrderPagingModel.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Grand.Web.Common.Page.Paging;
1+
using Grand.Infrastructure.Models;
22

33
namespace Grand.Web.Models.Orders;
44

src/Web/Grand.Web/Models/ShoppingCart/CheckoutAttributeSelectedModel.cs src/Web/Grand.Web.Models/ShoppingCart/CheckoutAttributeSelectedModel.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
using Grand.Web.Common.Binders;
2-
using Grand.Web.Common.Models;
1+
using Grand.Infrastructure.ModelBinding;
2+
using Grand.Infrastructure.Models;
33
using Microsoft.AspNetCore.Mvc;
44

55
namespace Grand.Web.Models.ShoppingCart;

src/Web/Grand.Web/Models/ShoppingCart/ProductDetailsCart.cs src/Web/Grand.Web.Models/ShoppingCart/ProductDetailsCart.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using Grand.Domain.Orders;
2-
using Grand.Web.Common.Binders;
3-
using Grand.Web.Common.Models;
2+
using Grand.Infrastructure.ModelBinding;
3+
using Grand.Infrastructure.Models;
44
using Microsoft.AspNetCore.Mvc;
55

66
namespace Grand.Web.Models.ShoppingCart;

src/Web/Grand.Web/Commands/Models/Contact/ContactAttributeChangeCommand.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using Grand.Domain.Customers;
22
using Grand.Domain.Stores;
3-
using Grand.Web.Common.Models;
3+
using Grand.Infrastructure.Models;
44
using MediatR;
55

66
namespace Grand.Web.Commands.Models.Contact;

src/Web/Grand.Web/Commands/Models/ShoppingCart/SaveCheckoutAttributesCommand.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
using Grand.Domain.Customers;
33
using Grand.Domain.Orders;
44
using Grand.Domain.Stores;
5-
using Grand.Web.Common.Models;
5+
using Grand.Infrastructure.Models;
66
using MediatR;
77

88
namespace Grand.Web.Commands.Models.ShoppingCart;

src/Web/Grand.Web/Features/Models/Common/GetParseCustomAddressAttributes.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using Grand.Domain.Common;
2-
using Grand.Web.Common.Models;
2+
using Grand.Infrastructure.Models;
33
using MediatR;
44

55
namespace Grand.Web.Features.Models.Common;

src/Web/Grand.Web/Features/Models/Customers/GetParseCustomAttributes.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using Grand.Domain.Common;
2-
using Grand.Web.Common.Models;
2+
using Grand.Infrastructure.Models;
33
using MediatR;
44

55
namespace Grand.Web.Features.Models.Customers;

src/Web/Grand.Web/Features/Models/ShoppingCart/GetParseProductAttributes.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using Grand.Domain.Catalog;
22
using Grand.Domain.Common;
3-
using Grand.Web.Common.Models;
3+
using Grand.Infrastructure.Models;
44
using MediatR;
55

66
namespace Grand.Web.Features.Models.ShoppingCart;

src/Web/Grand.Web/Grand.Web.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
<ProjectReference Include="..\..\Core\Grand.Domain\Grand.Domain.csproj" />
2121
<ProjectReference Include="..\..\Core\Grand.Infrastructure\Grand.Infrastructure.csproj" />
2222
<ProjectReference Include="..\..\Core\Grand.SharedKernel\Grand.SharedKernel.csproj" />
23+
<ProjectReference Include="..\Grand.Web.Models\Grand.Web.Models.csproj" />
2324
<ProjectReference Include="..\Grand.Web.Common\Grand.Web.Common.csproj" />
2425
<ProjectReference Include="..\Grand.Web.Admin\Grand.Web.Admin.csproj" />
2526
<ProjectReference Include="..\Grand.Web.Vendor\Grand.Web.Vendor.csproj" />

0 commit comments

Comments
 (0)