diff --git a/.github/workflows/develop_dev-mixcore.yml b/.github/workflows/develop_dev-mixcore.yml index ed3737fdb..dd29dd84b 100644 --- a/.github/workflows/develop_dev-mixcore.yml +++ b/.github/workflows/develop_dev-mixcore.yml @@ -6,7 +6,7 @@ name: Build and deploy ASP.Net Core app to Azure Web App - dev-mixcore on: push: branches: - - develop + - features/cleanup-startup workflow_dispatch: jobs: diff --git a/.gitignore b/.gitignore index 79f870166..6d7aa006f 100644 --- a/.gitignore +++ b/.gitignore @@ -244,20 +244,10 @@ ModelManifest.xml .vscode/ *.db -src/applications/Mixcore/Properties/PublishProfiles/ - -src/shared/__pycache__/ -src/applications/Mixcore/MixContent/cache -src/applications/Mixcore/MixContent/Temp -src/applications/Mixcore/MixContent/*.db -src/applications/Mixcore/MixContent/*.db-shm -src/applications/Mixcore/MixContent/*.db-wal -src/applications/Mixcore/logs/ - -src/applications/Mixcore/MixContent/ - +src/applications/**/PublishProfiles/ +src/applications/**/mixcontent/ +src/applications/**/ServiceDependencies/ src/applications/Mixcore/wwwroot/portal-apps/ -src/test/__pycache__/ - -src/modules/**/MixContent \ No newline at end of file +src/**/__pycache__/ +src/**/logs/ diff --git a/src/applications/Mixcore/Controllers/AppController.cs b/src/applications/Mixcore/Controllers/AppController.cs index fb56e554c..1383d76d2 100644 --- a/src/applications/Mixcore/Controllers/AppController.cs +++ b/src/applications/Mixcore/Controllers/AppController.cs @@ -2,6 +2,7 @@ using Mix.Database.Services; using Mix.Lib.Interfaces; using Mix.Lib.Services; +using Mix.Shared.Models.Configurations; using Mix.Shared.Services; namespace Mixcore.Controllers @@ -13,16 +14,16 @@ public class AppController : MixControllerBase protected readonly MixCmsContext CmsContext; private readonly MixCacheService _cacheService; private readonly DatabaseService _databaseService; - - public AppController( + public AppController( IHttpContextAccessor httpContextAccessor, IPSecurityConfigService ipSecurityConfigService, IMixCmsService mixCmsService, DatabaseService databaseService, MixCmsContext cmsContext, MixCacheService cacheService, - IMixTenantService tenantService) - : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { CmsContext = cmsContext; Uow = new(CmsContext); @@ -36,7 +37,7 @@ protected override void ValidateRequest() base.ValidateRequest(); // If this site has not been inited yet - if (GlobalConfigService.Instance.AppSettings.IsInit) + if (GlobalConfig.IsInit) { IsValid = false; if (string.IsNullOrEmpty(_databaseService.GetConnectionString(MixConstants.CONST_CMS_CONNECTION))) @@ -45,7 +46,7 @@ protected override void ValidateRequest() } else { - var status = GlobalConfigService.Instance.AppSettings.InitStatus; + var status = GlobalConfig.InitStatus; RedirectUrl = $"/init/step{status}"; } } diff --git a/src/applications/Mixcore/Controllers/HomeController.cs b/src/applications/Mixcore/Controllers/HomeController.cs index aa48c4685..249b219e2 100644 --- a/src/applications/Mixcore/Controllers/HomeController.cs +++ b/src/applications/Mixcore/Controllers/HomeController.cs @@ -26,8 +26,9 @@ public HomeController( MixRepoDbRepository repoDbRepository, IMixMetadataService metadataService, MixCacheService cacheService, - IMixTenantService tenantService) - : base(httpContextAccessor, ipSecurityConfigService, mixCmsService, translator, databaseService, uow, cacheService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, ipSecurityConfigService, mixCmsService, translator, databaseService, uow, cacheService, tenantService, configuration) { _repoDbRepository = repoDbRepository; _metadataService = metadataService; @@ -38,7 +39,7 @@ protected override void ValidateRequest() base.ValidateRequest(); // If this site has not been inited yet - if (GlobalConfigService.Instance.AppSettings.IsInit) + if (GlobalConfig.IsInit) { IsValid = false; if (string.IsNullOrEmpty(DatabaseService.GetConnectionString(MixConstants.CONST_CMS_CONNECTION))) @@ -47,7 +48,7 @@ protected override void ValidateRequest() } else { - var status = GlobalConfigService.Instance.AppSettings.InitStatus; + var status = GlobalConfig.InitStatus; RedirectUrl = $"/init/step{status}"; } } diff --git a/src/applications/Mixcore/Controllers/InitController.cs b/src/applications/Mixcore/Controllers/InitController.cs index 5297a9083..040bf9b57 100644 --- a/src/applications/Mixcore/Controllers/InitController.cs +++ b/src/applications/Mixcore/Controllers/InitController.cs @@ -1,4 +1,5 @@ using Microsoft.AspNetCore.Mvc; +using Mix.Shared.Models.Configurations; using Mix.Shared.Services; using Mixcore.Domain.Constants; @@ -7,15 +8,18 @@ namespace Mixcore.Controllers public class InitController : MixControllerBase { private readonly MixEndpointService _mixEndpointService; + private readonly GlobalSettingsModel _globalConfig; public InitController( IHttpContextAccessor httpContextAccessor, IMixCmsService mixCmsService, IPSecurityConfigService ipSecurityConfigService, MixEndpointService mixEndpointService, - IMixTenantService tenantService) - : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { _mixEndpointService = mixEndpointService; + _globalConfig = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get()!; } [HttpGet] @@ -23,14 +27,14 @@ public InitController( [Route("init/{page}")] public IActionResult Index(string page) { - if (!GlobalConfigService.Instance.AppSettings.IsInit) + if (!_globalConfig.IsInit) { return Redirect("/"); } else { page ??= ""; - var initStatus = GlobalConfigService.Instance.AppSettings.InitStatus; + var initStatus = _globalConfig.InitStatus; switch (initStatus) { diff --git a/src/applications/Mixcore/Controllers/PageController.cs b/src/applications/Mixcore/Controllers/PageController.cs index f879e0716..81e692fdf 100644 --- a/src/applications/Mixcore/Controllers/PageController.cs +++ b/src/applications/Mixcore/Controllers/PageController.cs @@ -16,8 +16,9 @@ public class PageController : MixControllerBase private readonly MixRepoDbRepository _repoDbRepository; private readonly IMixMetadataService _metadataService; - public PageController(IHttpContextAccessor httpContextAccessor, IPSecurityConfigService ipSecurityConfigService, IMixCmsService mixCmsService, DatabaseService databaseService, MixCmsContext cmsContext, MixRepoDbRepository repoDbRepository, IMixMetadataService metadataService, MixCacheService cacheService, IMixTenantService tenantService) : - base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + public PageController(IHttpContextAccessor httpContextAccessor, IPSecurityConfigService ipSecurityConfigService, IMixCmsService mixCmsService, DatabaseService databaseService, MixCmsContext cmsContext, MixRepoDbRepository repoDbRepository, IMixMetadataService metadataService, MixCacheService cacheService, IMixTenantService tenantService, + IConfiguration configuration) : + base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { CmsContext = cmsContext; Uow = new(CmsContext); diff --git a/src/applications/Mixcore/Controllers/PortalController.cs b/src/applications/Mixcore/Controllers/PortalController.cs index 63cb0ddd2..594a18640 100644 --- a/src/applications/Mixcore/Controllers/PortalController.cs +++ b/src/applications/Mixcore/Controllers/PortalController.cs @@ -12,8 +12,9 @@ public PortalController( IHttpContextAccessor httpContextAccessor, IMixCmsService mixCmsService, DatabaseService databaseService, IPSecurityConfigService ipSecurityConfigService, - IMixTenantService tenantService) - : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { _databaseService = databaseService; } diff --git a/src/applications/Mixcore/Controllers/PostController.cs b/src/applications/Mixcore/Controllers/PostController.cs index 8747d0ff1..42f2c4612 100644 --- a/src/applications/Mixcore/Controllers/PostController.cs +++ b/src/applications/Mixcore/Controllers/PostController.cs @@ -28,8 +28,9 @@ public PostController( IMixMetadataService metadataService, UnitOfWorkInfo dbUow, MixCacheService cacheService, - IMixTenantService tenantService) - : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { CmsContext = cmsContext; Uow = new(CmsContext); diff --git a/src/applications/Mixcore/Controllers/SecurityController.cs b/src/applications/Mixcore/Controllers/SecurityController.cs index 9429a44b8..65bda546e 100644 --- a/src/applications/Mixcore/Controllers/SecurityController.cs +++ b/src/applications/Mixcore/Controllers/SecurityController.cs @@ -27,8 +27,9 @@ public SecurityController( MixIdentityService idService, TenantUserManager userManager, MixEndpointService mixEndpointService, - IMixTenantService tenantService) - : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) + : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { _signInManager = signInManager; _logger = logger; diff --git a/src/applications/Mixcore/Domain/Bases/MvcBaseController.cs b/src/applications/Mixcore/Domain/Bases/MvcBaseController.cs index c1227d659..394e7810d 100644 --- a/src/applications/Mixcore/Domain/Bases/MvcBaseController.cs +++ b/src/applications/Mixcore/Domain/Bases/MvcBaseController.cs @@ -20,7 +20,9 @@ public MvcBaseController( DatabaseService databaseService, UnitOfWorkInfo uow, MixCacheService cacheService, - IMixTenantService tenantService) : base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService) + IMixTenantService tenantService, + IConfiguration configuration) : + base(httpContextAccessor, mixCmsService, ipSecurityConfigService, tenantService, configuration) { Translator = translator; DatabaseService = databaseService; @@ -33,7 +35,7 @@ protected override void ValidateRequest() base.ValidateRequest(); // If this site has not been inited yet - if (GlobalConfigService.Instance.AppSettings.IsInit) + if (GlobalConfig.IsInit) { IsValid = false; if (string.IsNullOrEmpty(DatabaseService.GetConnectionString(MixConstants.CONST_CMS_CONNECTION))) @@ -42,7 +44,7 @@ protected override void ValidateRequest() } else { - var status = GlobalConfigService.Instance.AppSettings.InitStatus; + var status = GlobalConfig.InitStatus; RedirectUrl = $"/init/step{status}"; } } diff --git a/src/applications/Mixcore/Domain/ViewModels/PostContentViewModel.cs b/src/applications/Mixcore/Domain/ViewModels/PostContentViewModel.cs index 1e3fd017d..1d041f6f9 100644 --- a/src/applications/Mixcore/Domain/ViewModels/PostContentViewModel.cs +++ b/src/applications/Mixcore/Domain/ViewModels/PostContentViewModel.cs @@ -17,7 +17,7 @@ public PostContentViewModel() { } - public PostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public PostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/applications/Mixcore/Models/Cms/Sample/Aspnetroleclaim.cs b/src/applications/Mixcore/Models/Cms/Sample/Aspnetroleclaim.cs deleted file mode 100644 index dc0e1dbe7..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Aspnetroleclaim.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Aspnetroleclaim -{ - public int Id { get; set; } - - public Guid? MixRoleId { get; set; } - - public Guid RoleId { get; set; } - - public string ClaimType { get; set; } - - public string ClaimValue { get; set; } - - public virtual Mixrole MixRole { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserclaim.cs b/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserclaim.cs deleted file mode 100644 index 6dcff28ae..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserclaim.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Aspnetuserclaim -{ - public int Id { get; set; } - - public Guid? MixUserId1 { get; set; } - - public Guid UserId { get; set; } - - public string ClaimType { get; set; } - - public string ClaimValue { get; set; } - - public Guid? MixUserId { get; set; } - - public virtual Mixuser MixUser { get; set; } - - public virtual Mixuser MixUserId1Navigation { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserlogin.cs b/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserlogin.cs deleted file mode 100644 index 97b8b22d6..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserlogin.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Aspnetuserlogin -{ - public string LoginProvider { get; set; } - - public string ProviderKey { get; set; } - - public string ProviderDisplayName { get; set; } - - public Guid UserId { get; set; } - - public Guid? MixUserId { get; set; } - - public Guid? MixUserId1 { get; set; } - - public virtual Mixuser MixUser { get; set; } - - public virtual Mixuser MixUserId1Navigation { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserrole.cs b/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserrole.cs deleted file mode 100644 index 5c15b581a..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Aspnetuserrole.cs +++ /dev/null @@ -1,25 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Aspnetuserrole -{ - public Guid UserId { get; set; } - - public Guid RoleId { get; set; } - - public int MixTenantId { get; set; } - - public Guid? MixUserId1 { get; set; } - - public Guid? MixRoleId { get; set; } - - public Guid? MixUserId { get; set; } - - public virtual Mixrole MixRole { get; set; } - - public virtual Mixuser MixUser { get; set; } - - public virtual Mixuser MixUserId1Navigation { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Aspnetusertoken.cs b/src/applications/Mixcore/Models/Cms/Sample/Aspnetusertoken.cs deleted file mode 100644 index 54e7335f0..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Aspnetusertoken.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Aspnetusertoken -{ - public Guid UserId { get; set; } - - public string LoginProvider { get; set; } - - public string Name { get; set; } - - public string Value { get; set; } - - public Guid? MixUserId { get; set; } - - public virtual Mixuser MixUser { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Client.cs b/src/applications/Mixcore/Models/Cms/Sample/Client.cs deleted file mode 100644 index 3566ee082..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Client.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Client -{ - public string Id { get; set; } - - public bool Active { get; set; } - - public string AllowedOrigin { get; set; } - - public int ApplicationType { get; set; } - - public string Name { get; set; } - - public int RefreshTokenLifeTime { get; set; } - - public string Secret { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Contactaddress.cs b/src/applications/Mixcore/Models/Cms/Sample/Contactaddress.cs deleted file mode 100644 index 316c6e1d2..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Contactaddress.cs +++ /dev/null @@ -1,37 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Contactaddress -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Street { get; set; } - - public string District { get; set; } - - public string City { get; set; } - - public string Province { get; set; } - - public string Note { get; set; } - - public int? SysUserDataId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Efmigrationshistory.cs b/src/applications/Mixcore/Models/Cms/Sample/Efmigrationshistory.cs deleted file mode 100644 index b30900274..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Efmigrationshistory.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Efmigrationshistory -{ - public string MigrationId { get; set; } - - public string ProductVersion { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Metadata.cs b/src/applications/Mixcore/Models/Cms/Sample/Metadata.cs deleted file mode 100644 index 6e211a1a8..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Metadata.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Metadata -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string SeoContent { get; set; } - - public string Title { get; set; } - - public string Content { get; set; } - - public string Type { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Metadatacontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Metadatacontent.cs deleted file mode 100644 index 2d845e1c2..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Metadatacontent.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Metadatacontent -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public int? MetadataId { get; set; } - - public int? ContentId { get; set; } - - public string ContentType { get; set; } - - public string Description { get; set; } - - public string Image { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Metadatacontentassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Metadatacontentassociation.cs deleted file mode 100644 index 23cc835dd..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Metadatacontentassociation.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Metadatacontentassociation -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public int? MetadataId { get; set; } - - public int? ContentId { get; set; } - - public string ContentType { get; set; } - - public string Description { get; set; } - - public string Image { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixapplication.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixapplication.cs deleted file mode 100644 index 3d9a2d110..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixapplication.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixapplication -{ - public int Id { get; set; } - - public string BaseHref { get; set; } - - public string BaseRoute { get; set; } - - public string Domain { get; set; } - - public string BaseApiUrl { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixtenant MixTenant { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixcache.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixcache.cs deleted file mode 100644 index f2202e3de..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixcache.cs +++ /dev/null @@ -1,27 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixcache -{ - public Guid Id { get; set; } - - public string Keyword { get; set; } - - public string Value { get; set; } - - public DateTime? ExpiredDateTime { get; set; } - - public string ModifiedBy { get; set; } - - public string CreatedBy { get; set; } - - public DateTime? LastModified { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixconfiguration.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixconfiguration.cs deleted file mode 100644 index f5f7187b7..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixconfiguration.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixconfiguration -{ - public int Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public string SystemName { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixconfigurationcontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixconfigurationcontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixconfigurationcontent.cs deleted file mode 100644 index 65e608805..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixconfigurationcontent.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixconfigurationcontent -{ - public int Id { get; set; } - - public string DefaultContent { get; set; } - - public int? MixConfigurationId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string DisplayName { get; set; } - - public string SystemName { get; set; } - - public string Description { get; set; } - - public string Content { get; set; } - - public string Category { get; set; } - - public string DataType { get; set; } - - public virtual Mixconfiguration MixConfiguration { get; set; } - - public virtual Mixculture MixCulture { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixcontributor.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixcontributor.cs deleted file mode 100644 index e950fa5d6..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixcontributor.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixcontributor -{ - public int Id { get; set; } - - public int MixTenantId { get; set; } - - public Guid UserId { get; set; } - - public bool IsOwner { get; set; } - - public int? IntContentId { get; set; } - - public Guid? GuidContentId { get; set; } - - public string ContentType { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixcorecmshelper.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixcorecmshelper.cs deleted file mode 100644 index 9c1a59282..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixcorecmshelper.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixcorecmshelper -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Description { get; set; } - - public string SampleCode { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixculture.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixculture.cs deleted file mode 100644 index b276aa4d7..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixculture.cs +++ /dev/null @@ -1,57 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixculture -{ - public int Id { get; set; } - - public string Alias { get; set; } - - public string Icon { get; set; } - - public string Lcid { get; set; } - - public string Specificulture { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixconfigurationcontents { get; } = new List(); - - public virtual ICollection Mixdatacontentassociations { get; } = new List(); - - public virtual ICollection Mixdatacontents { get; } = new List(); - - public virtual ICollection Mixdatacontentvalues { get; } = new List(); - - public virtual ICollection Mixlanguagecontents { get; } = new List(); - - public virtual ICollection Mixmodulecontents { get; } = new List(); - - public virtual ICollection Mixmoduledata { get; } = new List(); - - public virtual ICollection Mixpagecontents { get; } = new List(); - - public virtual ICollection Mixpostcontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabase.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabase.cs deleted file mode 100644 index e070a8f10..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabase.cs +++ /dev/null @@ -1,53 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabase -{ - public int Id { get; set; } - - public string SystemName { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public string Type { get; set; } - - public string ReadPermissions { get; set; } - - public string CreatePermissions { get; set; } - - public string UpdatePermissions { get; set; } - - public string DeletePermissions { get; set; } - - public bool SelfManaged { get; set; } - - public int? MixDatabaseContextDatabaseAssociationId { get; set; } - - public int? MixTenantId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public virtual Mixdatabasecontextdatabaseassociation MixDatabaseContextDatabaseAssociation { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixdata { get; } = new List(); - - public virtual ICollection Mixdatabasecolumns { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaseassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaseassociation.cs deleted file mode 100644 index ca25d975d..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaseassociation.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabaseassociation -{ - public Guid Id { get; set; } - - public int MixTenantId { get; set; } - - public string ParentDatabaseName { get; set; } - - public string ChildDatabaseName { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecolumn.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecolumn.cs deleted file mode 100644 index 9a1bedf2c..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecolumn.cs +++ /dev/null @@ -1,43 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabasecolumn -{ - public int Id { get; set; } - - public string SystemName { get; set; } - - public string DisplayName { get; set; } - - public string MixDatabaseName { get; set; } - - public string DataType { get; set; } - - public string Configurations { get; set; } - - public int? ReferenceId { get; set; } - - public string DefaultValue { get; set; } - - public int MixDatabaseId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public virtual Mixdatabase MixDatabase { get; set; } - - public virtual ICollection Mixdatacontentvalues { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontext.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontext.cs deleted file mode 100644 index a92608f33..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontext.cs +++ /dev/null @@ -1,41 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabasecontext -{ - public int Id { get; set; } - - public string DatabaseProvider { get; set; } - - public string ConnectionString { get; set; } - - public int? MixDatabaseContextDatabaseAssociationId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public string SystemName { get; set; } - - public virtual Mixdatabasecontextdatabaseassociation MixDatabaseContextDatabaseAssociation { get; set; } - - public virtual Mixtenant MixTenant { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontextdatabaseassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontextdatabaseassociation.cs deleted file mode 100644 index 5b207c631..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabasecontextdatabaseassociation.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabasecontextdatabaseassociation -{ - public int Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public int Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public virtual ICollection Mixdatabasecontexts { get; } = new List(); - - public virtual ICollection Mixdatabases { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaserelationship.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaserelationship.cs deleted file mode 100644 index c9a64628a..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatabaserelationship.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatabaserelationship -{ - public int Id { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public string DisplayName { get; set; } - - public string SourceDatabaseName { get; set; } - - public string DestinateDatabaseName { get; set; } - - public string Type { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontent.cs deleted file mode 100644 index b68d10837..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontent.cs +++ /dev/null @@ -1,81 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatacontent -{ - public Guid Id { get; set; } - - public int MixDatabaseId { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public Guid ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string Title { get; set; } - - public string Excerpt { get; set; } - - public string Content { get; set; } - - public int? LayoutId { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string Source { get; set; } - - public string SeoDescription { get; set; } - - public string SeoKeywords { get; set; } - - public string SeoName { get; set; } - - public string SeoTitle { get; set; } - - public DateTime? PublishedDateTime { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixdatum MixData { get; set; } - - public virtual ICollection Mixapplications { get; } = new List(); - - public virtual ICollection Mixdatacontentvalues { get; } = new List(); - - public virtual ICollection Mixmodulecontents { get; } = new List(); - - public virtual ICollection Mixpagecontents { get; } = new List(); - - public virtual ICollection Mixpostcontents { get; } = new List(); - - public virtual ICollection Mixthemes { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentassociation.cs deleted file mode 100644 index 393c8dc40..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentassociation.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatacontentassociation -{ - public Guid Id { get; set; } - - public int MixDatabaseId { get; set; } - - public string MixDatabaseName { get; set; } - - public string ParentType { get; set; } - - public Guid DataContentId { get; set; } - - public Guid? GuidParentId { get; set; } - - public int? IntParentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public Guid ParentId { get; set; } - - public int MixCultureId { get; set; } - - public virtual Mixculture MixCulture { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentvalue.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentvalue.cs deleted file mode 100644 index 256f7f60d..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatacontentvalue.cs +++ /dev/null @@ -1,69 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatacontentvalue -{ - public Guid Id { get; set; } - - public string MixDatabaseColumnName { get; set; } - - public string MixDatabaseName { get; set; } - - public string DataType { get; set; } - - public bool? BooleanValue { get; set; } - - public DateTime? DateTimeValue { get; set; } - - public double? DoubleValue { get; set; } - - public int? IntegerValue { get; set; } - - public string StringValue { get; set; } - - public string EncryptValue { get; set; } - - public string EncryptKey { get; set; } - - public string EncryptType { get; set; } - - public int MixDatabaseColumnId { get; set; } - - public int MixDatabaseId { get; set; } - - public Guid? MixDataContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public Guid ParentId { get; set; } - - public int MixCultureId { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixdatabasecolumn MixDatabaseColumn { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdatum.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdatum.cs deleted file mode 100644 index 4387b9566..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdatum.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdatum -{ - public Guid Id { get; set; } - - public int MixTenantId { get; set; } - - public int MixDatabaseId { get; set; } - - public string MixDatabaseName { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public virtual Mixdatabase MixDatabase { get; set; } - - public virtual ICollection Mixdatacontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdiscussion.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdiscussion.cs deleted file mode 100644 index 4a03a0213..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdiscussion.cs +++ /dev/null @@ -1,37 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdiscussion -{ - public int Id { get; set; } - - public int MixTenantId { get; set; } - - public int? ParentId { get; set; } - - public Guid UserId { get; set; } - - public string Content { get; set; } - - public int? IntContentId { get; set; } - - public Guid? GuidContentId { get; set; } - - public string ContentType { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixdomain.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixdomain.cs deleted file mode 100644 index 7790b3547..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixdomain.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixdomain -{ - public int Id { get; set; } - - public string Host { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixtenant MixTenant { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixlanguage.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixlanguage.cs deleted file mode 100644 index a7225997e..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixlanguage.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixlanguage -{ - public int Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public string SystemName { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixlanguagecontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixlanguagecontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixlanguagecontent.cs deleted file mode 100644 index 9c153f046..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixlanguagecontent.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixlanguagecontent -{ - public int Id { get; set; } - - public string DefaultContent { get; set; } - - public int? MixLanguageId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string DisplayName { get; set; } - - public string SystemName { get; set; } - - public string Description { get; set; } - - public string Content { get; set; } - - public string Category { get; set; } - - public string DataType { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixlanguage MixLanguage { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixmedium.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixmedium.cs deleted file mode 100644 index a6b692cc9..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixmedium.cs +++ /dev/null @@ -1,51 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixmedium -{ - public Guid Id { get; set; } - - public string Extension { get; set; } - - public string FileFolder { get; set; } - - public string FileName { get; set; } - - public string FileProperties { get; set; } - - public long FileSize { get; set; } - - public string FileType { get; set; } - - public string Title { get; set; } - - public string Tags { get; set; } - - public string Source { get; set; } - - public string TargetUrl { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixtenant MixTenant { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixmodule.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixmodule.cs deleted file mode 100644 index d30b1472f..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixmodule.cs +++ /dev/null @@ -1,37 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixmodule -{ - public int Id { get; set; } - - public string Type { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public string SystemName { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixmodulecontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixmodulecontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixmodulecontent.cs deleted file mode 100644 index 2d5232a8e..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixmodulecontent.cs +++ /dev/null @@ -1,85 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixmodulecontent -{ - public int Id { get; set; } - - public string SystemName { get; set; } - - public string ClassName { get; set; } - - public int? PageSize { get; set; } - - public string Type { get; set; } - - public string SimpleDataColumns { get; set; } - - public int? MixModuleId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string Title { get; set; } - - public string Excerpt { get; set; } - - public string Content { get; set; } - - public int? LayoutId { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string Source { get; set; } - - public string SeoDescription { get; set; } - - public string SeoKeywords { get; set; } - - public string SeoName { get; set; } - - public string SeoTitle { get; set; } - - public DateTime? PublishedDateTime { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataContentId { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixmodule MixModule { get; set; } - - public virtual ICollection Mixmoduledata { get; } = new List(); - - public virtual ICollection Mixmodulepostassociations { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixmoduledatum.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixmoduledatum.cs deleted file mode 100644 index a7745ab93..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixmoduledatum.cs +++ /dev/null @@ -1,69 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixmoduledatum -{ - public int Id { get; set; } - - public string SimpleDataColumns { get; set; } - - public string Value { get; set; } - - public int? MixModuleContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string Title { get; set; } - - public string Excerpt { get; set; } - - public string Content { get; set; } - - public int? LayoutId { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string Source { get; set; } - - public string SeoDescription { get; set; } - - public string SeoKeywords { get; set; } - - public string SeoName { get; set; } - - public string SeoTitle { get; set; } - - public DateTime? PublishedDateTime { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixmodulecontent MixModuleContent { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixmodulepostassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixmodulepostassociation.cs deleted file mode 100644 index 701146aa9..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixmodulepostassociation.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixmodulepostassociation -{ - public int Id { get; set; } - - public int? MixModuleContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public int Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public virtual Mixmodulecontent MixModuleContent { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpage.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpage.cs deleted file mode 100644 index bb8317838..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpage.cs +++ /dev/null @@ -1,37 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpage -{ - public int Id { get; set; } - - public int? MixPostContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixpostcontent MixPostContent { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixpagecontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpagecontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpagecontent.cs deleted file mode 100644 index 4067e2774..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpagecontent.cs +++ /dev/null @@ -1,81 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpagecontent -{ - public int Id { get; set; } - - public string ClassName { get; set; } - - public int? PageSize { get; set; } - - public string Type { get; set; } - - public int? MixPageId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string Title { get; set; } - - public string Excerpt { get; set; } - - public string Content { get; set; } - - public int? LayoutId { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string Source { get; set; } - - public string SeoDescription { get; set; } - - public string SeoKeywords { get; set; } - - public string SeoName { get; set; } - - public string SeoTitle { get; set; } - - public DateTime? PublishedDateTime { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataContentId { get; set; } - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixpage MixPage { get; set; } - - public virtual ICollection Mixpagemoduleassociations { get; } = new List(); - - public virtual ICollection Mixpagepostassociations { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpagemoduleassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpagemoduleassociation.cs deleted file mode 100644 index 8d5e2b167..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpagemoduleassociation.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpagemoduleassociation -{ - public int Id { get; set; } - - public int? MixPageContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public int Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public virtual Mixpagecontent MixPageContent { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpagepostassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpagepostassociation.cs deleted file mode 100644 index 382246a61..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpagepostassociation.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpagepostassociation -{ - public int Id { get; set; } - - public int? MixPageContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public int Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } - - public virtual Mixpagecontent MixPageContent { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpost.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpost.cs deleted file mode 100644 index ae6a39b7e..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpost.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpost -{ - public int Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixpostcontents { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpostcontent.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpostcontent.cs deleted file mode 100644 index 2950bd2f7..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpostcontent.cs +++ /dev/null @@ -1,81 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpostcontent -{ - public int Id { get; set; } - - public string ClassName { get; set; } - - public int? MixPostId { get; set; } - - public int? MixPostContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public string Specificulture { get; set; } - - public string Icon { get; set; } - - public bool IsPublic { get; set; } - - public int ParentId { get; set; } - - public int MixCultureId { get; set; } - - public string Title { get; set; } - - public string Excerpt { get; set; } - - public string Content { get; set; } - - public int? LayoutId { get; set; } - - public int? TemplateId { get; set; } - - public string Image { get; set; } - - public string Source { get; set; } - - public string SeoDescription { get; set; } - - public string SeoKeywords { get; set; } - - public string SeoName { get; set; } - - public string SeoTitle { get; set; } - - public DateTime? PublishedDateTime { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataContentId { get; set; } - - public virtual ICollection InverseMixPostContent { get; } = new List(); - - public virtual Mixculture MixCulture { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixpost MixPost { get; set; } - - public virtual Mixpostcontent MixPostContent { get; set; } - - public virtual ICollection Mixpages { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixpostpostassociation.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixpostpostassociation.cs deleted file mode 100644 index 9765fbce7..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixpostpostassociation.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixpostpostassociation -{ - public int Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public int Status { get; set; } - - public bool IsDeleted { get; set; } - - public int MixTenantId { get; set; } - - public int ParentId { get; set; } - - public int ChildId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixrole.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixrole.cs deleted file mode 100644 index 8c14a3455..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixrole.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixrole -{ - public Guid Id { get; set; } - - public string Name { get; set; } - - public string NormalizedName { get; set; } - - public string ConcurrencyStamp { get; set; } - - public virtual ICollection Aspnetroleclaims { get; } = new List(); - - public virtual ICollection Aspnetuserroles { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixtenant.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixtenant.cs deleted file mode 100644 index 4e433369a..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixtenant.cs +++ /dev/null @@ -1,57 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixtenant -{ - public int Id { get; set; } - - public string PrimaryDomain { get; set; } - - public string SystemName { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public virtual ICollection Mixapplications { get; } = new List(); - - public virtual ICollection Mixconfigurations { get; } = new List(); - - public virtual ICollection Mixcultures { get; } = new List(); - - public virtual ICollection Mixdatabasecontexts { get; } = new List(); - - public virtual ICollection Mixdatabases { get; } = new List(); - - public virtual ICollection Mixdomains { get; } = new List(); - - public virtual ICollection Mixlanguages { get; } = new List(); - - public virtual ICollection Mixmedia { get; } = new List(); - - public virtual ICollection Mixmodules { get; } = new List(); - - public virtual ICollection Mixpages { get; } = new List(); - - public virtual ICollection Mixposts { get; } = new List(); - - public virtual ICollection Mixthemes { get; } = new List(); - - public virtual ICollection Mixurlaliases { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixtheme.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixtheme.cs deleted file mode 100644 index ce7077274..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixtheme.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixtheme -{ - public int Id { get; set; } - - public string ImageUrl { get; set; } - - public string PreviewUrl { get; set; } - - public string AssetFolder { get; set; } - - public string TemplateFolder { get; set; } - - public string MixDatabaseName { get; set; } - - public Guid? MixDataContentId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public string SystemName { get; set; } - - public virtual Mixdatacontent MixDataContent { get; set; } - - public virtual Mixtenant MixTenant { get; set; } - - public virtual ICollection Mixviewtemplates { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixurlalias.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixurlalias.cs deleted file mode 100644 index 76357af9e..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixurlalias.cs +++ /dev/null @@ -1,39 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixurlalias -{ - public int Id { get; set; } - - public int? SourceContentId { get; set; } - - public Guid? SourceContentGuidId { get; set; } - - public string Alias { get; set; } - - public int Type { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public string DisplayName { get; set; } - - public string Description { get; set; } - - public int MixTenantId { get; set; } - - public virtual Mixtenant MixTenant { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixuser.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixuser.cs deleted file mode 100644 index 4fe633aa2..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixuser.cs +++ /dev/null @@ -1,61 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixuser -{ - public Guid Id { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public bool IsActived { get; set; } - - public DateTime? LastModified { get; set; } - - public string ModifiedBy { get; set; } - - public string RegisterType { get; set; } - - public DateTime? LockoutEnd { get; set; } - - public string UserName { get; set; } - - public string NormalizedUserName { get; set; } - - public string Email { get; set; } - - public string NormalizedEmail { get; set; } - - public bool EmailConfirmed { get; set; } - - public string PasswordHash { get; set; } - - public string SecurityStamp { get; set; } - - public string ConcurrencyStamp { get; set; } - - public string PhoneNumber { get; set; } - - public bool PhoneNumberConfirmed { get; set; } - - public bool TwoFactorEnabled { get; set; } - - public bool LockoutEnabled { get; set; } - - public int AccessFailedCount { get; set; } - - public virtual ICollection AspnetuserclaimMixUserId1Navigations { get; } = new List(); - - public virtual ICollection AspnetuserclaimMixUsers { get; } = new List(); - - public virtual ICollection AspnetuserloginMixUserId1Navigations { get; } = new List(); - - public virtual ICollection AspnetuserloginMixUsers { get; } = new List(); - - public virtual ICollection AspnetuserroleMixUserId1Navigations { get; } = new List(); - - public virtual ICollection AspnetuserroleMixUsers { get; } = new List(); - - public virtual ICollection Aspnetusertokens { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixusertenant.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixusertenant.cs deleted file mode 100644 index b4c0b7370..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixusertenant.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixusertenant -{ - public int TenantId { get; set; } - - public Guid MixUserId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Mixviewtemplate.cs b/src/applications/Mixcore/Models/Cms/Sample/Mixviewtemplate.cs deleted file mode 100644 index e5d848b64..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Mixviewtemplate.cs +++ /dev/null @@ -1,45 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Mixviewtemplate -{ - public int Id { get; set; } - - public int MixTenantId { get; set; } - - public string Content { get; set; } - - public string Extension { get; set; } - - public string FileFolder { get; set; } - - public string FileName { get; set; } - - public string FolderType { get; set; } - - public string Scripts { get; set; } - - public string Styles { get; set; } - - public string MixThemeName { get; set; } - - public int MixThemeId { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } - - public virtual Mixtheme MixTheme { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionrequest.cs b/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionrequest.cs deleted file mode 100644 index 6b54f53ad..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionrequest.cs +++ /dev/null @@ -1,59 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Onepaytransactionrequest -{ - public int Id { get; set; } - - public int VpcVersion { get; set; } - - public string VpcCurrency { get; set; } - - public string VpcCommand { get; set; } - - public string VpcAccessCode { get; set; } - - public string VpcMerchant { get; set; } - - public string VpcLocale { get; set; } - - public string VpcReturnUrl { get; set; } - - public string VpcMerchTxnRef { get; set; } - - public string VpcOrderInfo { get; set; } - - public string VpcAmount { get; set; } - - public string VpcTicketNo { get; set; } - - public string AgainLink { get; set; } - - public string Title { get; set; } - - public string VpcSecureHash { get; set; } - - public string VpcCustomerPhone { get; set; } - - public string VpcCustomerEmail { get; set; } - - public string VpcCustomerId { get; set; } - - public string OnepayStatus { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionresponse.cs b/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionresponse.cs deleted file mode 100644 index 6ceb49aeb..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Onepaytransactionresponse.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Onepaytransactionresponse -{ - public int Id { get; set; } - - public string VpcCommand { get; set; } - - public string VpcLocale { get; set; } - - public string VpcCurrencyCode { get; set; } - - public string VpcMerchTxnRef { get; set; } - - public string VpcMerchant { get; set; } - - public string VpcOrderInfo { get; set; } - - public string VpcAmount { get; set; } - - public string VpcTxnResponseCode { get; set; } - - public string VpcTransactionNo { get; set; } - - public string VpcMessage { get; set; } - - public string VpcAdditionData { get; set; } - - public string VpcSecureHash { get; set; } - - public string OnepayStatus { get; set; } - - public DateTime CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool IsDeleted { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Orderdetail.cs b/src/applications/Mixcore/Models/Cms/Sample/Orderdetail.cs deleted file mode 100644 index 0688fc3ad..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Orderdetail.cs +++ /dev/null @@ -1,41 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Orderdetail -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Description { get; set; } - - public float? Total { get; set; } - - public string Currency { get; set; } - - public string UserId { get; set; } - - public string OrderStatus { get; set; } - - public string PaymentGateway { get; set; } - - public int? CountTotal { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Orderitem.cs b/src/applications/Mixcore/Models/Cms/Sample/Orderitem.cs deleted file mode 100644 index da70b0c40..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Orderitem.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Orderitem -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Description { get; set; } - - public string Image { get; set; } - - public int? PostId { get; set; } - - public float? Price { get; set; } - - public int? Quantity { get; set; } - - public float? Total { get; set; } - - public string Currency { get; set; } - - public int? OrderId { get; set; } - - public string ReferenceUrl { get; set; } - - public int? OrderDetailId { get; set; } - - public float? Percent { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Productdetail.cs b/src/applications/Mixcore/Models/Cms/Sample/Productdetail.cs deleted file mode 100644 index 1e12e8ca0..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Productdetail.cs +++ /dev/null @@ -1,47 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Productdetail -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public float? Price { get; set; } - - public string Brands { get; set; } - - public int? ParentId { get; set; } - - public string ParentType { get; set; } - - public string DesignBy { get; set; } - - public string Information { get; set; } - - public string InformationImage { get; set; } - - public string Size { get; set; } - - public string SizeImage { get; set; } - - public string Document { get; set; } - - public string MaintenanceDocument { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzBlobTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzBlobTrigger.cs deleted file mode 100644 index 8adf9a831..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzBlobTrigger.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzBlobTrigger -{ - public string SchedName { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public byte[] BlobData { get; set; } - - public virtual QrtzTrigger QrtzTrigger { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzCalendar.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzCalendar.cs deleted file mode 100644 index 294ad96c4..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzCalendar.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzCalendar -{ - public string SchedName { get; set; } - - public string CalendarName { get; set; } - - public byte[] Calendar { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzCronTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzCronTrigger.cs deleted file mode 100644 index b3099a3da..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzCronTrigger.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzCronTrigger -{ - public string SchedName { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public string CronExpression { get; set; } - - public string TimeZoneId { get; set; } - - public virtual QrtzTrigger QrtzTrigger { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzFiredTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzFiredTrigger.cs deleted file mode 100644 index 0dea074c2..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzFiredTrigger.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzFiredTrigger -{ - public string SchedName { get; set; } - - public string EntryId { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public string InstanceName { get; set; } - - public long FiredTime { get; set; } - - public long SchedTime { get; set; } - - public int Priority { get; set; } - - public string State { get; set; } - - public string JobName { get; set; } - - public string JobGroup { get; set; } - - public bool? IsNonconcurrent { get; set; } - - public bool? RequestsRecovery { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzJobDetail.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzJobDetail.cs deleted file mode 100644 index 3ffd9c3a4..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzJobDetail.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzJobDetail -{ - public string SchedName { get; set; } - - public string JobName { get; set; } - - public string JobGroup { get; set; } - - public string Description { get; set; } - - public string JobClassName { get; set; } - - public bool IsDurable { get; set; } - - public bool IsNonconcurrent { get; set; } - - public bool IsUpdateData { get; set; } - - public bool RequestsRecovery { get; set; } - - public byte[] JobData { get; set; } - - public virtual ICollection QrtzTriggers { get; } = new List(); -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzLock.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzLock.cs deleted file mode 100644 index 5bdb5e9e6..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzLock.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzLock -{ - public string SchedName { get; set; } - - public string LockName { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzPausedTriggerGrp.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzPausedTriggerGrp.cs deleted file mode 100644 index 4be7fc34c..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzPausedTriggerGrp.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzPausedTriggerGrp -{ - public string SchedName { get; set; } - - public string TriggerGroup { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzSchedulerState.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzSchedulerState.cs deleted file mode 100644 index fa32e769d..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzSchedulerState.cs +++ /dev/null @@ -1,15 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzSchedulerState -{ - public string SchedName { get; set; } - - public string InstanceName { get; set; } - - public long LastCheckinTime { get; set; } - - public long CheckinInterval { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpleTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpleTrigger.cs deleted file mode 100644 index 67ab20a78..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpleTrigger.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzSimpleTrigger -{ - public string SchedName { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public long RepeatCount { get; set; } - - public long RepeatInterval { get; set; } - - public long TimesTriggered { get; set; } - - public virtual QrtzTrigger QrtzTrigger { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpropTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpropTrigger.cs deleted file mode 100644 index 64cf4a59c..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzSimpropTrigger.cs +++ /dev/null @@ -1,39 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzSimpropTrigger -{ - public string SchedName { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public string StrProp1 { get; set; } - - public string StrProp2 { get; set; } - - public string StrProp3 { get; set; } - - public int? IntProp1 { get; set; } - - public int? IntProp2 { get; set; } - - public long? LongProp1 { get; set; } - - public long? LongProp2 { get; set; } - - public decimal? DecProp1 { get; set; } - - public decimal? DecProp2 { get; set; } - - public bool? BoolProp1 { get; set; } - - public bool? BoolProp2 { get; set; } - - public string TimeZoneId { get; set; } - - public virtual QrtzTrigger QrtzTrigger { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/QrtzTrigger.cs b/src/applications/Mixcore/Models/Cms/Sample/QrtzTrigger.cs deleted file mode 100644 index e088b9578..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/QrtzTrigger.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class QrtzTrigger -{ - public string SchedName { get; set; } - - public string TriggerName { get; set; } - - public string TriggerGroup { get; set; } - - public string JobName { get; set; } - - public string JobGroup { get; set; } - - public string Description { get; set; } - - public long? NextFireTime { get; set; } - - public long? PrevFireTime { get; set; } - - public int? Priority { get; set; } - - public string TriggerState { get; set; } - - public string TriggerType { get; set; } - - public long StartTime { get; set; } - - public long? EndTime { get; set; } - - public string CalendarName { get; set; } - - public short? MisfireInstr { get; set; } - - public byte[] JobData { get; set; } - - public virtual QrtzBlobTrigger QrtzBlobTrigger { get; set; } - - public virtual QrtzCronTrigger QrtzCronTrigger { get; set; } - - public virtual QrtzJobDetail QrtzJobDetail { get; set; } - - public virtual QrtzSimpleTrigger QrtzSimpleTrigger { get; set; } - - public virtual QrtzSimpropTrigger QrtzSimpropTrigger { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Refreshtoken.cs b/src/applications/Mixcore/Models/Cms/Sample/Refreshtoken.cs deleted file mode 100644 index 0440efcdb..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Refreshtoken.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Refreshtoken -{ - public Guid Id { get; set; } - - public string ClientId { get; set; } - - public string Email { get; set; } - - public string Username { get; set; } - - public DateTime ExpiresUtc { get; set; } - - public DateTime IssuedUtc { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Shoppingcart.cs b/src/applications/Mixcore/Models/Cms/Sample/Shoppingcart.cs deleted file mode 100644 index 93a285ce1..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Shoppingcart.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Shoppingcart -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string UserId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Syscategory.cs b/src/applications/Mixcore/Models/Cms/Sample/Syscategory.cs deleted file mode 100644 index 67c0247a8..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Syscategory.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Syscategory -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Description { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Sysmedium.cs b/src/applications/Mixcore/Models/Cms/Sample/Sysmedium.cs deleted file mode 100644 index 295e03bfe..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Sysmedium.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Sysmedium -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Type { get; set; } - - public string File { get; set; } - - public int? ProductDetailsId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Sysmenuitem.cs b/src/applications/Mixcore/Models/Cms/Sample/Sysmenuitem.cs deleted file mode 100644 index b32730cf0..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Sysmenuitem.cs +++ /dev/null @@ -1,49 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Sysmenuitem -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Url { get; set; } - - public string Icon { get; set; } - - public string Type { get; set; } - - public string Target { get; set; } - - public string TargetId { get; set; } - - public string Classes { get; set; } - - public string Description { get; set; } - - public string Alt { get; set; } - - public string Hreflang { get; set; } - - public int? SysMenuItemId { get; set; } - - public int? SysNavigationId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Sysnavigation.cs b/src/applications/Mixcore/Models/Cms/Sample/Sysnavigation.cs deleted file mode 100644 index 3d16c54fa..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Sysnavigation.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Sysnavigation -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Name { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Syspermission.cs b/src/applications/Mixcore/Models/Cms/Sample/Syspermission.cs deleted file mode 100644 index 380ce8b50..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Syspermission.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Syspermission -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Icon { get; set; } - - public string Type { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Syspermissionendpoint.cs b/src/applications/Mixcore/Models/Cms/Sample/Syspermissionendpoint.cs deleted file mode 100644 index 2b26429be..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Syspermissionendpoint.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Syspermissionendpoint -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Path { get; set; } - - public string Method { get; set; } - - public string Description { get; set; } - - public int? SysPermissionId { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Systag.cs b/src/applications/Mixcore/Models/Cms/Sample/Systag.cs deleted file mode 100644 index f27116bab..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Systag.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Systag -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Title { get; set; } - - public string Slug { get; set; } - - public string Type { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Sysuserdatum.cs b/src/applications/Mixcore/Models/Cms/Sample/Sysuserdatum.cs deleted file mode 100644 index 4e8451233..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Sysuserdatum.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Sysuserdatum -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string Avatar { get; set; } - - public string ParentId { get; set; } - - public string ParentType { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/Sysuserpermission.cs b/src/applications/Mixcore/Models/Cms/Sample/Sysuserpermission.cs deleted file mode 100644 index a939fb047..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/Sysuserpermission.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Mixcore.Models.Cms.Sample; - -public partial class Sysuserpermission -{ - public int Id { get; set; } - - public DateTime? CreatedDateTime { get; set; } - - public DateTime? LastModified { get; set; } - - public int? MixTenantId { get; set; } - - public string CreatedBy { get; set; } - - public string ModifiedBy { get; set; } - - public int? Priority { get; set; } - - public string Status { get; set; } - - public bool? IsDeleted { get; set; } - - public string UserId { get; set; } - - public int? PermissionId { get; set; } - - public string Description { get; set; } -} diff --git a/src/applications/Mixcore/Models/Cms/Sample/TanconstNestoContext.cs b/src/applications/Mixcore/Models/Cms/Sample/TanconstNestoContext.cs deleted file mode 100644 index 19e42f483..000000000 --- a/src/applications/Mixcore/Models/Cms/Sample/TanconstNestoContext.cs +++ /dev/null @@ -1,3019 +0,0 @@ -using System; -using System.Collections.Generic; -using Microsoft.EntityFrameworkCore; - -namespace Mixcore.Models.Cms.Sample; - -public partial class TanconstNestoContext : DbContext -{ - public TanconstNestoContext() - { - } - - public TanconstNestoContext(DbContextOptions options) - : base(options) - { - } - - public virtual DbSet Aspnetroleclaims { get; set; } - - public virtual DbSet Aspnetuserclaims { get; set; } - - public virtual DbSet Aspnetuserlogins { get; set; } - - public virtual DbSet Aspnetuserroles { get; set; } - - public virtual DbSet Aspnetusertokens { get; set; } - - public virtual DbSet Clients { get; set; } - - public virtual DbSet Contactaddresses { get; set; } - - public virtual DbSet Efmigrationshistories { get; set; } - - public virtual DbSet Metadata { get; set; } - - public virtual DbSet Metadatacontents { get; set; } - - public virtual DbSet Metadatacontentassociations { get; set; } - - public virtual DbSet Mixapplications { get; set; } - - public virtual DbSet Mixcaches { get; set; } - - public virtual DbSet Mixconfigurations { get; set; } - - public virtual DbSet Mixconfigurationcontents { get; set; } - - public virtual DbSet Mixcontributors { get; set; } - - public virtual DbSet Mixcorecmshelpers { get; set; } - - public virtual DbSet Mixcultures { get; set; } - - public virtual DbSet Mixdatabases { get; set; } - - public virtual DbSet Mixdatabaseassociations { get; set; } - - public virtual DbSet Mixdatabasecolumns { get; set; } - - public virtual DbSet Mixdatabasecontexts { get; set; } - - public virtual DbSet Mixdatabasecontextdatabaseassociations { get; set; } - - public virtual DbSet Mixdatabaserelationships { get; set; } - - public virtual DbSet Mixdatacontents { get; set; } - - public virtual DbSet Mixdatacontentassociations { get; set; } - - public virtual DbSet Mixdatacontentvalues { get; set; } - - public virtual DbSet Mixdata { get; set; } - - public virtual DbSet Mixdiscussions { get; set; } - - public virtual DbSet Mixdomains { get; set; } - - public virtual DbSet Mixlanguages { get; set; } - - public virtual DbSet Mixlanguagecontents { get; set; } - - public virtual DbSet Mixmedia { get; set; } - - public virtual DbSet Mixmodules { get; set; } - - public virtual DbSet Mixmodulecontents { get; set; } - - public virtual DbSet Mixmoduledata { get; set; } - - public virtual DbSet Mixmodulepostassociations { get; set; } - - public virtual DbSet Mixpages { get; set; } - - public virtual DbSet Mixpagecontents { get; set; } - - public virtual DbSet Mixpagemoduleassociations { get; set; } - - public virtual DbSet Mixpagepostassociations { get; set; } - - public virtual DbSet Mixposts { get; set; } - - public virtual DbSet Mixpostcontents { get; set; } - - public virtual DbSet Mixpostpostassociations { get; set; } - - public virtual DbSet Mixroles { get; set; } - - public virtual DbSet Mixtenants { get; set; } - - public virtual DbSet Mixthemes { get; set; } - - public virtual DbSet Mixurlaliases { get; set; } - - public virtual DbSet Mixusers { get; set; } - - public virtual DbSet Mixusertenants { get; set; } - - public virtual DbSet Mixviewtemplates { get; set; } - - public virtual DbSet Onepaytransactionrequests { get; set; } - - public virtual DbSet Onepaytransactionresponses { get; set; } - - public virtual DbSet Orderdetails { get; set; } - - public virtual DbSet Orderitems { get; set; } - - public virtual DbSet Productdetails { get; set; } - - public virtual DbSet QrtzBlobTriggers { get; set; } - - public virtual DbSet QrtzCalendars { get; set; } - - public virtual DbSet QrtzCronTriggers { get; set; } - - public virtual DbSet QrtzFiredTriggers { get; set; } - - public virtual DbSet QrtzJobDetails { get; set; } - - public virtual DbSet QrtzLocks { get; set; } - - public virtual DbSet QrtzPausedTriggerGrps { get; set; } - - public virtual DbSet QrtzSchedulerStates { get; set; } - - public virtual DbSet QrtzSimpleTriggers { get; set; } - - public virtual DbSet QrtzSimpropTriggers { get; set; } - - public virtual DbSet QrtzTriggers { get; set; } - - public virtual DbSet Refreshtokens { get; set; } - - public virtual DbSet Shoppingcarts { get; set; } - - public virtual DbSet Syscategories { get; set; } - - public virtual DbSet Sysmedia { get; set; } - - public virtual DbSet Sysmenuitems { get; set; } - - public virtual DbSet Sysnavigations { get; set; } - - public virtual DbSet Syspermissions { get; set; } - - public virtual DbSet Syspermissionendpoints { get; set; } - - public virtual DbSet Systags { get; set; } - - public virtual DbSet Sysuserdata { get; set; } - - public virtual DbSet Sysuserpermissions { get; set; } - - protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) -#warning To protect potentially sensitive information in your connection string, you should move it out of source code. You can avoid scaffolding the connection string by using the Name= syntax to read it from configuration - see https://go.microsoft.com/fwlink/?linkid=2131148. For more guidance on storing connection strings, see http://go.microsoft.com/fwlink/?LinkId=723263. - => optionsBuilder.UseMySql("server=localhost;port=3306;database=tanconst_nesto;user=root;password=1234qwe@", Microsoft.EntityFrameworkCore.ServerVersion.Parse("8.0.31-mysql")); - - protected override void OnModelCreating(ModelBuilder modelBuilder) - { - modelBuilder - .UseCollation("utf8mb4_0900_ai_ci") - .HasCharSet("utf8mb4"); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("aspnetroleclaims"); - - entity.HasIndex(e => e.MixRoleId, "IX_AspNetRoleClaims_MixRoleId"); - - entity.HasIndex(e => e.RoleId, "IX_AspNetRoleClaims_RoleId"); - - entity.Property(e => e.Id).ValueGeneratedNever(); - entity.Property(e => e.ClaimType) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ClaimValue) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.MixRoleId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.RoleId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - - entity.HasOne(d => d.MixRole).WithMany(p => p.Aspnetroleclaims) - .HasForeignKey(d => d.MixRoleId) - .HasConstraintName("FK_AspNetRoleClaims_MixRoles_MixRoleId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("aspnetuserclaims"); - - entity.HasIndex(e => e.MixUserId, "IX_AspNetUserClaims_MixUserId"); - - entity.HasIndex(e => e.MixUserId1, "IX_AspNetUserClaims_MixUserId1"); - - entity.HasIndex(e => e.UserId, "IX_AspNetUserClaims_UserId"); - - entity.Property(e => e.ClaimType) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ClaimValue) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.MixUserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixUserId1) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.UserId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - - entity.HasOne(d => d.MixUser).WithMany(p => p.AspnetuserclaimMixUsers) - .HasForeignKey(d => d.MixUserId) - .HasConstraintName("FK_AspNetUserClaims_MixUsers_MixUserId"); - - entity.HasOne(d => d.MixUserId1Navigation).WithMany(p => p.AspnetuserclaimMixUserId1Navigations) - .HasForeignKey(d => d.MixUserId1) - .HasConstraintName("FK_AspNetUserClaims_MixUsers_MixUserId1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.LoginProvider, e.ProviderKey }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("aspnetuserlogins"); - - entity.HasIndex(e => e.MixUserId, "IX_AspNetUserLogins_MixUserId"); - - entity.HasIndex(e => e.MixUserId1, "IX_AspNetUserLogins_MixUserId1"); - - entity.HasIndex(e => e.UserId, "IX_AspNetUserLogins_UserId"); - - entity.Property(e => e.LoginProvider) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ProviderKey) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.MixUserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixUserId1) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ProviderDisplayName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.UserId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - - entity.HasOne(d => d.MixUser).WithMany(p => p.AspnetuserloginMixUsers) - .HasForeignKey(d => d.MixUserId) - .HasConstraintName("FK_AspNetUserLogins_MixUsers_MixUserId"); - - entity.HasOne(d => d.MixUserId1Navigation).WithMany(p => p.AspnetuserloginMixUserId1Navigations) - .HasForeignKey(d => d.MixUserId1) - .HasConstraintName("FK_AspNetUserLogins_MixUsers_MixUserId1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.UserId, e.RoleId, e.MixTenantId }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("aspnetuserroles"); - - entity.HasIndex(e => e.MixRoleId, "IX_AspNetUserRoles_MixRoleId"); - - entity.HasIndex(e => e.MixUserId, "IX_AspNetUserRoles_MixUserId"); - - entity.HasIndex(e => e.MixUserId1, "IX_AspNetUserRoles_MixUserId1"); - - entity.HasIndex(e => e.RoleId, "IX_AspNetUserRoles_RoleId"); - - entity.Property(e => e.UserId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.RoleId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixRoleId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixUserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixUserId1) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - - entity.HasOne(d => d.MixRole).WithMany(p => p.Aspnetuserroles) - .HasForeignKey(d => d.MixRoleId) - .HasConstraintName("FK_AspNetUserRoles_MixRoles_MixRoleId"); - - entity.HasOne(d => d.MixUser).WithMany(p => p.AspnetuserroleMixUsers) - .HasForeignKey(d => d.MixUserId) - .HasConstraintName("FK_AspNetUserRoles_MixUsers_MixUserId"); - - entity.HasOne(d => d.MixUserId1Navigation).WithMany(p => p.AspnetuserroleMixUserId1Navigations) - .HasForeignKey(d => d.MixUserId1) - .HasConstraintName("FK_AspNetUserRoles_MixUsers_MixUserId1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.UserId, e.LoginProvider, e.Name }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("aspnetusertokens"); - - entity.HasIndex(e => e.MixUserId, "IX_AspNetUserTokens_MixUserId"); - - entity.Property(e => e.UserId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.LoginProvider) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Name) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.MixUserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.Value) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixUser).WithMany(p => p.Aspnetusertokens) - .HasForeignKey(d => d.MixUserId) - .HasConstraintName("FK_AspNetUserTokens_MixUsers_MixUserId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("clients"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("contactaddress"); - - entity.Property(e => e.City).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.District).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Note).HasMaxLength(250); - entity.Property(e => e.Province).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Street).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.MigrationId).HasName("PRIMARY"); - - entity.ToTable("__efmigrationshistory"); - - entity.Property(e => e.MigrationId).HasMaxLength(150); - entity.Property(e => e.ProductVersion) - .IsRequired() - .HasMaxLength(32); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("metadata"); - - entity.Property(e => e.Content).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.SeoContent).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.Type).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("metadatacontent"); - - entity.Property(e => e.ContentType).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.Image).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("metadatacontentassociation"); - - entity.Property(e => e.ContentType).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.Image).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixapplication"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixApplication_MixDataContentId"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixApplication_MixTenantId"); - - entity.Property(e => e.BaseApiUrl) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.BaseHref) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.BaseRoute) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Domain) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixDatabaseName) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixapplications) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixApplication_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixapplications) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixApplication_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixcache"); - - entity.HasIndex(e => e.ExpiredDateTime, "Index_ExpiresAtTime"); - - entity.Property(e => e.CreatedBy).HasMaxLength(50); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.ExpiredDateTime).HasColumnType("datetime"); - entity.Property(e => e.Keyword) - .IsRequired() - .HasMaxLength(400); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(50); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50); - entity.Property(e => e.Value) - .IsRequired() - .HasColumnType("text"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixconfiguration"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixConfiguration_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixconfigurations) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixConfiguration_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixconfigurationcontent"); - - entity.HasIndex(e => e.MixConfigurationId, "IX_MixConfigurationContent_MixConfigurationId"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixConfigurationContent_MixCultureId"); - - entity.Property(e => e.Category) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Content) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DataType) - .IsRequired() - .HasMaxLength(50) - .HasDefaultValueSql("''") - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DefaultContent) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixConfiguration).WithMany(p => p.Mixconfigurationcontents) - .HasForeignKey(d => d.MixConfigurationId) - .HasConstraintName("FK_MixConfigurationContent_MixConfiguration_MixConfigurationId"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixconfigurationcontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixConfigurationContent_MixCulture_MixCultureId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixcontributor"); - - entity.Property(e => e.ContentType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.GuidContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.UserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixcorecmshelper"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixculture"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixCulture_MixTenantId"); - - entity.Property(e => e.Alias) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(4000) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.Lcid) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Specificulture) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixcultures) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixCulture_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabase"); - - entity.HasIndex(e => e.MixDatabaseContextDatabaseAssociationId, "IX_MixDatabase_MixDatabaseContextDatabaseAssociationId"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixDatabase_MixTenantId"); - - entity.Property(e => e.CreatePermissions) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DeletePermissions) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ReadPermissions) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Type) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.UpdatePermissions) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDatabaseContextDatabaseAssociation).WithMany(p => p.Mixdatabases) - .HasForeignKey(d => d.MixDatabaseContextDatabaseAssociationId) - .HasConstraintName("FK_MixDatabase_MixDatabaseContextDatabaseAssociation_MixDatabas~"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixdatabases) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixDatabase_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabaseassociation"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ChildDatabaseName) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentDatabaseName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabasecolumn"); - - entity.HasIndex(e => e.MixDatabaseId, "IX_MixDatabaseColumn_MixDatabaseId"); - - entity.Property(e => e.Configurations) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DataType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DefaultValue) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDatabaseName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDatabase).WithMany(p => p.Mixdatabasecolumns) - .HasForeignKey(d => d.MixDatabaseId) - .HasConstraintName("FK_MixDatabaseColumn_MixDatabase_MixDatabaseId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabasecontext"); - - entity.HasIndex(e => e.MixDatabaseContextDatabaseAssociationId, "IX_MixDatabaseContext_MixDatabaseContextDatabaseAssociationId"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixDatabaseContext_MixTenantId"); - - entity.Property(e => e.ConnectionString) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DatabaseProvider) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDatabaseContextDatabaseAssociation).WithMany(p => p.Mixdatabasecontexts) - .HasForeignKey(d => d.MixDatabaseContextDatabaseAssociationId) - .HasConstraintName("FK_MixDatabaseContext_MixDatabaseContextDatabaseAssociation_Mix~"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixdatabasecontexts) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixDatabaseContext_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabasecontextdatabaseassociation"); - - entity.Property(e => e.CreatedDateTime).HasMaxLength(6); - entity.Property(e => e.LastModified).HasMaxLength(6); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatabaserelationship"); - - entity.HasIndex(e => e.ChildId, "IX_MixDatabaseRelationship_ChildId"); - - entity.HasIndex(e => e.ParentId, "IX_MixDatabaseRelationship_ParentId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DestinateDatabaseName) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.SourceDatabaseName) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Type) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatacontent"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixDataContent_MixCultureId"); - - entity.HasIndex(e => e.MixDataId, "IX_MixDataContent_MixDataId"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.Content) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Excerpt) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Image) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.PublishedDateTime).HasColumnType("datetime"); - entity.Property(e => e.SeoDescription) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoKeywords) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixdatacontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixDataContent_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixData).WithMany(p => p.Mixdatacontents) - .HasForeignKey(d => d.MixDataId) - .HasConstraintName("FK_MixDataContent_MixData_MixDataId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatacontentassociation"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixDataContentAssociation_MixCultureId"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.GuidParentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ParentType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixdatacontentassociations) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixDataContentAssociation_MixCulture_MixCultureId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdatacontentvalue"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixDataContentValue_MixCultureId"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixDataContentValue_MixDataContentId"); - - entity.HasIndex(e => e.MixDatabaseColumnId, "IX_MixDataContentValue_MixDatabaseColumnId"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DataType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DateTimeValue).HasColumnType("datetime"); - entity.Property(e => e.EncryptKey) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.EncryptType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.EncryptValue) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.MixDatabaseColumnName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.MixDatabaseName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.StringValue) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixdatacontentvalues) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixDataContentValue_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixdatacontentvalues) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixDataContentValue_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixDatabaseColumn).WithMany(p => p.Mixdatacontentvalues) - .HasForeignKey(d => d.MixDatabaseColumnId) - .HasConstraintName("FK_MixDataContentValue_MixDatabaseColumn_MixDatabaseColumnId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdata"); - - entity.HasIndex(e => e.MixDatabaseId, "IX_MixData_MixDatabaseId"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDatabaseName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDatabase).WithMany(p => p.Mixdata) - .HasForeignKey(d => d.MixDatabaseId) - .HasConstraintName("FK_MixData_MixDatabase_MixDatabaseId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdiscussion"); - - entity.Property(e => e.Content) - .IsRequired() - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ContentType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.GuidContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.UserId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixdomain"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixDomain_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Host) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixdomains) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixDomain_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixlanguage"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixLanguage_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixlanguages) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixLanguage_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixlanguagecontent"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixLanguageContent_MixCultureId"); - - entity.HasIndex(e => e.MixLanguageId, "IX_MixLanguageContent_MixLanguageId"); - - entity.Property(e => e.Category) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Content) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DataType) - .IsRequired() - .HasMaxLength(50) - .HasDefaultValueSql("''") - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DefaultContent) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixlanguagecontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixLanguageContent_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixLanguage).WithMany(p => p.Mixlanguagecontents) - .HasForeignKey(d => d.MixLanguageId) - .HasConstraintName("FK_MixLanguageContent_MixLanguage_MixLanguageId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixmedia"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixMedia_MixTenantId"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Extension) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileFolder) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileName) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileProperties) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileType) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Tags) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.TargetUrl) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixmedia) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixMedia_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixmodule"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixModule_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Type) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixmodules) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixModule_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixmodulecontent"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixModuleContent_MixCultureId"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixModuleContent_MixDataContentId"); - - entity.HasIndex(e => e.MixModuleId, "IX_MixModuleContent_MixModuleId"); - - entity.Property(e => e.ClassName) - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Content) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Excerpt) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Image) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PublishedDateTime).HasColumnType("datetime"); - entity.Property(e => e.SeoDescription) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoKeywords) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .HasMaxLength(250) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Type) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixmodulecontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixModuleContent_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixmodulecontents) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixModuleContent_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixModule).WithMany(p => p.Mixmodulecontents) - .HasForeignKey(d => d.MixModuleId) - .HasConstraintName("FK_MixModuleContent_MixModule_MixModuleId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixmoduledata"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixModuleData_MixCultureId"); - - entity.HasIndex(e => e.MixModuleContentId, "IX_MixModuleData_MixModuleContentId"); - - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Excerpt) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Image) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PublishedDateTime).HasColumnType("datetime"); - entity.Property(e => e.SeoDescription) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoKeywords) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SimpleDataColumns) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Value) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixmoduledata) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixModuleData_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixModuleContent).WithMany(p => p.Mixmoduledata) - .HasForeignKey(d => d.MixModuleContentId) - .HasConstraintName("FK_MixModuleData_MixModuleContent_MixModuleContentId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixmodulepostassociation"); - - entity.HasIndex(e => e.MixModuleContentId, "IX_MixModulePostAssociation_MixModuleContentId"); - - entity.Property(e => e.CreatedDateTime).HasMaxLength(6); - entity.Property(e => e.LastModified).HasMaxLength(6); - - entity.HasOne(d => d.MixModuleContent).WithMany(p => p.Mixmodulepostassociations) - .HasForeignKey(d => d.MixModuleContentId) - .HasConstraintName("FK_MixModulePostAssociation_MixModuleContent_MixModuleContentId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpage"); - - entity.HasIndex(e => e.MixPostContentId, "IX_MixPage_MixPostContentId"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixPage_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixPostContent).WithMany(p => p.Mixpages) - .HasForeignKey(d => d.MixPostContentId) - .HasConstraintName("FK_MixPage_MixPostContent_MixPostContentId"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixpages) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixPage_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpagecontent"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixPageContent_MixCultureId"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixPageContent_MixDataContentId"); - - entity.HasIndex(e => e.MixPageId, "IX_MixPageContent_MixPageId"); - - entity.Property(e => e.ClassName) - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Content) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Excerpt) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Image) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PublishedDateTime).HasColumnType("datetime"); - entity.Property(e => e.SeoDescription) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoKeywords) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Type) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixpagecontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixPageContent_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixpagecontents) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixPageContent_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixPage).WithMany(p => p.Mixpagecontents) - .HasForeignKey(d => d.MixPageId) - .HasConstraintName("FK_MixPageContent_MixPage_MixPageId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpagemoduleassociation"); - - entity.HasIndex(e => e.MixPageContentId, "IX_MixPageModuleAssociation_MixPageContentId"); - - entity.Property(e => e.CreatedDateTime).HasMaxLength(6); - entity.Property(e => e.LastModified).HasMaxLength(6); - - entity.HasOne(d => d.MixPageContent).WithMany(p => p.Mixpagemoduleassociations) - .HasForeignKey(d => d.MixPageContentId) - .HasConstraintName("FK_MixPageModuleAssociation_MixPageContent_MixPageContentId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpagepostassociation"); - - entity.HasIndex(e => e.MixPageContentId, "IX_MixPagePostAssociation_MixPageContentId"); - - entity.Property(e => e.CreatedDateTime).HasMaxLength(6); - entity.Property(e => e.LastModified).HasMaxLength(6); - - entity.HasOne(d => d.MixPageContent).WithMany(p => p.Mixpagepostassociations) - .HasForeignKey(d => d.MixPageContentId) - .HasConstraintName("FK_MixPagePostAssociation_MixPageContent_MixPageContentId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpost"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixPost_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixposts) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixPost_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpostcontent"); - - entity.HasIndex(e => e.MixCultureId, "IX_MixPostContent_MixCultureId"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixPostContent_MixDataContentId"); - - entity.HasIndex(e => e.MixPostContentId, "IX_MixPostContent_MixPostContentId"); - - entity.HasIndex(e => e.MixPostId, "IX_MixPostContent_MixPostId"); - - entity.Property(e => e.ClassName) - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Content) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Excerpt) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Icon) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Image) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PublishedDateTime).HasColumnType("datetime"); - entity.Property(e => e.SeoDescription) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoKeywords) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SeoName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Source) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Specificulture) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixCulture).WithMany(p => p.Mixpostcontents) - .HasForeignKey(d => d.MixCultureId) - .HasConstraintName("FK_MixPostContent_MixCulture_MixCultureId"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixpostcontents) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixPostContent_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixPostContent).WithMany(p => p.InverseMixPostContent) - .HasForeignKey(d => d.MixPostContentId) - .HasConstraintName("FK_MixPostContent_MixPostContent_MixPostContentId"); - - entity.HasOne(d => d.MixPost).WithMany(p => p.Mixpostcontents) - .HasForeignKey(d => d.MixPostId) - .HasConstraintName("FK_MixPostContent_MixPost_MixPostId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixpostpostassociation"); - - entity.Property(e => e.CreatedDateTime).HasMaxLength(6); - entity.Property(e => e.LastModified).HasMaxLength(6); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixroles"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ConcurrencyStamp) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Name) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.NormalizedName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixtenant"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PrimaryDomain) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SystemName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixtheme"); - - entity.HasIndex(e => e.MixDataContentId, "IX_MixTheme_MixDataContentId"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixTheme_MixTenantId"); - - entity.Property(e => e.AssetFolder) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ImageUrl) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixDataContentId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.PreviewUrl) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.TemplateFolder) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixDataContent).WithMany(p => p.Mixthemes) - .HasForeignKey(d => d.MixDataContentId) - .HasConstraintName("FK_MixTheme_MixDataContent_MixDataContentId"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixthemes) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixTheme_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixurlalias"); - - entity.HasIndex(e => e.MixTenantId, "IX_MixUrlAlias_MixTenantId"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description) - .HasMaxLength(4000) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.DisplayName) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.SourceContentGuidId) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTenant).WithMany(p => p.Mixurlaliases) - .HasForeignKey(d => d.MixTenantId) - .HasConstraintName("FK_MixUrlAlias_MixTenant_MixTenantId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixusers"); - - entity.HasIndex(e => e.NormalizedEmail, "EmailIndex"); - - entity.HasIndex(e => e.NormalizedUserName, "UserNameIndex").IsUnique(); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ConcurrencyStamp) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Email) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.LockoutEnd).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.NormalizedEmail) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.NormalizedUserName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.PasswordHash) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.PhoneNumber) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.RegisterType) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.SecurityStamp) - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.UserName) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.MixUserId, e.TenantId }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("mixusertenants"); - - entity.HasIndex(e => e.MixUserId, "IX_MixUserTenants_MixUserId"); - - entity.HasIndex(e => e.TenantId, "IX_MixUserTenants_TenantId"); - - entity.Property(e => e.MixUserId) - .HasDefaultValueSql("uuid_to_bin(uuid())") - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("mixviewtemplate"); - - entity.HasIndex(e => e.MixThemeId, "IX_MixViewTemplate_MixThemeId"); - - entity.Property(e => e.Content) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Extension) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileFolder) - .IsRequired() - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FileName) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.FolderType) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MixThemeName) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Scripts) - .IsRequired() - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Styles) - .IsRequired() - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - - entity.HasOne(d => d.MixTheme).WithMany(p => p.Mixviewtemplates) - .HasForeignKey(d => d.MixThemeId) - .HasConstraintName("FK_MixViewTemplate_MixTheme_MixThemeId"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("onepaytransactionrequest"); - - entity.Property(e => e.AgainLink).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.OnepayStatus) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.VpcAccessCode) - .HasMaxLength(250) - .HasColumnName("vpc_AccessCode"); - entity.Property(e => e.VpcAmount) - .HasMaxLength(250) - .HasColumnName("vpc_Amount"); - entity.Property(e => e.VpcCommand) - .HasMaxLength(250) - .HasColumnName("vpc_Command"); - entity.Property(e => e.VpcCurrency) - .HasMaxLength(250) - .HasColumnName("vpc_Currency"); - entity.Property(e => e.VpcCustomerEmail) - .HasMaxLength(250) - .HasColumnName("vpc_Customer_Email"); - entity.Property(e => e.VpcCustomerId) - .HasMaxLength(250) - .HasColumnName("vpc_Customer_Id"); - entity.Property(e => e.VpcCustomerPhone) - .HasMaxLength(250) - .HasColumnName("vpc_Customer_Phone"); - entity.Property(e => e.VpcLocale) - .HasMaxLength(250) - .HasColumnName("vpc_Locale"); - entity.Property(e => e.VpcMerchTxnRef) - .HasMaxLength(250) - .HasColumnName("vpc_MerchTxnRef"); - entity.Property(e => e.VpcMerchant) - .HasMaxLength(250) - .HasColumnName("vpc_Merchant"); - entity.Property(e => e.VpcOrderInfo) - .HasMaxLength(250) - .HasColumnName("vpc_OrderInfo"); - entity.Property(e => e.VpcReturnUrl) - .HasMaxLength(4000) - .HasColumnName("vpc_ReturnURL"); - entity.Property(e => e.VpcSecureHash) - .HasMaxLength(250) - .HasColumnName("vpc_SecureHash"); - entity.Property(e => e.VpcTicketNo) - .HasMaxLength(250) - .HasColumnName("vpc_TicketNo"); - entity.Property(e => e.VpcVersion).HasColumnName("vpc_Version"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("onepaytransactionresponse"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.OnepayStatus) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Status) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_general_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.VpcAdditionData) - .HasMaxLength(250) - .HasColumnName("vpc_AdditionData"); - entity.Property(e => e.VpcAmount) - .HasMaxLength(250) - .HasColumnName("vpc_Amount"); - entity.Property(e => e.VpcCommand) - .HasMaxLength(250) - .HasColumnName("vpc_Command"); - entity.Property(e => e.VpcCurrencyCode) - .HasMaxLength(250) - .HasColumnName("vpc_CurrencyCode"); - entity.Property(e => e.VpcLocale) - .HasMaxLength(250) - .HasColumnName("vpc_Locale"); - entity.Property(e => e.VpcMerchTxnRef) - .HasMaxLength(250) - .HasColumnName("vpc_MerchTxnRef"); - entity.Property(e => e.VpcMerchant) - .HasMaxLength(250) - .HasColumnName("vpc_Merchant"); - entity.Property(e => e.VpcMessage) - .HasMaxLength(250) - .HasColumnName("vpc_Message"); - entity.Property(e => e.VpcOrderInfo) - .HasMaxLength(250) - .HasColumnName("vpc_OrderInfo"); - entity.Property(e => e.VpcSecureHash) - .HasMaxLength(250) - .HasColumnName("vpc_SecureHash"); - entity.Property(e => e.VpcTransactionNo) - .HasMaxLength(250) - .HasColumnName("vpc_TransactionNo"); - entity.Property(e => e.VpcTxnResponseCode) - .HasMaxLength(250) - .HasColumnName("vpc_TxnResponseCode"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("orderdetail"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Currency).HasMaxLength(250); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.OrderStatus).HasMaxLength(250); - entity.Property(e => e.PaymentGateway).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.UserId).HasMaxLength(255); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("orderitem"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Currency).HasMaxLength(250); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.Image).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ReferenceUrl).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("productdetails"); - - entity.Property(e => e.Brands).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.DesignBy).HasMaxLength(250); - entity.Property(e => e.Document).HasMaxLength(250); - entity.Property(e => e.InformationImage).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.MaintenanceDocument).HasMaxLength(250); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentType).HasMaxLength(20); - entity.Property(e => e.Size).HasMaxLength(250); - entity.Property(e => e.SizeImage).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_blob_triggers"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }, "SCHED_NAME"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerName) - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.BlobData) - .HasColumnType("blob") - .HasColumnName("BLOB_DATA"); - - entity.HasOne(d => d.QrtzTrigger).WithOne(p => p.QrtzBlobTrigger) - .HasForeignKey(d => new { d.SchedName, d.TriggerName, d.TriggerGroup }) - .OnDelete(DeleteBehavior.ClientSetNull) - .HasConstraintName("qrtz_blob_triggers_ibfk_1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.CalendarName }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("qrtz_calendars"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.CalendarName) - .HasMaxLength(200) - .HasColumnName("CALENDAR_NAME"); - entity.Property(e => e.Calendar) - .IsRequired() - .HasColumnType("blob") - .HasColumnName("CALENDAR"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_cron_triggers"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerName) - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.CronExpression) - .IsRequired() - .HasMaxLength(120) - .HasColumnName("CRON_EXPRESSION"); - entity.Property(e => e.TimeZoneId) - .HasMaxLength(80) - .HasColumnName("TIME_ZONE_ID"); - - entity.HasOne(d => d.QrtzTrigger).WithOne(p => p.QrtzCronTrigger) - .HasForeignKey(d => new { d.SchedName, d.TriggerName, d.TriggerGroup }) - .OnDelete(DeleteBehavior.ClientSetNull) - .HasConstraintName("qrtz_cron_triggers_ibfk_1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.EntryId }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("qrtz_fired_triggers"); - - entity.HasIndex(e => new { e.SchedName, e.InstanceName, e.RequestsRecovery }, "IDX_QRTZ_FT_INST_JOB_REQ_RCVRY"); - - entity.HasIndex(e => new { e.SchedName, e.JobGroup }, "IDX_QRTZ_FT_JG"); - - entity.HasIndex(e => new { e.SchedName, e.JobName, e.JobGroup }, "IDX_QRTZ_FT_J_G"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerGroup }, "IDX_QRTZ_FT_TG"); - - entity.HasIndex(e => new { e.SchedName, e.InstanceName }, "IDX_QRTZ_FT_TRIG_INST_NAME"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }, "IDX_QRTZ_FT_T_G"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.EntryId) - .HasMaxLength(140) - .HasColumnName("ENTRY_ID"); - entity.Property(e => e.FiredTime).HasColumnName("FIRED_TIME"); - entity.Property(e => e.InstanceName) - .IsRequired() - .HasMaxLength(200) - .HasColumnName("INSTANCE_NAME"); - entity.Property(e => e.IsNonconcurrent).HasColumnName("IS_NONCONCURRENT"); - entity.Property(e => e.JobGroup) - .HasMaxLength(200) - .HasColumnName("JOB_GROUP"); - entity.Property(e => e.JobName) - .HasMaxLength(200) - .HasColumnName("JOB_NAME"); - entity.Property(e => e.Priority).HasColumnName("PRIORITY"); - entity.Property(e => e.RequestsRecovery).HasColumnName("REQUESTS_RECOVERY"); - entity.Property(e => e.SchedTime).HasColumnName("SCHED_TIME"); - entity.Property(e => e.State) - .IsRequired() - .HasMaxLength(16) - .HasColumnName("STATE"); - entity.Property(e => e.TriggerGroup) - .IsRequired() - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.TriggerName) - .IsRequired() - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.JobName, e.JobGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_job_details"); - - entity.HasIndex(e => new { e.SchedName, e.JobGroup }, "IDX_QRTZ_J_GRP"); - - entity.HasIndex(e => new { e.SchedName, e.RequestsRecovery }, "IDX_QRTZ_J_REQ_RECOVERY"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.JobName) - .HasMaxLength(200) - .HasColumnName("JOB_NAME"); - entity.Property(e => e.JobGroup) - .HasMaxLength(200) - .HasColumnName("JOB_GROUP"); - entity.Property(e => e.Description) - .HasMaxLength(250) - .HasColumnName("DESCRIPTION"); - entity.Property(e => e.IsDurable).HasColumnName("IS_DURABLE"); - entity.Property(e => e.IsNonconcurrent).HasColumnName("IS_NONCONCURRENT"); - entity.Property(e => e.IsUpdateData).HasColumnName("IS_UPDATE_DATA"); - entity.Property(e => e.JobClassName) - .IsRequired() - .HasMaxLength(250) - .HasColumnName("JOB_CLASS_NAME"); - entity.Property(e => e.JobData) - .HasColumnType("blob") - .HasColumnName("JOB_DATA"); - entity.Property(e => e.RequestsRecovery).HasColumnName("REQUESTS_RECOVERY"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.LockName }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("qrtz_locks"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.LockName) - .HasMaxLength(40) - .HasColumnName("LOCK_NAME"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("qrtz_paused_trigger_grps"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.InstanceName }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0 }); - - entity.ToTable("qrtz_scheduler_state"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.InstanceName) - .HasMaxLength(200) - .HasColumnName("INSTANCE_NAME"); - entity.Property(e => e.CheckinInterval).HasColumnName("CHECKIN_INTERVAL"); - entity.Property(e => e.LastCheckinTime).HasColumnName("LAST_CHECKIN_TIME"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_simple_triggers"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerName) - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.RepeatCount).HasColumnName("REPEAT_COUNT"); - entity.Property(e => e.RepeatInterval).HasColumnName("REPEAT_INTERVAL"); - entity.Property(e => e.TimesTriggered).HasColumnName("TIMES_TRIGGERED"); - - entity.HasOne(d => d.QrtzTrigger).WithOne(p => p.QrtzSimpleTrigger) - .HasForeignKey(d => new { d.SchedName, d.TriggerName, d.TriggerGroup }) - .OnDelete(DeleteBehavior.ClientSetNull) - .HasConstraintName("qrtz_simple_triggers_ibfk_1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_simprop_triggers"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerName) - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.BoolProp1).HasColumnName("BOOL_PROP_1"); - entity.Property(e => e.BoolProp2).HasColumnName("BOOL_PROP_2"); - entity.Property(e => e.DecProp1) - .HasPrecision(13, 4) - .HasColumnName("DEC_PROP_1"); - entity.Property(e => e.DecProp2) - .HasPrecision(13, 4) - .HasColumnName("DEC_PROP_2"); - entity.Property(e => e.IntProp1).HasColumnName("INT_PROP_1"); - entity.Property(e => e.IntProp2).HasColumnName("INT_PROP_2"); - entity.Property(e => e.LongProp1).HasColumnName("LONG_PROP_1"); - entity.Property(e => e.LongProp2).HasColumnName("LONG_PROP_2"); - entity.Property(e => e.StrProp1) - .HasMaxLength(512) - .HasColumnName("STR_PROP_1"); - entity.Property(e => e.StrProp2) - .HasMaxLength(512) - .HasColumnName("STR_PROP_2"); - entity.Property(e => e.StrProp3) - .HasMaxLength(512) - .HasColumnName("STR_PROP_3"); - entity.Property(e => e.TimeZoneId) - .HasMaxLength(80) - .HasColumnName("TIME_ZONE_ID"); - - entity.HasOne(d => d.QrtzTrigger).WithOne(p => p.QrtzSimpropTrigger) - .HasForeignKey(d => new { d.SchedName, d.TriggerName, d.TriggerGroup }) - .OnDelete(DeleteBehavior.ClientSetNull) - .HasConstraintName("qrtz_simprop_triggers_ibfk_1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => new { e.SchedName, e.TriggerName, e.TriggerGroup }) - .HasName("PRIMARY") - .HasAnnotation("MySql:IndexPrefixLength", new[] { 0, 0, 0 }); - - entity.ToTable("qrtz_triggers"); - - entity.HasIndex(e => new { e.SchedName, e.CalendarName }, "IDX_QRTZ_T_C"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerGroup }, "IDX_QRTZ_T_G"); - - entity.HasIndex(e => new { e.SchedName, e.JobName, e.JobGroup }, "IDX_QRTZ_T_J"); - - entity.HasIndex(e => new { e.SchedName, e.JobGroup }, "IDX_QRTZ_T_JG"); - - entity.HasIndex(e => new { e.SchedName, e.NextFireTime }, "IDX_QRTZ_T_NEXT_FIRE_TIME"); - - entity.HasIndex(e => new { e.SchedName, e.MisfireInstr, e.NextFireTime }, "IDX_QRTZ_T_NFT_MISFIRE"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerState, e.NextFireTime }, "IDX_QRTZ_T_NFT_ST"); - - entity.HasIndex(e => new { e.SchedName, e.MisfireInstr, e.NextFireTime, e.TriggerState }, "IDX_QRTZ_T_NFT_ST_MISFIRE"); - - entity.HasIndex(e => new { e.SchedName, e.MisfireInstr, e.NextFireTime, e.TriggerGroup, e.TriggerState }, "IDX_QRTZ_T_NFT_ST_MISFIRE_GRP"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerGroup, e.TriggerState }, "IDX_QRTZ_T_N_G_STATE"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerName, e.TriggerGroup, e.TriggerState }, "IDX_QRTZ_T_N_STATE"); - - entity.HasIndex(e => new { e.SchedName, e.TriggerState }, "IDX_QRTZ_T_STATE"); - - entity.Property(e => e.SchedName) - .HasMaxLength(120) - .HasColumnName("SCHED_NAME"); - entity.Property(e => e.TriggerName) - .HasMaxLength(200) - .HasColumnName("TRIGGER_NAME"); - entity.Property(e => e.TriggerGroup) - .HasMaxLength(200) - .HasColumnName("TRIGGER_GROUP"); - entity.Property(e => e.CalendarName) - .HasMaxLength(200) - .HasColumnName("CALENDAR_NAME"); - entity.Property(e => e.Description) - .HasMaxLength(250) - .HasColumnName("DESCRIPTION"); - entity.Property(e => e.EndTime).HasColumnName("END_TIME"); - entity.Property(e => e.JobData) - .HasColumnType("blob") - .HasColumnName("JOB_DATA"); - entity.Property(e => e.JobGroup) - .IsRequired() - .HasMaxLength(200) - .HasColumnName("JOB_GROUP"); - entity.Property(e => e.JobName) - .IsRequired() - .HasMaxLength(200) - .HasColumnName("JOB_NAME"); - entity.Property(e => e.MisfireInstr).HasColumnName("MISFIRE_INSTR"); - entity.Property(e => e.NextFireTime).HasColumnName("NEXT_FIRE_TIME"); - entity.Property(e => e.PrevFireTime).HasColumnName("PREV_FIRE_TIME"); - entity.Property(e => e.Priority).HasColumnName("PRIORITY"); - entity.Property(e => e.StartTime).HasColumnName("START_TIME"); - entity.Property(e => e.TriggerState) - .IsRequired() - .HasMaxLength(16) - .HasColumnName("TRIGGER_STATE"); - entity.Property(e => e.TriggerType) - .IsRequired() - .HasMaxLength(8) - .HasColumnName("TRIGGER_TYPE"); - - entity.HasOne(d => d.QrtzJobDetail).WithMany(p => p.QrtzTriggers) - .HasForeignKey(d => new { d.SchedName, d.JobName, d.JobGroup }) - .OnDelete(DeleteBehavior.ClientSetNull) - .HasConstraintName("qrtz_triggers_ibfk_1"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("refreshtokens"); - - entity.Property(e => e.Id) - .UseCollation("ascii_general_ci") - .HasCharSet("ascii"); - entity.Property(e => e.ClientId) - .IsRequired() - .HasMaxLength(50) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.Email) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - entity.Property(e => e.ExpiresUtc).HasColumnType("datetime"); - entity.Property(e => e.IssuedUtc).HasColumnType("datetime"); - entity.Property(e => e.Username) - .HasMaxLength(250) - .UseCollation("utf8mb3_unicode_ci") - .HasCharSet("utf8mb3"); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity - .ToTable("shoppingcart") - .HasCharSet("utf8mb3") - .UseCollation("utf8mb3_unicode_ci"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.UserId).HasMaxLength(255); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity - .ToTable("syscategory") - .HasCharSet("utf8mb3") - .UseCollation("utf8mb3_unicode_ci"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity - .ToTable("sysmedia") - .HasCharSet("utf8mb3") - .UseCollation("utf8mb3_unicode_ci"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.File).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.Type).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("sysmenuitem"); - - entity.Property(e => e.Alt).HasMaxLength(250); - entity.Property(e => e.Classes).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.Hreflang).HasMaxLength(250); - entity.Property(e => e.Icon).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Target).HasMaxLength(250); - entity.Property(e => e.TargetId).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.Type).HasMaxLength(250); - entity.Property(e => e.Url).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("sysnavigation"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Name).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("syspermission"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Icon).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.Type).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("syspermissionendpoint"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.Method).HasMaxLength(250); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Path).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("systag"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Slug).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.Title).HasMaxLength(250); - entity.Property(e => e.Type).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("sysuserdata"); - - entity.Property(e => e.Avatar).HasMaxLength(250); - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.ParentId).HasMaxLength(255); - entity.Property(e => e.ParentType).HasMaxLength(20); - entity.Property(e => e.Status).HasMaxLength(250); - }); - - modelBuilder.Entity(entity => - { - entity.HasKey(e => e.Id).HasName("PRIMARY"); - - entity.ToTable("sysuserpermission"); - - entity.Property(e => e.CreatedBy).HasMaxLength(250); - entity.Property(e => e.CreatedDateTime).HasColumnType("datetime"); - entity.Property(e => e.Description).HasMaxLength(250); - entity.Property(e => e.LastModified).HasColumnType("datetime"); - entity.Property(e => e.ModifiedBy).HasMaxLength(250); - entity.Property(e => e.Status).HasMaxLength(250); - entity.Property(e => e.UserId).HasMaxLength(255); - }); - - OnModelCreatingPartial(modelBuilder); - } - - partial void OnModelCreatingPartial(ModelBuilder modelBuilder); -} diff --git a/src/applications/Mixcore/Program.cs b/src/applications/Mixcore/Program.cs index 48a49f47a..183ae0134 100644 --- a/src/applications/Mixcore/Program.cs +++ b/src/applications/Mixcore/Program.cs @@ -1,3 +1,5 @@ +using Mix.Shared.Helpers; + namespace Mixcore { public class Program @@ -10,10 +12,6 @@ public static void Main(string[] args) public static IHostBuilder CreateHostBuilder(string[] args) { var builder = MixCmsHelper.CreateHostBuilder(args); - builder.ConfigureAppConfiguration((hostingContext, config) => - { - config.AddJsonFile("MixContent/Shared/AppConfigs/kiotviet.json", true, true); - }); return builder; } } diff --git a/src/applications/Mixcore/Startup.cs b/src/applications/Mixcore/Startup.cs index 3447949aa..a3af3c818 100644 --- a/src/applications/Mixcore/Startup.cs +++ b/src/applications/Mixcore/Startup.cs @@ -40,7 +40,6 @@ public void ConfigureServices(IServiceCollection services) // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env) { - var globalConfigs = Configuration.Get(); if (!env.IsDevelopment()) { // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts. diff --git a/src/applications/Mixcore/mixcore.csproj b/src/applications/Mixcore/mixcore.csproj index a04b05a27..fb2c97aa4 100644 --- a/src/applications/Mixcore/mixcore.csproj +++ b/src/applications/Mixcore/mixcore.csproj @@ -85,35 +85,8 @@ PreserveNewest - - Always - - - - - - - - - - - - - - - - - - - - true - PreserveNewest - - - Never - diff --git a/src/shared/MixContent/default.zip b/src/applications/Mixcore/wwwroot/default-mixcontent/default.zip similarity index 100% rename from src/shared/MixContent/default.zip rename to src/applications/Mixcore/wwwroot/default-mixcontent/default.zip diff --git a/src/shared/MixContent/Shared/AppConfigs/authentication.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/authentication.json similarity index 57% rename from src/shared/MixContent/Shared/AppConfigs/authentication.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/authentication.json index 9da309182..6b4eaf915 100644 --- a/src/shared/MixContent/Shared/AppConfigs/authentication.json +++ b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/authentication.json @@ -8,10 +8,17 @@ "ValidateIssuerSigningKey": true, "TokenType": "Bearer", "Audience": "mix-core", - "SecretKey": "7fdc91305d594f29bb9d2860163f4d27", + "ClientId": "00000000-0000-0000-0000-000000000000", + "SecretKey": "61cf4651c35a4dfab0bb2cea9181db53", "Issuer": "mix-core", "Issuers": "mix-core", "Audiences": "mix-core", + "RequireUniqueEmail": false, + "RequireConfirmedEmail": false, + "ConfirmedEmailUrl": null, + "ConfirmedEmailUrlSuccess": null, + "ConfirmedEmailUrlFail": null, + "TokenLifespan": 3, "Facebook": { "AppId": "", "AppSecret": "" @@ -20,13 +27,19 @@ "AppId": "", "AppSecret": "" }, - "Twitter": { + "Microsoft": { "AppId": "", "AppSecret": "" }, - "Microsoft": { + "Twitter": { "AppId": "", "AppSecret": "" + }, + "AzureAd": { + "Instance": "https://login.microsoftonline.com/", + "ClientId": null, + "TenantId": null, + "Scopes": null } } } diff --git a/src/shared/MixContent/Shared/AppConfigs/azure.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/azure.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/azure.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/azure.json diff --git a/src/shared/MixContent/Shared/AppConfigs/configuration.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/configuration.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/configuration.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/configuration.json diff --git a/src/shared/MixContent/Shared/AppConfigs/database.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/database.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/database.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/database.json diff --git a/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/endpoint.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/endpoint.json new file mode 100644 index 000000000..bf9fbd355 --- /dev/null +++ b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/endpoint.json @@ -0,0 +1,15 @@ +{ + "Account": null, + "Common": null, + "Portal": null, + "Theme": null, + "Mixcore": null, + "Messenger": null, + "Scheduler": null, + "Grpc": null, + "Storage": "", + "Store": "https://store.mixcore.org", + "UniversalPortal": "https://universal.mixcore.net", + "UniversalPortalDev": "https://mix-portal-angular.vercel.app", + "LocalPortalDev": "http://localhost:4200" +} diff --git a/src/shared/MixContent/Shared/AppConfigs/epplus.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/epplus.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/epplus.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/epplus.json diff --git a/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/global.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/global.json new file mode 100644 index 000000000..3c702a8ba --- /dev/null +++ b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/global.json @@ -0,0 +1,19 @@ +{ + "GlobalSettings": { + "IsInit": true, + "IsLogStream": false, + "IsUpdateSystemDatabases": true, + "IsEncryptApi": false, + "EnableOcelot": false, + "PortalThemeSettings": null, + "IsMaintenance": false, + "IsHttps": false, + "MaxPageSize": 100, + "ResponseCache": 5, + "InitStatus": "Blank", + "DefaultCulture": "en-us", + "Domain": "", + "ApiEncryptKey": "NElUempOSmx4QVlXRFRmSys5Z0lpZz09LERBSENTUUlZWEVNYVRJRlErc256bE9Ibmo1Z0wwcm5PRm9iMDlXSEJSM0U9", + "LastUpdateConfiguration": null + } +} \ No newline at end of file diff --git a/src/shared/MixContent/Shared/AppConfigs/google_credential.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/google_credential.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/google_credential.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/google_credential.json diff --git a/src/shared/MixContent/Shared/AppConfigs/google_firebase.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/google_firebase.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/google_firebase.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/google_firebase.json diff --git a/src/shared/MixContent/Shared/AppConfigs/ip_security.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/ip_security.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/ip_security.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/ip_security.json diff --git a/src/shared/MixContent/Shared/AppConfigs/log.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/log.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/log.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/log.json diff --git a/src/shared/MixContent/Shared/AppConfigs/mix_heart.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/mix_heart.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/mix_heart.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/mix_heart.json diff --git a/src/shared/MixContent/Shared/AppConfigs/ocelot.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/ocelot.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/ocelot.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/ocelot.json diff --git a/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/payments.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/payments.json new file mode 100644 index 000000000..b6215f83c --- /dev/null +++ b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/payments.json @@ -0,0 +1,5 @@ +{ + "Payments": { + "IsActive": false + } +} \ No newline at end of file diff --git a/src/shared/MixContent/Shared/AppConfigs/portal.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/portal.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/portal.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/portal.json diff --git a/src/shared/MixContent/Shared/AppConfigs/quartz.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/quartz.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/quartz.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/quartz.json diff --git a/src/shared/MixContent/Shared/AppConfigs/queue.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/queue.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/queue.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/queue.json diff --git a/src/shared/MixContent/Shared/AppConfigs/rate_limit.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/rate_limit.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/rate_limit.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/rate_limit.json diff --git a/src/shared/MixContent/Shared/AppConfigs/redis.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/redis.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/redis.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/redis.json diff --git a/src/shared/MixContent/Shared/AppConfigs/smtp.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/smtp.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/smtp.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/smtp.json diff --git a/src/shared/MixContent/Shared/AppConfigs/storage.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/storage.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/storage.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/storage.json diff --git a/src/shared/MixContent/Shared/AppConfigs/translator.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/translator.json similarity index 100% rename from src/shared/MixContent/Shared/AppConfigs/translator.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/appconfigs/translator.json diff --git a/src/shared/MixContent/Shared/Json/cultures.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/cultures.json similarity index 100% rename from src/shared/MixContent/Shared/Json/cultures.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/cultures.json diff --git a/src/shared/MixContent/Shared/Json/enums.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/enums.json similarity index 100% rename from src/shared/MixContent/Shared/Json/enums.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/enums.json diff --git a/src/shared/MixContent/Shared/Json/micon.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/micon.json similarity index 100% rename from src/shared/MixContent/Shared/Json/micon.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/micon.json diff --git a/src/shared/MixContent/Shared/Json/portal-menus.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/portal-menus.json similarity index 100% rename from src/shared/MixContent/Shared/Json/portal-menus.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/portal-menus.json diff --git a/src/shared/MixContent/Shared/Json/system-databases.json b/src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/system-databases.json similarity index 100% rename from src/shared/MixContent/Shared/Json/system-databases.json rename to src/applications/Mixcore/wwwroot/default-mixcontent/shared/json/system-databases.json diff --git a/src/shared/MixContent/StaticFiles/readme.md b/src/applications/Mixcore/wwwroot/default-mixcontent/staticfiles/readme.md similarity index 100% rename from src/shared/MixContent/StaticFiles/readme.md rename to src/applications/Mixcore/wwwroot/default-mixcontent/staticfiles/readme.md diff --git a/src/shared/MixContent/Templates/_ViewImports.cshtml b/src/applications/Mixcore/wwwroot/default-mixcontent/templates/_ViewImports.cshtml similarity index 100% rename from src/shared/MixContent/Templates/_ViewImports.cshtml rename to src/applications/Mixcore/wwwroot/default-mixcontent/templates/_ViewImports.cshtml diff --git a/src/shared/MixContent/Templates/_ViewStart.cshtml b/src/applications/Mixcore/wwwroot/default-mixcontent/templates/_ViewStart.cshtml similarity index 100% rename from src/shared/MixContent/Templates/_ViewStart.cshtml rename to src/applications/Mixcore/wwwroot/default-mixcontent/templates/_ViewStart.cshtml diff --git a/src/modules/mix.account/StartupService.cs b/src/modules/mix.account/Domain/StartupService.cs similarity index 96% rename from src/modules/mix.account/StartupService.cs rename to src/modules/mix.account/Domain/StartupService.cs index 03b962df7..5439e7a5b 100644 --- a/src/modules/mix.account/StartupService.cs +++ b/src/modules/mix.account/Domain/StartupService.cs @@ -1,7 +1,7 @@ using Mix.Database.Entities.Account; using Mix.Lib.Interfaces; -namespace Mix.Account +namespace Mix.Account.Domain { public class StartupService : IStartupService { diff --git a/src/modules/mix.account/Domain/ViewModels/MixRoleViewModel.cs b/src/modules/mix.account/Domain/ViewModels/MixRoleViewModel.cs index ce7232708..5c8f646d2 100644 --- a/src/modules/mix.account/Domain/ViewModels/MixRoleViewModel.cs +++ b/src/modules/mix.account/Domain/ViewModels/MixRoleViewModel.cs @@ -12,7 +12,7 @@ public MixRoleViewModel() { } - public MixRoleViewModel(MixRole entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixRoleViewModel(MixRole entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/modules/mix.common/Controllers/SharedApiController.cs b/src/modules/mix.common/Controllers/SharedApiController.cs index ae8fc291f..1c1f8682d 100644 --- a/src/modules/mix.common/Controllers/SharedApiController.cs +++ b/src/modules/mix.common/Controllers/SharedApiController.cs @@ -197,7 +197,7 @@ public ActionResult GetGlobalSettings() [HttpPost] [Route("global-settings")] - public ActionResult GetSettings([FromBody] GlobalConfigurations settings) + public ActionResult GetSettings([FromBody] GlobalSettingsModel settings) { GlobalConfigService.Instance.AppSettings = settings; GlobalConfigService.Instance.SaveSettings(); diff --git a/src/modules/mix.common/Controllers/SharedTenantApiController.cs b/src/modules/mix.common/Controllers/SharedTenantApiController.cs index fffe7278b..ddc48aea3 100644 --- a/src/modules/mix.common/Controllers/SharedTenantApiController.cs +++ b/src/modules/mix.common/Controllers/SharedTenantApiController.cs @@ -44,7 +44,7 @@ public SharedTenantApiController( [HttpGet] [Route("get-global-settings")] - public ActionResult GetSharedSettings() + public ActionResult GetSharedSettings() { var settings = CommonHelper.GetAppSettings(_authConfigurations, CurrentTenant); return Ok(settings); diff --git a/src/modules/mix.common/Domain/Helpers/CommonHelper.cs b/src/modules/mix.common/Domain/Helpers/CommonHelper.cs index 44baef278..57b7acf3b 100644 --- a/src/modules/mix.common/Domain/Helpers/CommonHelper.cs +++ b/src/modules/mix.common/Domain/Helpers/CommonHelper.cs @@ -7,7 +7,7 @@ namespace Mix.Common.Domain.Helpers { public class CommonHelper { - internal static GlobalSettings GetAppSettings(MixAuthenticationConfigurations authConfigurations, MixTenantSystemModel currentTenant) + internal static Common.Models.GlobalSettings GetAppSettings(MixAuthenticationConfigurations authConfigurations, MixTenantSystemModel currentTenant) { //var cultures = _cultureService.Cultures; //var culture = _cultureService.LoadCulture(lang); diff --git a/src/modules/mix.common/Domain/ViewModels/PostContentViewModel.cs b/src/modules/mix.common/Domain/ViewModels/PostContentViewModel.cs index 61b9af84e..6b7beae56 100644 --- a/src/modules/mix.common/Domain/ViewModels/PostContentViewModel.cs +++ b/src/modules/mix.common/Domain/ViewModels/PostContentViewModel.cs @@ -14,7 +14,7 @@ public PostContentViewModel() { } - public PostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public PostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/modules/mix.grpc/Models/GrpcChannelModel.cs b/src/modules/mix.grpc/Domain/Models/GrpcChannelModel.cs similarity index 97% rename from src/modules/mix.grpc/Models/GrpcChannelModel.cs rename to src/modules/mix.grpc/Domain/Models/GrpcChannelModel.cs index d73e368e1..3999794e1 100644 --- a/src/modules/mix.grpc/Models/GrpcChannelModel.cs +++ b/src/modules/mix.grpc/Domain/Models/GrpcChannelModel.cs @@ -4,7 +4,7 @@ using System; using System.Threading.Tasks; -namespace Mix.Grpc.Models +namespace Mix.Grpc.Domain.Models { public class GrpcChannelModel { diff --git a/src/modules/mix.grpc/Protos/mix_grpc.proto b/src/modules/mix.grpc/Domain/Protos/mix_grpc.proto similarity index 100% rename from src/modules/mix.grpc/Protos/mix_grpc.proto rename to src/modules/mix.grpc/Domain/Protos/mix_grpc.proto diff --git a/src/modules/mix.grpc/Services/MixGrpcService.cs b/src/modules/mix.grpc/Domain/Services/MixGrpcService.cs similarity index 98% rename from src/modules/mix.grpc/Services/MixGrpcService.cs rename to src/modules/mix.grpc/Domain/Services/MixGrpcService.cs index 0c785d422..8b21faac9 100644 --- a/src/modules/mix.grpc/Services/MixGrpcService.cs +++ b/src/modules/mix.grpc/Domain/Services/MixGrpcService.cs @@ -5,7 +5,7 @@ using System.Reflection; using System.Threading.Tasks; -namespace Mix.Grpc +namespace Mix.Grpc.Domain.Services { public class MixGrpcService : MixGrpc.MixGrpcBase { diff --git a/src/modules/mix.grpc/StartupService.cs b/src/modules/mix.grpc/Domain/StartupService.cs similarity index 92% rename from src/modules/mix.grpc/StartupService.cs rename to src/modules/mix.grpc/Domain/StartupService.cs index 56d836857..50543e555 100644 --- a/src/modules/mix.grpc/StartupService.cs +++ b/src/modules/mix.grpc/Domain/StartupService.cs @@ -2,9 +2,10 @@ using Microsoft.AspNetCore.Routing; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; +using Mix.Grpc.Domain.Services; using Mix.Lib.Interfaces; -namespace Mix.Grpc +namespace Mix.Grpc.Domain { public class StartupService : IStartupService { diff --git a/src/modules/mix.grpc/Startup.cs b/src/modules/mix.grpc/Startup.cs index a14eb4bd8..b4ee4482f 100644 --- a/src/modules/mix.grpc/Startup.cs +++ b/src/modules/mix.grpc/Startup.cs @@ -2,6 +2,7 @@ using Microsoft.AspNetCore.Hosting; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Hosting; +using Mix.Grpc.Domain.Services; namespace Mix.Grpc { diff --git a/src/modules/mix.grpc/mix.grpc.csproj b/src/modules/mix.grpc/mix.grpc.csproj index 27edfc6e2..d1ad528ad 100644 --- a/src/modules/mix.grpc/mix.grpc.csproj +++ b/src/modules/mix.grpc/mix.grpc.csproj @@ -10,7 +10,7 @@ - + diff --git a/src/modules/mix.messenger/StartupService.cs b/src/modules/mix.messenger/Domain/StartupService.cs similarity index 96% rename from src/modules/mix.messenger/StartupService.cs rename to src/modules/mix.messenger/Domain/StartupService.cs index 66ae632c0..23505695e 100644 --- a/src/modules/mix.messenger/StartupService.cs +++ b/src/modules/mix.messenger/Domain/StartupService.cs @@ -4,7 +4,7 @@ using Microsoft.Extensions.DependencyInjection; using Mix.Lib.Interfaces; -namespace Mix.Messenger +namespace Mix.Messenger.Domain { public class StartupService : IStartupService { diff --git a/src/modules/mix.portal/Controllers/MixDbController.cs b/src/modules/mix.portal/Controllers/MixDbController.cs index 0f4e296e7..a5eb67986 100644 --- a/src/modules/mix.portal/Controllers/MixDbController.cs +++ b/src/modules/mix.portal/Controllers/MixDbController.cs @@ -435,7 +435,7 @@ private async Task PatchHandler(JObject objDto, CancellationToken cancellationTo throw new MixException(MixErrorStatus.Badrequest, ex); } } - private async Task ParseDtoToEntityAsync(JObject dto) + private Task ParseDtoToEntityAsync(JObject dto) { try { @@ -521,7 +521,7 @@ private async Task ParseDtoToEntityAsync(JObject dto) { result.Add(new JProperty(IsDeletedFieldName, false)); } - return result; + return Task.FromResult(result); } catch (Exception ex) { diff --git a/src/modules/mix.portal/Domain/ViewModels/MixApplicationViewModel.cs b/src/modules/mix.portal/Domain/ViewModels/MixApplicationViewModel.cs index 4abd35dc2..75938470f 100644 --- a/src/modules/mix.portal/Domain/ViewModels/MixApplicationViewModel.cs +++ b/src/modules/mix.portal/Domain/ViewModels/MixApplicationViewModel.cs @@ -7,6 +7,7 @@ public sealed class MixApplicationViewModel public string BaseHref { get; set; } public string BaseRoute { get; set; } + public JObject AppSettings { get; set; } public string Domain { get; set; } public string BaseApiUrl { get; set; } public int? TemplateId { get; set; } diff --git a/src/modules/mix.portal/Domain/ViewModels/MixPostContentViewModel.cs b/src/modules/mix.portal/Domain/ViewModels/MixPostContentViewModel.cs index 17d37fc21..54b80e418 100644 --- a/src/modules/mix.portal/Domain/ViewModels/MixPostContentViewModel.cs +++ b/src/modules/mix.portal/Domain/ViewModels/MixPostContentViewModel.cs @@ -17,7 +17,7 @@ public MixPortalPostContentViewModel() { } - public MixPortalPostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixPortalPostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/modules/mix.portal/Domain/ViewModels/MixPostPostViewModel.cs b/src/modules/mix.portal/Domain/ViewModels/MixPostPostViewModel.cs index d67902993..36744704b 100644 --- a/src/modules/mix.portal/Domain/ViewModels/MixPostPostViewModel.cs +++ b/src/modules/mix.portal/Domain/ViewModels/MixPostPostViewModel.cs @@ -13,7 +13,7 @@ public MixPostPostAssociationViewModel() { } - public MixPostPostAssociationViewModel(MixPostPostAssociation entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixPostPostAssociationViewModel(MixPostPostAssociation entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/modules/mix.scheduler/Jobs/KeepPoolAliveJob.cs b/src/modules/mix.scheduler/Domain/Jobs/KeepPoolAliveJob.cs similarity index 96% rename from src/modules/mix.scheduler/Jobs/KeepPoolAliveJob.cs rename to src/modules/mix.scheduler/Domain/Jobs/KeepPoolAliveJob.cs index de7543ffc..4ab2be551 100644 --- a/src/modules/mix.scheduler/Jobs/KeepPoolAliveJob.cs +++ b/src/modules/mix.scheduler/Domain/Jobs/KeepPoolAliveJob.cs @@ -9,7 +9,7 @@ using Mix.Quartz.Models; using NuGet.Packaging.Signing; -namespace Mix.Scheduler.Jobs +namespace Mix.Scheduler.Domain.Jobs { public class KeepPoolAliveJob : MixJobBase { @@ -39,7 +39,7 @@ public override async Task ExecuteHandler(IJobExecutionContext context) { var now = DateTime.UtcNow; var ping = await _httpService.GetStringAsync($"{domain.TrimEnd('/')}"); - + Console.WriteLine($"Ping at {now}: {(DateTime.Now - now).TotalMilliseconds}"); } catch (Exception ex) diff --git a/src/modules/mix.scheduler/Jobs/PublishScheduledPostsJob.cs b/src/modules/mix.scheduler/Domain/Jobs/PublishScheduledPostsJob.cs similarity index 93% rename from src/modules/mix.scheduler/Jobs/PublishScheduledPostsJob.cs rename to src/modules/mix.scheduler/Domain/Jobs/PublishScheduledPostsJob.cs index 4f2d4b4fe..0f8a96f18 100644 --- a/src/modules/mix.scheduler/Jobs/PublishScheduledPostsJob.cs +++ b/src/modules/mix.scheduler/Domain/Jobs/PublishScheduledPostsJob.cs @@ -5,7 +5,7 @@ using System; using System.Threading.Tasks; -namespace Mix.Scheduler.Jobs +namespace Mix.Scheduler.Domain.Jobs { public class PublishScheduledPostsJob : MixJobBase { diff --git a/src/modules/mix.scheduler/Jobs/SendMessageQueueJob.cs b/src/modules/mix.scheduler/Domain/Jobs/SendMessageQueueJob.cs similarity index 96% rename from src/modules/mix.scheduler/Jobs/SendMessageQueueJob.cs rename to src/modules/mix.scheduler/Domain/Jobs/SendMessageQueueJob.cs index 403ba9d63..a8bd84264 100644 --- a/src/modules/mix.scheduler/Jobs/SendMessageQueueJob.cs +++ b/src/modules/mix.scheduler/Domain/Jobs/SendMessageQueueJob.cs @@ -6,7 +6,7 @@ using System; using System.Threading.Tasks; -namespace Mix.Scheduler.Jobs +namespace Mix.Scheduler.Domain.Jobs { public class SendMessageQueueJob : MixJobBase { @@ -20,7 +20,7 @@ public override Task ExecuteHandler(IJobExecutionContext context) { var objData = JObject.Parse(context.Trigger.JobDataMap.GetString("data") ?? "{}"); int tenantId = objData.Value("tenantId"); - + var msg = new MessageQueueModel(tenantId) { Success = true, diff --git a/src/modules/mix.scheduler/Jobs/SendPortalMessageJob.cs b/src/modules/mix.scheduler/Domain/Jobs/SendPortalMessageJob.cs similarity index 96% rename from src/modules/mix.scheduler/Jobs/SendPortalMessageJob.cs rename to src/modules/mix.scheduler/Domain/Jobs/SendPortalMessageJob.cs index 36390e067..8e8611764 100644 --- a/src/modules/mix.scheduler/Jobs/SendPortalMessageJob.cs +++ b/src/modules/mix.scheduler/Domain/Jobs/SendPortalMessageJob.cs @@ -8,7 +8,7 @@ using Mix.Quartz.Jobs; using Mix.SignalR.Interfaces; -namespace Mix.Scheduler.Jobs +namespace Mix.Scheduler.Domain.Jobs { public class SendPortalMessageJob : MixJobBase { diff --git a/src/modules/mix.scheduler/StartupService.cs b/src/modules/mix.scheduler/Domain/StartupService.cs similarity index 95% rename from src/modules/mix.scheduler/StartupService.cs rename to src/modules/mix.scheduler/Domain/StartupService.cs index 62606f7d4..80c678384 100644 --- a/src/modules/mix.scheduler/StartupService.cs +++ b/src/modules/mix.scheduler/Domain/StartupService.cs @@ -4,7 +4,7 @@ using Microsoft.Extensions.DependencyInjection; using Mix.Lib.Interfaces; -namespace Mix.Scheduler +namespace Mix.Scheduler.Domain { public class StartupService : IStartupService { diff --git a/src/modules/mix.storage/StartupService.cs b/src/modules/mix.storage/Domain/StartupService.cs similarity index 94% rename from src/modules/mix.storage/StartupService.cs rename to src/modules/mix.storage/Domain/StartupService.cs index cd311ae2a..5a26e9391 100644 --- a/src/modules/mix.storage/StartupService.cs +++ b/src/modules/mix.storage/Domain/StartupService.cs @@ -1,7 +1,7 @@ using Mix.Lib.Interfaces; using Mix.Storage.Lib.Extensions; -namespace Mix.Storage +namespace Mix.Storage.Domain { public class StartupService : IStartupService { diff --git a/src/modules/mix.tenancy/StartupService.cs b/src/modules/mix.tenancy/Domain/StartupService.cs similarity index 98% rename from src/modules/mix.tenancy/StartupService.cs rename to src/modules/mix.tenancy/Domain/StartupService.cs index acdba91ff..25a217a9b 100644 --- a/src/modules/mix.tenancy/StartupService.cs +++ b/src/modules/mix.tenancy/Domain/StartupService.cs @@ -3,7 +3,7 @@ using Mix.Tenancy.Domain.Interfaces; using Mix.Tenancy.Domain.Services; -namespace Mix.Tenancy +namespace Mix.Tenancy.Domain { public class StartupService : IStartupService { diff --git a/src/platform/core/mix-heart b/src/platform/core/mix-heart index f46b5698f..4b9ac633b 160000 --- a/src/platform/core/mix-heart +++ b/src/platform/core/mix-heart @@ -1 +1 @@ -Subproject commit f46b5698f30fd2c1108e4c7f72de3ea2053afa28 +Subproject commit 4b9ac633bf6a986cbe590c49b9de9a4aec04bdbd diff --git a/src/platform/core/mix.mixdb.event/Services/MixDbEventService.cs b/src/platform/core/mix.mixdb.event/Services/MixDbEventService.cs index 49eb0a286..a630bdf82 100644 --- a/src/platform/core/mix.mixdb.event/Services/MixDbEventService.cs +++ b/src/platform/core/mix.mixdb.event/Services/MixDbEventService.cs @@ -1,6 +1,7 @@ using Microsoft.AspNetCore.Http; using Microsoft.Azure.Amqp.Framing; using Microsoft.CodeAnalysis.Elfie.Serialization; +using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; using Mix.Constant.Constants; using Mix.Database.Constants; @@ -16,6 +17,7 @@ using Mix.Service.Commands; using Mix.Service.Services; using Mix.Shared.Models; +using Mix.Shared.Models.Configurations; using Mix.Shared.Services; using Mix.SignalR.Enums; using Mix.SignalR.Interfaces; @@ -37,13 +39,16 @@ public class MixDbEventService private DatabaseService _databaseService; private MixPermissionService _mixPermissionService; public List Subscribers; + private readonly GlobalSettingsModel _globalConfig; private readonly HttpService _httpService; public MixDbEventService(DatabaseService databaseService, HttpService httpService, IPortalHubClientService portalHub, MixPermissionService mixPermissionService, - IServiceProvider servicesProvider) + IServiceProvider servicesProvider, + IConfiguration configuration) { _databaseService = databaseService; + _globalConfig = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get()!; LoadEvents(); _httpService = httpService; PortalHub = portalHub; @@ -53,7 +58,7 @@ public MixDbEventService(DatabaseService databaseService, HttpService httpServic public void LoadEvents() { - if (!GlobalConfigService.Instance.IsInit) + if (!_globalConfig.IsInit) { var repo = MixDbEventSubscriberViewModel.GetRootRepository(new MixDbDbContext(_databaseService), null); Subscribers = repo.GetAllAsync(m => !m.IsDeleted).GetAwaiter().GetResult(); diff --git a/src/platform/mix.constant/Constants/MixAppConfigFilePaths.cs b/src/platform/mix.constant/Constants/MixAppConfigFilePaths.cs index 93ccc1cab..448e3cb50 100644 --- a/src/platform/mix.constant/Constants/MixAppConfigFilePaths.cs +++ b/src/platform/mix.constant/Constants/MixAppConfigFilePaths.cs @@ -2,33 +2,33 @@ { public class MixAppConfigFilePaths { - public const string Authentication = "MixContent/Shared/AppConfigs/authentication"; - public const string AppConfigs = "MixContent/AppConfigs"; - public const string Shared = "MixContent/Shared"; - public const string Database = "MixContent/Shared/AppConfigs/database"; - public const string Culture = "MixContent/Shared/AppConfigs/culture"; - public const string ConnectionString = "MixContent/Shared/AppConfigs/connection_string"; - public const string MixConfigurations = "MixContent/Shared/AppConfigs/authentication"; - public const string Translator = "MixContent/Shared/AppConfigs/translator"; - public const string Configration = "MixContent/Shared/AppConfigs/configuration"; + public const string Authentication = "mixcontent/shared/appconfigs/authentication"; + public const string AppConfigs = "mixcontent/appconfigs"; + public const string Shared = "mixcontent/shared"; + public const string Database = "mixcontent/shared/appconfigs/database"; + public const string Culture = "mixcontent/shared/appconfigs/culture"; + public const string ConnectionString = "mixcontent/shared/appconfigs/connection_string"; + public const string MixConfigurations = "mixcontent/shared/appconfigs/authentication"; + public const string Translator = "mixcontent/shared/appconfigs/translator"; + public const string Configration = "mixcontent/shared/appconfigs/configuration"; - public const string Global = "MixContent/Shared/AppConfigs/global"; - public const string Portal = "MixContent/Shared/AppConfigs/portal"; - public const string EPPlus = "MixContent/Shared/AppConfigs/epplus"; - public const string IPSecurity = "MixContent/Shared/AppConfigs/ip_security"; - public const string MixHeart = "MixContent/Shared/AppConfigs/mix_heart"; - public const string Quartz = "MixContent/Shared/AppConfigs/quartz"; - public const string Smtp = "MixContent/Shared/AppConfigs/smtp"; - public const string Endpoint = "MixContent/Shared/AppConfigs/endpoint"; - public const string Azure = "MixContent/Shared/AppConfigs/azure"; - public const string Ocelot = "MixContent/Shared/AppConfigs/ocelot"; - public const string Storage = "MixContent/Shared/AppConfigs/storage"; - public const string Queue = "MixContent/Shared/AppConfigs/queue"; - public const string Payments = "MixContent/Shared/AppConfigs/payments"; - public const string Kiotviet = "MixContent/Shared/AppConfigs/kiotviet"; - public const string Log = "MixContent/Shared/AppConfigs/log"; - public const string RateLimit = "MixContent/Shared/AppConfigs/rate_limit"; - public const string GoogleFirebase = "MixContent/Shared/AppConfigs/google_firebase"; - public const string GoogleCredential = "MixContent/Shared/AppConfigs/google_credential"; + public const string Global = "mixcontent/shared/appconfigs/global"; + public const string Portal = "mixcontent/shared/appconfigs/portal"; + public const string EPPlus = "mixcontent/shared/appconfigs/epplus"; + public const string IPSecurity = "mixcontent/shared/appconfigs/ip_security"; + public const string MixHeart = "mixcontent/shared/appconfigs/mix_heart"; + public const string Quartz = "mixcontent/shared/appconfigs/quartz"; + public const string Smtp = "mixcontent/shared/appconfigs/smtp"; + public const string Endpoint = "mixcontent/shared/appconfigs/endpoint"; + public const string Azure = "mixcontent/shared/appconfigs/azure"; + public const string Ocelot = "mixcontent/shared/appconfigs/ocelot"; + public const string Storage = "mixcontent/shared/appconfigs/storage"; + public const string Queue = "mixcontent/shared/appconfigs/queue"; + public const string Payments = "mixcontent/shared/appconfigs/payments"; + public const string Kiotviet = "mixcontent/shared/appconfigs/kiotviet"; + public const string Log = "mixcontent/shared/appconfigs/log"; + public const string RateLimit = "mixcontent/shared/appconfigs/rate_limit"; + public const string GoogleFirebase = "mixcontent/shared/appconfigs/google_firebase"; + public const string GoogleCredential = "mixcontent/shared/appconfigs/google_credential"; } } \ No newline at end of file diff --git a/src/platform/mix.constant/Constants/MixConstants.cs b/src/platform/mix.constant/Constants/MixConstants.cs index d7ea1d5df..e40928ed7 100644 --- a/src/platform/mix.constant/Constants/MixConstants.cs +++ b/src/platform/mix.constant/Constants/MixConstants.cs @@ -26,6 +26,7 @@ public class MixConstants public const string CONST_DOMAIN_NOTIFICATION_KEY_COMMIT_VALUE = "We had a problem during saving your data."; public const string CONST_DOMAIN_NOTIFICATION = "DomainNotification"; public const string CONST_DEFAULT_AVATAR = "/mix-app/assets/img/user.png"; + public const string CONST_DEFAULT_MIX_CONTENT = "wwwroot/default-content.zip"; public const string CONST_DEFAULT_EXTENSIONS_FILE_PATH = "\\Contents\\Extensions\\"; public const string CONST_DEFAULT_EXTENSION_FILE_NAME = "extensions.json"; public const string CONST_DEFAULT_STRING_ID = "default"; diff --git a/src/platform/mix.constant/Constants/MixFolders.cs b/src/platform/mix.constant/Constants/MixFolders.cs index 0c286edd4..3d0ad053a 100644 --- a/src/platform/mix.constant/Constants/MixFolders.cs +++ b/src/platform/mix.constant/Constants/MixFolders.cs @@ -21,7 +21,7 @@ public class MixFolders public const string ImportFolder = "mixcontent/staticfiles/imports/themes"; public const string UploadsFolder = "uploads"; public const string SiteContentAssetsFolder = "mixcontent/assets"; - public const string SharedConfigurationFolder = "../../shared/MixContent"; + public const string DefaultMixContentFolder = "wwwroot/default-mixcontent"; public const string MixCoreConfigurationFolder = "../../applications/Mixcore/mixcontent"; } } \ No newline at end of file diff --git a/src/platform/mix.database/Entities/Cms/EntityConfigurations/MixApplicationConfiguration.cs b/src/platform/mix.database/Entities/Cms/EntityConfigurations/MixApplicationConfiguration.cs index b2f9c60c1..6f7e0acdd 100644 --- a/src/platform/mix.database/Entities/Cms/EntityConfigurations/MixApplicationConfiguration.cs +++ b/src/platform/mix.database/Entities/Cms/EntityConfigurations/MixApplicationConfiguration.cs @@ -17,6 +17,12 @@ public override void Configure(EntityTypeBuilder builder) builder.Property(e => e.DisplayName) .HasColumnType($"{Config.String}{Config.MediumLength}") .HasCharSet(Config.CharSet); + builder.Property(e => e.AppSettings) + .HasColumnType(Config.Text) + .HasConversion( + v => v.ToString(Newtonsoft.Json.Formatting.None), + v => !string.IsNullOrEmpty(v) ? JObject.Parse(v) : new()) + .HasCharSet(Config.CharSet); builder.Property(e => e.BaseHref) .HasColumnType($"{Config.String}{Config.MediumLength}") .HasCharSet(Config.CharSet); diff --git a/src/platform/mix.database/Entities/Cms/MixApplication.cs b/src/platform/mix.database/Entities/Cms/MixApplication.cs index 5b2f2269e..51ae1f9a4 100644 --- a/src/platform/mix.database/Entities/Cms/MixApplication.cs +++ b/src/platform/mix.database/Entities/Cms/MixApplication.cs @@ -1,16 +1,17 @@ -namespace Mix.Database.Entities.Cms +using Newtonsoft.Json.Linq; + +namespace Mix.Database.Entities.Cms { public class MixApplication : TenantEntityBase { public string BaseHref { get; set; } public string BaseRoute { get; set; } + public JObject AppSettings { get; set; } public string Domain { get; set; } public string BaseApiUrl { get; set; } public int? TemplateId { get; set; } public string Image { get; set; } public string MixDatabaseName { get; set; } public int? MixDbId { get; set; } - - //public JObject? ExtraData { get; set; } } } diff --git a/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.Designer.cs b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.Designer.cs new file mode 100644 index 000000000..eece18c79 --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.Designer.cs @@ -0,0 +1,2882 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using Mix.Database.Entities.Cms; +using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; + +#nullable disable + +namespace Mix.Database.Migrations.Cms.MySqlMixCms +{ + [DbContext(typeof(MySqlMixCmsContext))] + [Migration("20231008125316_UpdateMixApplication")] + partial class UpdateMixApplication + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "7.0.9") + .HasAnnotation("Relational:MaxIdentifierLength", 64); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("AppSettings") + .HasColumnType("longtext"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("AppSettings"), "utf8"); + + b.Property("BaseApiUrl") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("BaseApiUrl"), "utf8"); + + b.Property("BaseHref") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("BaseHref"), "utf8"); + + b.Property("BaseRoute") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("BaseRoute"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Domain") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Domain"), "utf8"); + + b.Property("Image") + .HasColumnType("longtext"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("MixDatabaseName"), "utf8"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.HasKey("Id") + .HasName("PK_MixApplication"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixApplication"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfiguration"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixConfiguration"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Category"), "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DataType"), "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DefaultContent"), "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixConfigurationId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfigurationContent"); + + b.HasIndex("MixConfigurationId"); + + b.HasIndex("MixCultureId"); + + b.ToTable("MixConfigurationContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixContributor", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ContentType"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("char(36)"); + + b.Property("IntContentId") + .HasColumnType("int"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsOwner") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("UserId") + .HasColumnType("char(36)"); + + b.HasKey("Id") + .HasName("PK_MixContributor"); + + b.ToTable("MixContributor"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Alias") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Alias"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(4000)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("Lcid") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Lcid"), "utf8"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixCulture"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatePermissions") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("CreatePermissions"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DeletePermissions") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DeletePermissions"), "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseContextId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReadPermissions") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ReadPermissions"), "utf8"); + + b.Property("SelfManaged") + .HasColumnType("tinyint(1)"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Type"), "utf8"); + + b.Property("UpdatePermissions") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("UpdatePermissions"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabase"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("char(36)") + .HasDefaultValueSql("(uuid())"); + + b.Property("ChildDatabaseName") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ChildDatabaseName"), "utf8"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidChildId") + .HasColumnType("char(36)"); + + b.Property("GuidParentId") + .HasColumnType("char(36)"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentDatabaseName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ParentDatabaseName"), "utf8"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseAssociation"); + + b.ToTable("MixDatabaseAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Configurations") + .HasColumnType("varchar(4000)"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DataType"), "utf8"); + + b.Property("DefaultValue") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DefaultValue"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("MixDatabaseName"), "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReferenceId") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseColumn"); + + b.HasIndex("MixDatabaseId"); + + b.ToTable("MixDatabaseColumn"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ConnectionString") + .IsRequired() + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ConnectionString"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DatabaseProvider") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DatabaseProvider"), "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Schema") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Schema"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseContext"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabaseContext"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DestinateDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DestinateDatabaseName"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SourceDatabaseName"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Type"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseRelationship"); + + b.HasIndex("ChildId"); + + b.HasIndex("ParentId"); + + b.ToTable("MixDatabaseRelationship"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDiscussion", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .IsRequired() + .HasColumnType("longtext"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ContentType"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("char(36)"); + + b.Property("IntContentId") + .HasColumnType("int"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("UserId") + .HasColumnType("char(36)"); + + b.HasKey("Id") + .HasName("PK_MixDiscussion"); + + b.ToTable("MixDiscussion"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Host") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Host"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDomain"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDomain"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguage"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Category"), "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DataType"), "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DefaultContent"), "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixLanguageId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixLanguageId"); + + b.ToTable("MixLanguageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("char(36)") + .HasDefaultValueSql("(uuid())"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("Extension") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Extension"), "utf8"); + + b.Property("FileFolder") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileFolder"), "utf8"); + + b.Property("FileName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileName"), "utf8"); + + b.Property("FileProperties") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileProperties"), "utf8"); + + b.Property("FileSize") + .HasColumnType("bigint"); + + b.Property("FileType") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileType"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Source"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("Tags") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Tags"), "utf8"); + + b.Property("TargetUrl") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("TargetUrl"), "utf8"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Title"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixMedia"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixMedia"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Type"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModule"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ClassName"), "utf8"); + + b.Property("Content") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Excerpt"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Image"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("longtext"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixModuleId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("int"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoDescription"), "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoKeywords"), "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoName"), "utf8"); + + b.Property("SeoTitle") + .HasColumnType("longtext"); + + b.Property("SimpleDataColumns") + .HasColumnType("longtext"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Source"), "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .HasColumnType("varchar(250)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Title"), "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Type"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleId"); + + b.ToTable("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Excerpt"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Image"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixModuleContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoDescription"), "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoKeywords"), "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoName"), "utf8"); + + b.Property("SeoTitle") + .HasColumnType("longtext"); + + b.Property("SimpleDataColumns") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SimpleDataColumns"), "utf8"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Source"), "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Title"), "utf8"); + + b.Property("Value") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Value"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleData"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModuleData"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("longtext"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime(6)"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime(6)"); + + b.Property("MixModuleContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("longtext"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModulePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixPostContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPage"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ClassName"), "utf8"); + + b.Property("Content") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Excerpt"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Image"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("longtext"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixPageId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("int"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoDescription"), "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoKeywords"), "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoName"), "utf8"); + + b.Property("SeoTitle") + .HasColumnType("longtext"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Source"), "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Title"), "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Type"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPageId"); + + b.ToTable("MixPageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("longtext"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime(6)"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime(6)"); + + b.Property("MixPageContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("longtext"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPageModuleAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("longtext"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime(6)"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime(6)"); + + b.Property("MixPageContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("longtext"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPagePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("longtext"); + + b.Property("DisplayName") + .HasColumnType("longtext"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPost"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ClassName"), "utf8"); + + b.Property("Content") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Excerpt"), "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Icon"), "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Image"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("IsPublic") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("longtext"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixPostContentId") + .HasColumnType("int"); + + b.Property("MixPostId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoDescription"), "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoKeywords"), "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SeoName"), "utf8"); + + b.Property("SeoTitle") + .HasColumnType("longtext"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Source"), "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Specificulture"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Title"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPostContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixPostId"); + + b.ToTable("MixPostContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostPostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("longtext"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime(6)"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime(6)"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("longtext"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.ToTable("MixPostPostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Content"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Extension") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Extension"), "utf8"); + + b.Property("FileFolder") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileFolder"), "utf8"); + + b.Property("FileName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FileName"), "utf8"); + + b.Property("FolderType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("FolderType"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("MixThemeId") + .HasColumnType("int"); + + b.Property("MixThemeName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("MixThemeName"), "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Scripts") + .IsRequired() + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Scripts"), "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("Styles") + .IsRequired() + .HasColumnType("longtext") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Styles"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTemplate"); + + b.HasIndex("MixThemeId"); + + b.ToTable("MixViewTemplate"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PrimaryDomain") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("PrimaryDomain"), "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("SystemName"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTenant"); + + b.ToTable("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("AssetFolder") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("AssetFolder"), "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("ImageUrl") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("ImageUrl"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("longtext"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PreviewUrl") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("PreviewUrl"), "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("SystemName") + .HasColumnType("longtext"); + + b.Property("TemplateFolder") + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("TemplateFolder"), "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTheme"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Alias") + .HasColumnType("longtext"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Description"), "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("utf8_unicode_ci"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("DisplayName"), "utf8"); + + b.Property("IsDeleted") + .HasColumnType("tinyint(1)"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceContentGuidId") + .HasColumnType("char(36)"); + + b.Property("SourceContentId") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("Status"), "utf8"); + + b.Property("Type") + .HasColumnType("int"); + + b.HasKey("Id") + .HasName("PK_MixUrlAlias"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixUrlAlias"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixConfiguration", "MixConfiguration") + .WithMany("MixConfigurationContents") + .HasForeignKey("MixConfigurationId"); + + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixConfiguration"); + + b.Navigation("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", null) + .WithMany("MixDatabases") + .HasForeignKey("MixTenantId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "MixDatabase") + .WithMany("MixDatabaseColumns") + .HasForeignKey("MixDatabaseId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "DestinateDatabase") + .WithMany("DestinateRelationships") + .HasForeignKey("ChildId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "SourceDatabase") + .WithMany("SourceRelationships") + .HasForeignKey("ParentId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.Navigation("DestinateDatabase"); + + b.Navigation("SourceDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixLanguage", "MixLanguage") + .WithMany("MixLanguageContents") + .HasForeignKey("MixLanguageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixModules") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModule", "MixModule") + .WithMany("MixModuleContents") + .HasForeignKey("MixModuleId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", "MixModuleContent") + .WithMany() + .HasForeignKey("MixModuleContentId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixModuleContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPages") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPages") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPage", "MixPage") + .WithMany("MixPageContents") + .HasForeignKey("MixPageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixModuleContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPosts") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixPost", "MixPost") + .WithMany("MixPostContents") + .HasForeignKey("MixPostId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTheme", "MixTheme") + .WithMany("MixViewTemplates") + .HasForeignKey("MixThemeId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Navigation("MixConfigurationContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Navigation("DestinateRelationships"); + + b.Navigation("MixDatabaseColumns"); + + b.Navigation("SourceRelationships"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Navigation("MixLanguageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Navigation("MixModuleContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Navigation("MixPageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Navigation("MixModuleContents"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Navigation("MixPages"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Navigation("MixDatabases"); + + b.Navigation("MixModules"); + + b.Navigation("MixPages"); + + b.Navigation("MixPosts"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Navigation("MixViewTemplates"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.cs b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.cs new file mode 100644 index 000000000..4ceaf50ea --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/20231008125316_UpdateMixApplication.cs @@ -0,0 +1,29 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Mix.Database.Migrations.Cms.MySqlMixCms +{ + /// + public partial class UpdateMixApplication : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "AppSettings", + table: "MixApplication", + type: "longtext", + nullable: true) + .Annotation("MySql:CharSet", "utf8"); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "AppSettings", + table: "MixApplication"); + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/MySqlMixCms/MySqlMixCmsContextModelSnapshot.cs b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/MySqlMixCmsContextModelSnapshot.cs index 14e70e19b..a1f05bce6 100644 --- a/src/platform/mix.database/Migrations/Cms/MySqlMixCms/MySqlMixCmsContextModelSnapshot.cs +++ b/src/platform/mix.database/Migrations/Cms/MySqlMixCms/MySqlMixCmsContextModelSnapshot.cs @@ -27,6 +27,11 @@ protected override void BuildModel(ModelBuilder modelBuilder) .HasColumnType("int") .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + b.Property("AppSettings") + .HasColumnType("longtext"); + + MySqlPropertyBuilderExtensions.HasCharSet(b.Property("AppSettings"), "utf8"); + b.Property("BaseApiUrl") .HasColumnType("varchar(250)"); diff --git a/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.Designer.cs b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.Designer.cs new file mode 100644 index 000000000..547c221a2 --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.Designer.cs @@ -0,0 +1,2736 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using Mix.Database.Entities.Cms; +using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; + +#nullable disable + +namespace Mix.Database.Migrations.PostgresqlMixCms +{ + [DbContext(typeof(PostgresqlMixCmsContext))] + [Migration("20231008125206_UpdateMixApplication")] + partial class UpdateMixApplication + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "7.0.9") + .HasAnnotation("Relational:MaxIdentifierLength", 63); + + NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("AppSettings") + .HasColumnType("text") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseApiUrl") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseHref") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseRoute") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Domain") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("text"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixDatabaseName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixDbId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("integer"); + + b.HasKey("Id") + .HasName("PK_MixApplication"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixApplication"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfiguration"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixConfiguration"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixConfigurationId") + .HasColumnType("integer"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfigurationContent"); + + b.HasIndex("MixConfigurationId"); + + b.HasIndex("MixCultureId"); + + b.ToTable("MixConfigurationContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixContributor", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("GuidContentId") + .HasColumnType("uuid"); + + b.Property("IntContentId") + .HasColumnType("integer"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsOwner") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("uuid"); + + b.HasKey("Id") + .HasName("PK_MixContributor"); + + b.ToTable("MixContributor"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Alias") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(4000)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("Lcid") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixCulture"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DeletePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixDatabaseContextId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReadPermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SelfManaged") + .HasColumnType("boolean"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UpdatePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabase"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uuid") + .HasDefaultValueSql("gen_random_uuid()"); + + b.Property("ChildDatabaseName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("GuidChildId") + .HasColumnType("uuid"); + + b.Property("GuidParentId") + .HasColumnType("uuid"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentDatabaseName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseAssociation"); + + b.ToTable("MixDatabaseAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Configurations") + .HasColumnType("varchar(4000)"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultValue") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixDatabaseId") + .HasColumnType("integer"); + + b.Property("MixDatabaseName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReferenceId") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseColumn"); + + b.HasIndex("MixDatabaseId"); + + b.ToTable("MixDatabaseColumn"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ConnectionString") + .IsRequired() + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DatabaseProvider") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Schema") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseContext"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabaseContext"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DestinateDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseRelationship"); + + b.HasIndex("ChildId"); + + b.HasIndex("ParentId"); + + b.ToTable("MixDatabaseRelationship"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDiscussion", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Content") + .IsRequired() + .HasColumnType("text") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("GuidContentId") + .HasColumnType("uuid"); + + b.Property("IntContentId") + .HasColumnType("integer"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("uuid"); + + b.HasKey("Id") + .HasName("PK_MixDiscussion"); + + b.ToTable("MixDiscussion"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Host") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDomain"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDomain"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguage"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixLanguageId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixLanguageId"); + + b.ToTable("MixLanguageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uuid") + .HasDefaultValueSql("gen_random_uuid()"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Extension") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileProperties") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileSize") + .HasColumnType("bigint"); + + b.Property("FileType") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Tags") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TargetUrl") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixMedia"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixMedia"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModule"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixDatabaseName") + .HasColumnType("text"); + + b.Property("MixDbId") + .HasColumnType("integer"); + + b.Property("MixModuleId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("integer"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("text"); + + b.Property("SimpleDataColumns") + .HasColumnType("text"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleId"); + + b.ToTable("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Content") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixModuleContentId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("text"); + + b.Property("SimpleDataColumns") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Value") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleData"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModuleData"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("text"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixModuleContentId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("text"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .HasColumnType("integer"); + + b.HasKey("Id"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModulePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixPostContentId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPage"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixDatabaseName") + .HasColumnType("text"); + + b.Property("MixDbId") + .HasColumnType("integer"); + + b.Property("MixPageId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("integer"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("text"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPageId"); + + b.ToTable("MixPageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("text"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixPageContentId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("text"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .HasColumnType("integer"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPageModuleAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("text"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixPageContentId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("text"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .HasColumnType("integer"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPagePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("text"); + + b.Property("DisplayName") + .HasColumnType("text"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPost"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("IsPublic") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("integer"); + + b.Property("MixDatabaseName") + .HasColumnType("text"); + + b.Property("MixDbId") + .HasColumnType("integer"); + + b.Property("MixPostContentId") + .HasColumnType("integer"); + + b.Property("MixPostId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("text"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPostContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixPostId"); + + b.ToTable("MixPostContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostPostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("integer"); + + b.Property("CreatedBy") + .HasColumnType("text"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("text"); + + b.Property("ParentId") + .HasColumnType("integer"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .HasColumnType("integer"); + + b.HasKey("Id"); + + b.ToTable("MixPostPostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Content") + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Extension") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FolderType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("MixThemeId") + .HasColumnType("integer"); + + b.Property("MixThemeName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Scripts") + .IsRequired() + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Styles") + .IsRequired() + .HasColumnType("text") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTemplate"); + + b.HasIndex("MixThemeId"); + + b.ToTable("MixViewTemplate"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PrimaryDomain") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTenant"); + + b.ToTable("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("AssetFolder") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ImageUrl") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixDatabaseName") + .HasColumnType("text"); + + b.Property("MixDbId") + .HasColumnType("integer"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PreviewUrl") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("text"); + + b.Property("TemplateFolder") + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTheme"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("integer"); + + NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + + b.Property("Alias") + .HasColumnType("text"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("timestamp with time zone"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("und-x-icu") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("boolean"); + + b.Property("LastModified") + .HasColumnType("timestamp with time zone"); + + b.Property("MixTenantId") + .HasColumnType("integer"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceContentGuidId") + .HasColumnType("uuid"); + + b.Property("SourceContentId") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .HasColumnType("integer"); + + b.HasKey("Id") + .HasName("PK_MixUrlAlias"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixUrlAlias"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixConfiguration", "MixConfiguration") + .WithMany("MixConfigurationContents") + .HasForeignKey("MixConfigurationId"); + + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixConfiguration"); + + b.Navigation("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", null) + .WithMany("MixDatabases") + .HasForeignKey("MixTenantId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "MixDatabase") + .WithMany("MixDatabaseColumns") + .HasForeignKey("MixDatabaseId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "DestinateDatabase") + .WithMany("DestinateRelationships") + .HasForeignKey("ChildId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "SourceDatabase") + .WithMany("SourceRelationships") + .HasForeignKey("ParentId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.Navigation("DestinateDatabase"); + + b.Navigation("SourceDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixLanguage", "MixLanguage") + .WithMany("MixLanguageContents") + .HasForeignKey("MixLanguageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixModules") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModule", "MixModule") + .WithMany("MixModuleContents") + .HasForeignKey("MixModuleId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", "MixModuleContent") + .WithMany() + .HasForeignKey("MixModuleContentId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixModuleContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPages") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPages") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPage", "MixPage") + .WithMany("MixPageContents") + .HasForeignKey("MixPageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixModuleContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPosts") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixPost", "MixPost") + .WithMany("MixPostContents") + .HasForeignKey("MixPostId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTheme", "MixTheme") + .WithMany("MixViewTemplates") + .HasForeignKey("MixThemeId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Navigation("MixConfigurationContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Navigation("DestinateRelationships"); + + b.Navigation("MixDatabaseColumns"); + + b.Navigation("SourceRelationships"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Navigation("MixLanguageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Navigation("MixModuleContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Navigation("MixPageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Navigation("MixModuleContents"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Navigation("MixPages"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Navigation("MixDatabases"); + + b.Navigation("MixModules"); + + b.Navigation("MixPages"); + + b.Navigation("MixPosts"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Navigation("MixViewTemplates"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.cs b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.cs new file mode 100644 index 000000000..fe6c7f89b --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/20231008125206_UpdateMixApplication.cs @@ -0,0 +1,28 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Mix.Database.Migrations.PostgresqlMixCms +{ + /// + public partial class UpdateMixApplication : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "AppSettings", + table: "MixApplication", + type: "text", + nullable: true); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "AppSettings", + table: "MixApplication"); + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/PostgresqlMixCmsContextModelSnapshot.cs b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/PostgresqlMixCmsContextModelSnapshot.cs index 5f5216f20..d3d767c1e 100644 --- a/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/PostgresqlMixCmsContextModelSnapshot.cs +++ b/src/platform/mix.database/Migrations/Cms/PostgresqlMixCms/PostgresqlMixCmsContextModelSnapshot.cs @@ -30,6 +30,10 @@ protected override void BuildModel(ModelBuilder modelBuilder) NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); + b.Property("AppSettings") + .HasColumnType("text") + .HasAnnotation("MySql:CharSet", "utf8"); + b.Property("BaseApiUrl") .HasColumnType("varchar(250)") .HasAnnotation("MySql:CharSet", "utf8"); diff --git a/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.Designer.cs b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.Designer.cs new file mode 100644 index 000000000..ce31b24ba --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.Designer.cs @@ -0,0 +1,2761 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Metadata; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using Mix.Database.Entities.Cms; +using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; + +#nullable disable + +namespace Mix.Database.Migrations.SqlServerMixCms +{ + [DbContext(typeof(SqlServerMixCmsContext))] + [Migration("20231008125433_UpdateMixApplication")] + partial class UpdateMixApplication + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "7.0.9") + .HasAnnotation("Relational:MaxIdentifierLength", 128); + + SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("AppSettings") + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseApiUrl") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseHref") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseRoute") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Domain") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("nvarchar(max)"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.HasKey("Id") + .HasName("PK_MixApplication"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixApplication"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfiguration"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixConfiguration"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Category") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixConfigurationId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfigurationContent"); + + b.HasIndex("MixConfigurationId"); + + b.HasIndex("MixCultureId"); + + b.ToTable("MixConfigurationContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixContributor", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("uniqueidentifier"); + + b.Property("IntContentId") + .HasColumnType("int"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsOwner") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("uniqueidentifier"); + + b.HasKey("Id") + .HasName("PK_MixContributor"); + + b.ToTable("MixContributor"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Alias") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(4000)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("Lcid") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixCulture"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatePermissions") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DeletePermissions") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseContextId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReadPermissions") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SelfManaged") + .HasColumnType("bit"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UpdatePermissions") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabase"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier") + .HasDefaultValueSql("newid()"); + + b.Property("ChildDatabaseName") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidChildId") + .HasColumnType("uniqueidentifier"); + + b.Property("GuidParentId") + .HasColumnType("uniqueidentifier"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentDatabaseName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseAssociation"); + + b.ToTable("MixDatabaseAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Configurations") + .HasColumnType("varchar(4000)"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultValue") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("ReferenceId") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseColumn"); + + b.HasIndex("MixDatabaseId"); + + b.ToTable("MixDatabaseColumn"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ConnectionString") + .IsRequired() + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DatabaseProvider") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Schema") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseContext"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabaseContext"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DestinateDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseRelationship"); + + b.HasIndex("ChildId"); + + b.HasIndex("ParentId"); + + b.ToTable("MixDatabaseRelationship"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDiscussion", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Content") + .IsRequired() + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("uniqueidentifier"); + + b.Property("IntContentId") + .HasColumnType("int"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("uniqueidentifier"); + + b.HasKey("Id") + .HasName("PK_MixDiscussion"); + + b.ToTable("MixDiscussion"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Host") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDomain"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDomain"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguage"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Category") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixLanguageId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixLanguageId"); + + b.ToTable("MixLanguageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier") + .HasDefaultValueSql("newid()"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Extension") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .HasColumnType("nvarchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileProperties") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileSize") + .HasColumnType("bigint"); + + b.Property("FileType") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Source") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Tags") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TargetUrl") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Title") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixMedia"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixMedia"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("nvarchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModule"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("nvarchar(max)"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixModuleId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("int"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("nvarchar(max)"); + + b.Property("SimpleDataColumns") + .HasColumnType("nvarchar(max)"); + + b.Property("Source") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleId"); + + b.ToTable("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixModuleContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("nvarchar(max)"); + + b.Property("SimpleDataColumns") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Source") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Value") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleData"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModuleData"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime2"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime2"); + + b.Property("MixModuleContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModulePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixPostContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPage"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("nvarchar(max)"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixPageId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("int"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("nvarchar(max)"); + + b.Property("Source") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPageId"); + + b.ToTable("MixPageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime2"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime2"); + + b.Property("MixPageContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPageModuleAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime2"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime2"); + + b.Property("MixPageContentId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPagePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(max)"); + + b.Property("DisplayName") + .HasColumnType("nvarchar(max)"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPost"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("IsPublic") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("int"); + + b.Property("MixCultureId") + .HasColumnType("int"); + + b.Property("MixDatabaseName") + .HasColumnType("nvarchar(max)"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixPostContentId") + .HasColumnType("int"); + + b.Property("MixPostId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("nvarchar(max)"); + + b.Property("Source") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("int"); + + b.Property("Title") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPostContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixPostId"); + + b.ToTable("MixPostContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostPostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ChildId") + .HasColumnType("int"); + + b.Property("CreatedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime2"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime2"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("nvarchar(max)"); + + b.Property("ParentId") + .HasColumnType("int"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.ToTable("MixPostPostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Extension") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FolderType") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("MixThemeId") + .HasColumnType("int"); + + b.Property("MixThemeName") + .IsRequired() + .HasColumnType("nvarchar(50)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Scripts") + .IsRequired() + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Styles") + .IsRequired() + .HasColumnType("ntext") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTemplate"); + + b.HasIndex("MixThemeId"); + + b.ToTable("MixViewTemplate"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PrimaryDomain") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTenant"); + + b.ToTable("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("AssetFolder") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ImageUrl") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("nvarchar(max)"); + + b.Property("MixDbId") + .HasColumnType("int"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PreviewUrl") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("nvarchar(max)"); + + b.Property("TemplateFolder") + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTheme"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Alias") + .HasColumnType("nvarchar(max)"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("nvarchar(4000)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("nvarchar(250)") + .UseCollation("Vietnamese_CI_AS") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("bit"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("int"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("int"); + + b.Property("SourceContentGuidId") + .HasColumnType("uniqueidentifier"); + + b.Property("SourceContentId") + .HasColumnType("int"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .HasColumnType("int"); + + b.HasKey("Id") + .HasName("PK_MixUrlAlias"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixUrlAlias"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixConfiguration", "MixConfiguration") + .WithMany("MixConfigurationContents") + .HasForeignKey("MixConfigurationId"); + + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixConfiguration"); + + b.Navigation("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", null) + .WithMany("MixDatabases") + .HasForeignKey("MixTenantId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "MixDatabase") + .WithMany("MixDatabaseColumns") + .HasForeignKey("MixDatabaseId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "DestinateDatabase") + .WithMany("DestinateRelationships") + .HasForeignKey("ChildId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "SourceDatabase") + .WithMany("SourceRelationships") + .HasForeignKey("ParentId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.Navigation("DestinateDatabase"); + + b.Navigation("SourceDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixLanguage", "MixLanguage") + .WithMany("MixLanguageContents") + .HasForeignKey("MixLanguageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixModules") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModule", "MixModule") + .WithMany("MixModuleContents") + .HasForeignKey("MixModuleId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", "MixModuleContent") + .WithMany() + .HasForeignKey("MixModuleContentId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixModuleContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPages") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPages") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPage", "MixPage") + .WithMany("MixPageContents") + .HasForeignKey("MixPageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixModuleContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPosts") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixPost", "MixPost") + .WithMany("MixPostContents") + .HasForeignKey("MixPostId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTheme", "MixTheme") + .WithMany("MixViewTemplates") + .HasForeignKey("MixThemeId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Navigation("MixConfigurationContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Navigation("DestinateRelationships"); + + b.Navigation("MixDatabaseColumns"); + + b.Navigation("SourceRelationships"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Navigation("MixLanguageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Navigation("MixModuleContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Navigation("MixPageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Navigation("MixModuleContents"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Navigation("MixPages"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Navigation("MixDatabases"); + + b.Navigation("MixModules"); + + b.Navigation("MixPages"); + + b.Navigation("MixPosts"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Navigation("MixViewTemplates"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.cs b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.cs new file mode 100644 index 000000000..95ac3ee79 --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/20231008125433_UpdateMixApplication.cs @@ -0,0 +1,28 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Mix.Database.Migrations.SqlServerMixCms +{ + /// + public partial class UpdateMixApplication : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "AppSettings", + table: "MixApplication", + type: "ntext", + nullable: true); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "AppSettings", + table: "MixApplication"); + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/SqlServerMixCmsContextModelSnapshot.cs b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/SqlServerMixCmsContextModelSnapshot.cs index 919dce51e..67d1d7d24 100644 --- a/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/SqlServerMixCmsContextModelSnapshot.cs +++ b/src/platform/mix.database/Migrations/Cms/SqlServerMixCms/SqlServerMixCmsContextModelSnapshot.cs @@ -32,6 +32,10 @@ protected override void BuildModel(ModelBuilder modelBuilder) SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + b.Property("AppSettings") + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + b.Property("BaseApiUrl") .HasColumnType("varchar(250)") .HasAnnotation("MySql:CharSet", "utf8"); diff --git a/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.Designer.cs b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.Designer.cs new file mode 100644 index 000000000..3e0964e19 --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.Designer.cs @@ -0,0 +1,2700 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using Mix.Database.Entities.Cms; +using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; + +#nullable disable + +namespace Mix.Database.Migrations.Cms.SqliteMixCms +{ + [DbContext(typeof(SqliteMixCmsContext))] + [Migration("20231008115949_UpdateMixApplication")] + partial class UpdateMixApplication + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.9"); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("AppSettings") + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseApiUrl") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseHref") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("BaseRoute") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Domain") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixDbId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("INTEGER"); + + b.HasKey("Id") + .HasName("PK_MixApplication"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixApplication"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfiguration"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixConfiguration"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixConfigurationId") + .HasColumnType("INTEGER"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixConfigurationContent"); + + b.HasIndex("MixConfigurationId"); + + b.HasIndex("MixCultureId"); + + b.ToTable("MixConfigurationContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixContributor", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("TEXT"); + + b.Property("IntContentId") + .HasColumnType("INTEGER"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsOwner") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("TEXT"); + + b.HasKey("Id") + .HasName("PK_MixContributor"); + + b.ToTable("MixContributor"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Alias") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(4000)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("Lcid") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Specificulture") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixCulture"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DeletePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseContextId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("ReadPermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SelfManaged") + .HasColumnType("INTEGER"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UpdatePermissions") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabase"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT") + .HasDefaultValueSql("(newid())"); + + b.Property("ChildDatabaseName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidChildId") + .HasColumnType("TEXT"); + + b.Property("GuidParentId") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentDatabaseName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseAssociation"); + + b.ToTable("MixDatabaseAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Configurations") + .HasColumnType("varchar(4000)"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultValue") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseId") + .HasColumnType("INTEGER"); + + b.Property("MixDatabaseName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("ReferenceId") + .HasColumnType("INTEGER"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseColumn"); + + b.HasIndex("MixDatabaseId"); + + b.ToTable("MixDatabaseColumn"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ConnectionString") + .IsRequired() + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DatabaseProvider") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Schema") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseContext"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDatabaseContext"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DestinateDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("SourceDatabaseName") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDatabaseRelationship"); + + b.HasIndex("ChildId"); + + b.HasIndex("ParentId"); + + b.ToTable("MixDatabaseRelationship"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDiscussion", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .IsRequired() + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ContentType") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("GuidContentId") + .HasColumnType("TEXT"); + + b.Property("IntContentId") + .HasColumnType("INTEGER"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("UserId") + .HasColumnType("TEXT"); + + b.HasKey("Id") + .HasName("PK_MixDiscussion"); + + b.ToTable("MixDiscussion"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Host") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixDomain"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixDomain"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguage"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Category") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("DataType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DefaultContent") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixLanguageId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixLanguageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixLanguageId"); + + b.ToTable("MixLanguageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT") + .HasDefaultValueSql("(newid())"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Extension") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileProperties") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileSize") + .HasColumnType("INTEGER"); + + b.Property("FileType") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Tags") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TargetUrl") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixMedia"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixMedia"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModule"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("integer"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixDatabaseName") + .HasColumnType("TEXT"); + + b.Property("MixDbId") + .HasColumnType("INTEGER"); + + b.Property("MixModuleId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("INTEGER"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("TEXT"); + + b.Property("SimpleDataColumns") + .HasColumnType("TEXT"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("varchar(250)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("integer"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleId"); + + b.ToTable("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("integer"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixModuleContentId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("TEXT"); + + b.Property("SimpleDataColumns") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("integer"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Value") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixModuleData"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModuleData"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER"); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("TEXT"); + + b.Property("CreatedDateTime") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("TEXT"); + + b.Property("MixModuleContentId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("TEXT"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("INTEGER"); + + b.Property("Status") + .HasColumnType("INTEGER"); + + b.HasKey("Id"); + + b.HasIndex("MixModuleContentId"); + + b.ToTable("MixModulePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixPostContentId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPage"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("integer"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixDatabaseName") + .HasColumnType("TEXT"); + + b.Property("MixDbId") + .HasColumnType("INTEGER"); + + b.Property("MixPageId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PageSize") + .HasColumnType("INTEGER"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("TEXT"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("integer"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPageContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPageId"); + + b.ToTable("MixPageContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER"); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("TEXT"); + + b.Property("CreatedDateTime") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("TEXT"); + + b.Property("MixPageContentId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("TEXT"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("INTEGER"); + + b.Property("Status") + .HasColumnType("INTEGER"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPageModuleAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER"); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("TEXT"); + + b.Property("CreatedDateTime") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("TEXT"); + + b.Property("MixPageContentId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("TEXT"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("INTEGER"); + + b.Property("Status") + .HasColumnType("INTEGER"); + + b.HasKey("Id"); + + b.HasIndex("MixPageContentId"); + + b.ToTable("MixPagePostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("TEXT"); + + b.Property("DisplayName") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPost"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("ClassName") + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Excerpt") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Icon") + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Image") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("IsPublic") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("LayoutId") + .HasColumnType("integer"); + + b.Property("MixCultureId") + .HasColumnType("INTEGER"); + + b.Property("MixDatabaseName") + .HasColumnType("TEXT"); + + b.Property("MixDbId") + .HasColumnType("INTEGER"); + + b.Property("MixPostContentId") + .HasColumnType("INTEGER"); + + b.Property("MixPostId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("PublishedDateTime") + .HasColumnType("datetime"); + + b.Property("SeoDescription") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoKeywords") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoName") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SeoTitle") + .HasColumnType("TEXT"); + + b.Property("Source") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Specificulture") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("TemplateId") + .HasColumnType("integer"); + + b.Property("Title") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixPostContent"); + + b.HasIndex("MixCultureId"); + + b.HasIndex("MixPostContentId"); + + b.HasIndex("MixPostId"); + + b.ToTable("MixPostContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostPostAssociation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER"); + + b.Property("ChildId") + .HasColumnType("INTEGER"); + + b.Property("CreatedBy") + .HasColumnType("TEXT"); + + b.Property("CreatedDateTime") + .HasColumnType("TEXT"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("TEXT"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("TEXT"); + + b.Property("ParentId") + .HasColumnType("INTEGER"); + + b.Property("Priority") + .HasColumnType("INTEGER"); + + b.Property("Status") + .HasColumnType("INTEGER"); + + b.HasKey("Id"); + + b.ToTable("MixPostPostAssociation"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Content") + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Extension") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileFolder") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FileName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("FolderType") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("MixThemeId") + .HasColumnType("INTEGER"); + + b.Property("MixThemeName") + .IsRequired() + .HasColumnType("varchar(50)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Scripts") + .IsRequired() + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Styles") + .IsRequired() + .HasColumnType("ntext") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTemplate"); + + b.HasIndex("MixThemeId"); + + b.ToTable("MixViewTemplate"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PrimaryDomain") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTenant"); + + b.ToTable("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("AssetFolder") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("ImageUrl") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixDatabaseName") + .HasColumnType("TEXT"); + + b.Property("MixDbId") + .HasColumnType("INTEGER"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("PreviewUrl") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("SystemName") + .HasColumnType("TEXT"); + + b.Property("TemplateFolder") + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.HasKey("Id") + .HasName("PK_MixTheme"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("INTEGER") + .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + + b.Property("Alias") + .HasColumnType("TEXT"); + + b.Property("CreatedBy") + .HasColumnType("varchar(250)"); + + b.Property("CreatedDateTime") + .HasColumnType("datetime"); + + b.Property("Description") + .HasColumnType("varchar(4000)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("DisplayName") + .IsRequired() + .HasColumnType("varchar(250)") + .UseCollation("NOCASE") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("IsDeleted") + .HasColumnType("INTEGER"); + + b.Property("LastModified") + .HasColumnType("datetime"); + + b.Property("MixTenantId") + .HasColumnType("INTEGER"); + + b.Property("ModifiedBy") + .HasColumnType("varchar(250)"); + + b.Property("Priority") + .HasColumnType("integer"); + + b.Property("SourceContentGuidId") + .HasColumnType("TEXT"); + + b.Property("SourceContentId") + .HasColumnType("INTEGER"); + + b.Property("Status") + .IsRequired() + .HasColumnType("varchar(50)") + .HasAnnotation("MySql:CharSet", "utf8"); + + b.Property("Type") + .HasColumnType("INTEGER"); + + b.HasKey("Id") + .HasName("PK_MixUrlAlias"); + + b.HasIndex("MixTenantId"); + + b.ToTable("MixUrlAlias"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixApplication", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfigurationContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixConfiguration", "MixConfiguration") + .WithMany("MixConfigurationContents") + .HasForeignKey("MixConfigurationId"); + + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixConfiguration"); + + b.Navigation("MixCulture"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixCulture", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", null) + .WithMany("MixDatabases") + .HasForeignKey("MixTenantId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseColumn", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "MixDatabase") + .WithMany("MixDatabaseColumns") + .HasForeignKey("MixDatabaseId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseContext", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabaseRelationship", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "DestinateDatabase") + .WithMany("DestinateRelationships") + .HasForeignKey("ChildId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixDatabase", "SourceDatabase") + .WithMany("SourceRelationships") + .HasForeignKey("ParentId") + .OnDelete(DeleteBehavior.NoAction) + .IsRequired(); + + b.Navigation("DestinateDatabase"); + + b.Navigation("SourceDatabase"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDomain", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixLanguage", "MixLanguage") + .WithMany("MixLanguageContents") + .HasForeignKey("MixLanguageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixLanguage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixMedia", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixModules") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModule", "MixModule") + .WithMany("MixModuleContents") + .HasForeignKey("MixModuleId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModule"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleData", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", "MixModuleContent") + .WithMany() + .HasForeignKey("MixModuleContentId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixModuleContent"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModulePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixModuleContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixModuleContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPages") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPages") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPage", "MixPage") + .WithMany("MixPageContents") + .HasForeignKey("MixPageId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPage"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageModuleAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixModuleContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPagePostAssociation", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixPageContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPageContentId"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany("MixPosts") + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixCulture", "MixCulture") + .WithMany() + .HasForeignKey("MixCultureId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Mix.Database.Entities.Cms.MixPostContent", null) + .WithMany("MixPostContents") + .HasForeignKey("MixPostContentId"); + + b.HasOne("Mix.Database.Entities.Cms.MixPost", "MixPost") + .WithMany("MixPostContents") + .HasForeignKey("MixPostId"); + + b.Navigation("MixCulture"); + + b.Navigation("MixPost"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTemplate", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTheme", "MixTheme") + .WithMany("MixViewTemplates") + .HasForeignKey("MixThemeId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTheme"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixUrlAlias", b => + { + b.HasOne("Mix.Database.Entities.Cms.MixTenant", "MixTenant") + .WithMany() + .HasForeignKey("MixTenantId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("MixTenant"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixConfiguration", b => + { + b.Navigation("MixConfigurationContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixDatabase", b => + { + b.Navigation("DestinateRelationships"); + + b.Navigation("MixDatabaseColumns"); + + b.Navigation("SourceRelationships"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixLanguage", b => + { + b.Navigation("MixLanguageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModule", b => + { + b.Navigation("MixModuleContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixModuleContent", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPage", b => + { + b.Navigation("MixPageContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPageContent", b => + { + b.Navigation("MixModuleContents"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPost", b => + { + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixPostContent", b => + { + b.Navigation("MixPages"); + + b.Navigation("MixPostContents"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTenant", b => + { + b.Navigation("MixDatabases"); + + b.Navigation("MixModules"); + + b.Navigation("MixPages"); + + b.Navigation("MixPosts"); + }); + + modelBuilder.Entity("Mix.Database.Entities.Cms.MixTheme", b => + { + b.Navigation("MixViewTemplates"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.cs b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.cs new file mode 100644 index 000000000..945264e13 --- /dev/null +++ b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/20231008115949_UpdateMixApplication.cs @@ -0,0 +1,28 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Mix.Database.Migrations.Cms.SqliteMixCms +{ + /// + public partial class UpdateMixApplication : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "AppSettings", + table: "MixApplication", + type: "ntext", + nullable: true); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "AppSettings", + table: "MixApplication"); + } + } +} diff --git a/src/platform/mix.database/Migrations/Cms/SqliteMixCms/SqliteMixCmsContextModelSnapshot.cs b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/SqliteMixCmsContextModelSnapshot.cs index 1cb576345..ddb034047 100644 --- a/src/platform/mix.database/Migrations/Cms/SqliteMixCms/SqliteMixCmsContextModelSnapshot.cs +++ b/src/platform/mix.database/Migrations/Cms/SqliteMixCms/SqliteMixCmsContextModelSnapshot.cs @@ -25,6 +25,10 @@ protected override void BuildModel(ModelBuilder modelBuilder) .HasColumnType("INTEGER") .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); + b.Property("AppSettings") + .HasColumnType("ntext") + .HasAnnotation("MySql:CharSet", "utf8"); + b.Property("BaseApiUrl") .HasColumnType("varchar(250)") .HasAnnotation("MySql:CharSet", "utf8"); diff --git a/src/platform/mix.identity/ViewModels/RoleViewModel.cs b/src/platform/mix.identity/ViewModels/RoleViewModel.cs index 0f6ac7132..71cddaa9a 100644 --- a/src/platform/mix.identity/ViewModels/RoleViewModel.cs +++ b/src/platform/mix.identity/ViewModels/RoleViewModel.cs @@ -12,7 +12,7 @@ public RoleViewModel() { } - public RoleViewModel(MixRole entity, UnitOfWorkInfo uowInfo = null) + public RoleViewModel(MixRole entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/AssociationViewModelBase.cs b/src/platform/mix.library/Base/AssociationViewModelBase.cs index b6ee4ae86..6cfb31e7f 100644 --- a/src/platform/mix.library/Base/AssociationViewModelBase.cs +++ b/src/platform/mix.library/Base/AssociationViewModelBase.cs @@ -20,7 +20,7 @@ protected AssociationViewModelBase(UnitOfWorkInfo unitOfWorkInfo) { } - protected AssociationViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected AssociationViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/ExtraColumnMultilingualSEOContentViewModelBase.cs b/src/platform/mix.library/Base/ExtraColumnMultilingualSEOContentViewModelBase.cs index abe00c406..e87e3e3b2 100644 --- a/src/platform/mix.library/Base/ExtraColumnMultilingualSEOContentViewModelBase.cs +++ b/src/platform/mix.library/Base/ExtraColumnMultilingualSEOContentViewModelBase.cs @@ -19,7 +19,7 @@ protected ExtraColumnMultilingualSEOContentViewModelBase(UnitOfWorkInfo unitOfWo { } - protected ExtraColumnMultilingualSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected ExtraColumnMultilingualSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/HaveParentContentViewModelBase.cs b/src/platform/mix.library/Base/HaveParentContentViewModelBase.cs index 0f06c22af..093b9b581 100644 --- a/src/platform/mix.library/Base/HaveParentContentViewModelBase.cs +++ b/src/platform/mix.library/Base/HaveParentContentViewModelBase.cs @@ -18,7 +18,7 @@ protected HaveParentContentViewModelBase(UnitOfWorkInfo unitOfWorkInfo) { } - protected HaveParentContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected HaveParentContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/HaveParentSEOContentViewModelBase.cs b/src/platform/mix.library/Base/HaveParentSEOContentViewModelBase.cs index ceea22c3c..4c4fbac6b 100644 --- a/src/platform/mix.library/Base/HaveParentSEOContentViewModelBase.cs +++ b/src/platform/mix.library/Base/HaveParentSEOContentViewModelBase.cs @@ -18,7 +18,7 @@ protected HaveParentSEOContentViewModelBase(UnitOfWorkInfo unitOfWorkInfo) { } - protected HaveParentSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected HaveParentSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/MixControllerBase.cs b/src/platform/mix.library/Base/MixControllerBase.cs index dd224e523..d0b42fb6e 100644 --- a/src/platform/mix.library/Base/MixControllerBase.cs +++ b/src/platform/mix.library/Base/MixControllerBase.cs @@ -4,6 +4,8 @@ using Microsoft.AspNetCore.Mvc.Rendering; using Microsoft.Extensions.Configuration; using Mix.Lib.Interfaces; +using Mix.Shared.Models.Configurations; +using RepoDb; using System.Globalization; namespace Mix.Lib.Base @@ -17,6 +19,7 @@ public abstract class MixControllerBase : Controller protected bool IsValid = true; protected string RedirectUrl; protected readonly IPSecurityConfigService IpSecurityConfigService; + protected readonly GlobalSettingsModel GlobalConfig; protected readonly IMixCmsService MixCmsService; protected IMixTenantService TenantService; protected MixTenantSystemModel CurrentTenant => Session.Get(MixRequestQueryKeywords.Tenant); @@ -40,13 +43,16 @@ protected MixControllerBase( IHttpContextAccessor httpContextAccessor, IMixCmsService mixCmsService, IPSecurityConfigService ipSecurityConfigService, - IMixTenantService tenantService) + IMixTenantService tenantService, + IConfiguration configuration) { + Configuration = configuration; Session = httpContextAccessor.HttpContext?.Session; IpSecurityConfigService = ipSecurityConfigService; ViewData[MixRequestQueryKeywords.Tenant] = CurrentTenant; MixCmsService = mixCmsService; TenantService = tenantService; + GlobalConfig = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get()!; } private void LoadCulture() @@ -90,7 +96,7 @@ private void LoadCulture() public override Task OnActionExecutionAsync(ActionExecutingContext context, ActionExecutionDelegate next) { - if (!GlobalConfigService.Instance.AppSettings.IsInit) + if (!GlobalConfig.IsInit) { LoadCulture(); } @@ -137,7 +143,7 @@ protected virtual void ValidateRequest() } // If mode Maintenance enabled in appsettings - if (!GlobalConfigService.Instance.IsInit + if (!GlobalConfig.IsInit && CurrentTenant != null && CurrentTenant.Configurations != null && CurrentTenant.Configurations.IsMaintenance diff --git a/src/platform/mix.library/Base/MultilingualContentViewModelBase.cs b/src/platform/mix.library/Base/MultilingualContentViewModelBase.cs index 096b4ae85..a987e59ef 100644 --- a/src/platform/mix.library/Base/MultilingualContentViewModelBase.cs +++ b/src/platform/mix.library/Base/MultilingualContentViewModelBase.cs @@ -23,7 +23,7 @@ protected MultilingualContentViewModelBase(UnitOfWorkInfo unitOfWorkInfo) { } - protected MultilingualContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected MultilingualContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/MultilingualSEOContentViewModelBase.cs b/src/platform/mix.library/Base/MultilingualSEOContentViewModelBase.cs index ab8a5bd20..460a83dff 100644 --- a/src/platform/mix.library/Base/MultilingualSEOContentViewModelBase.cs +++ b/src/platform/mix.library/Base/MultilingualSEOContentViewModelBase.cs @@ -21,7 +21,7 @@ protected MultilingualSEOContentViewModelBase(UnitOfWorkInfo unitOfWorkInfo) { } - protected MultilingualSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected MultilingualSEOContentViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/TenantDataUniqueNameViewModelBase.cs b/src/platform/mix.library/Base/TenantDataUniqueNameViewModelBase.cs index f529b0c3a..afb222712 100644 --- a/src/platform/mix.library/Base/TenantDataUniqueNameViewModelBase.cs +++ b/src/platform/mix.library/Base/TenantDataUniqueNameViewModelBase.cs @@ -18,7 +18,7 @@ protected TenantDataUniqueNameViewModelBase(UnitOfWorkInfo unitOfWorkInfo) : bas { } - protected TenantDataUniqueNameViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected TenantDataUniqueNameViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Base/TenantDataViewModelBase.cs b/src/platform/mix.library/Base/TenantDataViewModelBase.cs index 5b00130a1..730bf5d00 100644 --- a/src/platform/mix.library/Base/TenantDataViewModelBase.cs +++ b/src/platform/mix.library/Base/TenantDataViewModelBase.cs @@ -18,7 +18,7 @@ protected TenantDataViewModelBase(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfWo { } - protected TenantDataViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo = null) + protected TenantDataViewModelBase(TEntity entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/Helpers/MixCmsHelper.cs b/src/platform/mix.library/Helpers/MixCmsHelper.cs index 7eaf72265..393d27317 100644 --- a/src/platform/mix.library/Helpers/MixCmsHelper.cs +++ b/src/platform/mix.library/Helpers/MixCmsHelper.cs @@ -66,7 +66,7 @@ public static IHostBuilder CreateHostBuilder(string[] args) where TSta // Clone Settings from shared folder if (!mixContentFolder.Exists) { - MixHelper.CopyFolder(MixFolders.SharedConfigurationFolder, MixFolders.MixContentFolder); + MixHelper.CopyFolder(MixFolders.DefaultMixContentFolder, MixFolders.MixContentFolder); Console.WriteLine("Clone Settings from shared folder completed."); } return Host.CreateDefaultBuilder(args) diff --git a/src/platform/mix.library/Middlewares/AuditlogMiddleware.cs b/src/platform/mix.library/Middlewares/AuditlogMiddleware.cs index 4d668f068..c90fd2080 100644 --- a/src/platform/mix.library/Middlewares/AuditlogMiddleware.cs +++ b/src/platform/mix.library/Middlewares/AuditlogMiddleware.cs @@ -17,10 +17,12 @@ public class AuditlogMiddleware private IAuditLogService _auditlogService; private AuditLogDataModel _auditlogData; private IConfiguration _configuration; + private GlobalSettingsModel _globalConfig; private bool _isLog { get; set; } public AuditlogMiddleware(RequestDelegate next, IConfiguration configuration, IAuditLogService auditlogService) { _configuration = configuration; + _globalConfig = _configuration.Get(); _next = next; _auditlogData = new(); _auditlogService = auditlogService; @@ -82,7 +84,7 @@ public async Task InvokeAsync(HttpContext context) } private bool CheckAuditLogPath(string path) { - return !GlobalConfigService.Instance.IsInit && (path.IndexOf("/api") == 0 && path.IndexOf("audit-log") < 0 && path.IndexOf("queue-log") < 0); + return !_globalConfig.IsInit && (path.IndexOf("/api") == 0 && path.IndexOf("audit-log") < 0 && path.IndexOf("queue-log") < 0); } private async Task LogRequest(HttpContext context) diff --git a/src/platform/mix.library/Middlewares/UnitOfWorkMiddleware.cs b/src/platform/mix.library/Middlewares/UnitOfWorkMiddleware.cs index 8b6fe98cd..29a2a6908 100644 --- a/src/platform/mix.library/Middlewares/UnitOfWorkMiddleware.cs +++ b/src/platform/mix.library/Middlewares/UnitOfWorkMiddleware.cs @@ -1,6 +1,8 @@ using Microsoft.AspNetCore.Http; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Storage; +using Microsoft.Extensions.Configuration; +using Mix.Shared.Models.Configurations; using System.Data.Common; namespace Mix.Lib.Middlewares @@ -9,9 +11,11 @@ public class UnitOfWorkMiddleware { private readonly RequestDelegate _next; private static readonly List UowInfos = new(); - public UnitOfWorkMiddleware(RequestDelegate next) + private GlobalSettingsModel _globalConfig; + public UnitOfWorkMiddleware(RequestDelegate next, IConfiguration configuration) { _next = next; + _globalConfig = configuration.Get(); } public static void AddUnitOfWork() where T : IUnitOfWorkInfo @@ -46,7 +50,7 @@ private async Task ShareTransaction(HttpContext context, Dictionary dicConnections, Dictionary dicTransactions) { - if (GlobalConfigService.Instance.IsInit) + if (_globalConfig.IsInit) { return; } diff --git a/src/platform/mix.library/Services/MixIdentityService.cs b/src/platform/mix.library/Services/MixIdentityService.cs index e59d5c63d..de4ffd3ca 100644 --- a/src/platform/mix.library/Services/MixIdentityService.cs +++ b/src/platform/mix.library/Services/MixIdentityService.cs @@ -1,5 +1,6 @@ using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Identity; +using Microsoft.Extensions.Configuration; using Microsoft.IdentityModel.Tokens; using Mix.Communicator.Services; using Mix.Database.Entities.Account; @@ -29,6 +30,7 @@ public class MixIdentityService : IMixIdentityService { protected const string TenantIdFieldName = "MixTenantId"; protected const string datetimeFormat = "yyyy-MM-ddTHH:mm:ss.FFFZ"; + protected IConfiguration Configuration; protected readonly UnitOfWorkInfo AccountUow; protected readonly UnitOfWorkInfo CmsUow; protected readonly UnitOfWorkInfo MixDbUow; @@ -37,6 +39,7 @@ public class MixIdentityService : IMixIdentityService protected readonly SignInManager SignInManager; protected readonly RoleManager RoleManager; protected readonly AuthConfigService AuthConfigService; + protected readonly GlobalSettingsModel GlobalConfig; protected readonly FirebaseService FirebaseService; protected readonly IMixDbDataService MixDbDataService; protected readonly MixRepoDbRepository RepoDbRepository; @@ -72,9 +75,10 @@ public MixIdentityService( DatabaseService databaseService, MixCmsAccountContext accContext, UnitOfWorkInfo mixDbUow, - IMixDbDataService mixDbDataService) + IMixDbDataService mixDbDataService, IConfiguration configuration) { Session = httpContextAccessor.HttpContext?.Session; + Configuration = configuration; CmsUow = cmsUow; CmsContext = cmsUow.DbContext; CacheService = cacheService; @@ -91,6 +95,7 @@ public MixIdentityService( _accContext = accContext; MixDbUow = mixDbUow; MixDbDataService = mixDbDataService; + GlobalConfig = Configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get(); } public virtual async Task Any(Guid userId) @@ -160,7 +165,7 @@ public virtual async Task LoginAsync(LoginViewModel model, Cancellation public virtual async Task GetAuthData(MixUser user, bool rememberMe, int tenantId, CancellationToken cancellationToken = default) { var rsaKeys = RSAEncryptionHelper.GenerateKeys(); - var aesKey = GlobalConfigService.Instance.AesKey; //AesEncryptionHelper.GenerateCombinedKeys(); + var aesKey = GlobalConfig.ApiEncryptKey; var token = await GenerateAccessTokenAsync(user, rememberMe, aesKey, rsaKeys[MixConstants.CONST_RSA_PUBLIC_KEY], cancellationToken); if (token != null) @@ -246,7 +251,7 @@ public async Task GetOrCreateUserData(MixUser user, CancellationToken c try { var u = await MixDbDataService.GetSingleByParent(MixDatabaseNames.SYSTEM_USER_DATA, MixContentType.User, user.Id, true); - if (u == null && !GlobalConfigService.Instance.IsInit) + if (u == null && !GlobalConfig.IsInit) { u = new JObject() { diff --git a/src/platform/mix.library/Startup/AuthServiceCollectionExtensions.cs b/src/platform/mix.library/Startup/AuthServiceCollectionExtensions.cs index c3aa47749..45d558be5 100644 --- a/src/platform/mix.library/Startup/AuthServiceCollectionExtensions.cs +++ b/src/platform/mix.library/Startup/AuthServiceCollectionExtensions.cs @@ -16,7 +16,7 @@ using Mix.Identity.Extensions; using Mix.Lib.Interfaces; using Mix.Lib.Services; - +using Mix.Shared.Models.Configurations; using System.Text; namespace Microsoft.Extensions.DependencyInjection { @@ -27,8 +27,8 @@ public static IServiceCollection AddMixAuthorize(this IServiceCollec where TDbContext : DbContext { AuthConfigService authConfigService = services.GetService(); - - if (GlobalConfigService.Instance.IsInit) + var _globalConfig = configuration.Get()!; + if (_globalConfig.IsInit) { authConfigService.AppSettings.SecretKey = Guid.NewGuid().ToString("N"); authConfigService.SaveSettings(); diff --git a/src/platform/mix.library/Startup/Migration.cs b/src/platform/mix.library/Startup/Migration.cs index 04b6b81dd..0a8f01095 100644 --- a/src/platform/mix.library/Startup/Migration.cs +++ b/src/platform/mix.library/Startup/Migration.cs @@ -3,13 +3,14 @@ using Mix.Database.Services; using Mix.RepoDb.Interfaces; using Mix.RepoDb.Services; +using Mix.Shared.Models.Configurations; namespace Microsoft.Extensions.DependencyInjection { public static partial class ServiceCollectionExtensions { - private static void ApplyMigrations(this IServiceCollection services, Mix.Shared.Models.Configurations.GlobalConfigurations options) + private static void ApplyMigrations(this IServiceCollection services, GlobalSettingsModel options) { if (!options.IsInit) { diff --git a/src/platform/mix.library/Startup/_ServiceCollectionExtensions.cs b/src/platform/mix.library/Startup/_ServiceCollectionExtensions.cs index 5f9c17d2f..fd1822d20 100644 --- a/src/platform/mix.library/Startup/_ServiceCollectionExtensions.cs +++ b/src/platform/mix.library/Startup/_ServiceCollectionExtensions.cs @@ -12,6 +12,7 @@ using Mix.Mixdb.Event.Services; using Mix.Service.Interfaces; using Mix.Shared; +using Mix.Shared.Interfaces; using Mix.Shared.Models.Configurations; using Mix.SignalR.Interfaces; using System.Reflection; @@ -29,7 +30,12 @@ public static List MixAssemblies public static IServiceCollection AddMixServices(this IServiceCollection services, Assembly executingAssembly, IConfiguration configuration) { - var options = configuration.Get(); + var globalConfig = configuration.GetSection(MixAppSettingsSection.GlobalSettings) + .Get(); + services.AddOptions() + .Bind(configuration.GetSection(MixAppSettingsSection.GlobalSettings)) + .ValidateDataAnnotations(); + services.AddMvc().AddSessionStateTempDataProvider(); services.TryAddSingleton(); services.AddSession(options => @@ -49,7 +55,7 @@ public static IServiceCollection AddMixServices(this IServiceCollection services services.AddHttpClient(); services.AddLogging(); - services.ApplyMigrations(options); + services.ApplyMigrations(globalConfig); services.AddQueues(executingAssembly, configuration); @@ -74,7 +80,7 @@ public static IServiceCollection AddMixServices(this IServiceCollection services services.TryAddSingleton(); services.TryAddSingleton(); services.TryAddSingleton(); - services.AddMixRepoDb(); + services.AddMixRepoDb(globalConfig); UnitOfWorkMiddleware.AddUnitOfWork>(); return services; @@ -84,8 +90,7 @@ public static IServiceCollection AddMixServices(this IServiceCollection services public static IServiceCollection AddMixTestServices(this IServiceCollection services, Assembly executingAssembly, IConfiguration configuration) { // Clone Settings from shared folder - var options = new GlobalConfigurations(); - configuration.GetSection("GlobalConfigurations").Bind(options); + var globalConfig = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get()!; services.AddMvc().AddSessionStateTempDataProvider(); services.AddSession(); @@ -97,7 +102,7 @@ public static IServiceCollection AddMixTestServices(this IServiceCollection serv services.AddHttpClient(); services.AddLogging(); - services.ApplyMigrations(options); + services.ApplyMigrations(globalConfig); services.AddQueues(executingAssembly, configuration); @@ -119,7 +124,7 @@ public static IServiceCollection AddMixTestServices(this IServiceCollection serv services.TryAddSingleton(); services.TryAddSingleton(); - services.AddMixRepoDb(); + services.AddMixRepoDb(globalConfig); UnitOfWorkMiddleware.AddUnitOfWork>(); return services; diff --git a/src/platform/mix.library/ViewModels/MixConfigurationContentViewModel.cs b/src/platform/mix.library/ViewModels/MixConfigurationContentViewModel.cs index 59367c5c7..ad0aeffa6 100644 --- a/src/platform/mix.library/ViewModels/MixConfigurationContentViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixConfigurationContentViewModel.cs @@ -19,7 +19,7 @@ public MixConfigurationContentViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(un { } - public MixConfigurationContentViewModel(MixConfigurationContent entity, UnitOfWorkInfo uowInfo = null) + public MixConfigurationContentViewModel(MixConfigurationContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixConfigurationViewModel.cs b/src/platform/mix.library/ViewModels/MixConfigurationViewModel.cs index 41aa53dee..ab6107a09 100644 --- a/src/platform/mix.library/ViewModels/MixConfigurationViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixConfigurationViewModel.cs @@ -16,7 +16,7 @@ public MixConfigurationViewModel() { } - public MixConfigurationViewModel(MixConfiguration entity, UnitOfWorkInfo uowInfo = null) + public MixConfigurationViewModel(MixConfiguration entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixContributorViewModel.cs b/src/platform/mix.library/ViewModels/MixContributorViewModel.cs index a90df4c8a..e4d6d7968 100644 --- a/src/platform/mix.library/ViewModels/MixContributorViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixContributorViewModel.cs @@ -23,7 +23,7 @@ public MixContributorViewModel() { } - public MixContributorViewModel(MixContributor entity, UnitOfWorkInfo uowInfo = null) + public MixContributorViewModel(MixContributor entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDatabaseAssociationViewModel.cs b/src/platform/mix.library/ViewModels/MixDatabaseAssociationViewModel.cs index f520c0daa..b9e1804a4 100644 --- a/src/platform/mix.library/ViewModels/MixDatabaseAssociationViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDatabaseAssociationViewModel.cs @@ -21,7 +21,7 @@ public MixDatabaseAssociationViewModel() { } - public MixDatabaseAssociationViewModel(MixDatabaseAssociation entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseAssociationViewModel(MixDatabaseAssociation entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDatabaseColumnViewModel.cs b/src/platform/mix.library/ViewModels/MixDatabaseColumnViewModel.cs index db388a17c..21dba9b58 100644 --- a/src/platform/mix.library/ViewModels/MixDatabaseColumnViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDatabaseColumnViewModel.cs @@ -30,7 +30,7 @@ public MixDatabaseColumnViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfWo { } - public MixDatabaseColumnViewModel(MixDatabaseColumn entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseColumnViewModel(MixDatabaseColumn entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDatabaseContextViewModel.cs b/src/platform/mix.library/ViewModels/MixDatabaseContextViewModel.cs index 28d06b532..74538ae39 100644 --- a/src/platform/mix.library/ViewModels/MixDatabaseContextViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDatabaseContextViewModel.cs @@ -23,7 +23,7 @@ public MixDatabaseContextViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfW { } - public MixDatabaseContextViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseContextViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDatabaseRelationshipViewModel.cs b/src/platform/mix.library/ViewModels/MixDatabaseRelationshipViewModel.cs index 41607c7f1..52447c8f5 100644 --- a/src/platform/mix.library/ViewModels/MixDatabaseRelationshipViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDatabaseRelationshipViewModel.cs @@ -29,7 +29,7 @@ public MixDatabaseRelationshipViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(un { } - public MixDatabaseRelationshipViewModel(MixDatabaseRelationship entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseRelationshipViewModel(MixDatabaseRelationship entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDatabaseViewModel.cs b/src/platform/mix.library/ViewModels/MixDatabaseViewModel.cs index a9654f293..776a261b8 100644 --- a/src/platform/mix.library/ViewModels/MixDatabaseViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDatabaseViewModel.cs @@ -33,7 +33,7 @@ public MixDatabaseViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfWorkInfo { } - public MixDatabaseViewModel(MixDatabase entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseViewModel(MixDatabase entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixDomainViewModel.cs b/src/platform/mix.library/ViewModels/MixDomainViewModel.cs index d5aa2d112..da1c4aa79 100644 --- a/src/platform/mix.library/ViewModels/MixDomainViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixDomainViewModel.cs @@ -15,7 +15,7 @@ public MixDomainViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfWorkInfo) { } - public MixDomainViewModel(MixDomain entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixDomainViewModel(MixDomain entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixLanguageContentViewModel.cs b/src/platform/mix.library/ViewModels/MixLanguageContentViewModel.cs index 47750c717..f71384a75 100644 --- a/src/platform/mix.library/ViewModels/MixLanguageContentViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixLanguageContentViewModel.cs @@ -19,7 +19,7 @@ public MixLanguageContentViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfW { } - public MixLanguageContentViewModel(MixLanguageContent entity, UnitOfWorkInfo uowInfo = null) + public MixLanguageContentViewModel(MixLanguageContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixPageContentViewModel.cs b/src/platform/mix.library/ViewModels/MixPageContentViewModel.cs index 040d87a92..63653c334 100644 --- a/src/platform/mix.library/ViewModels/MixPageContentViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixPageContentViewModel.cs @@ -10,7 +10,7 @@ public MixPageContentViewModel() { } - public MixPageContentViewModel(MixPageContent entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixPageContentViewModel(MixPageContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixPostContentViewModel.cs b/src/platform/mix.library/ViewModels/MixPostContentViewModel.cs index ae6f48bd0..53fcf3a1f 100644 --- a/src/platform/mix.library/ViewModels/MixPostContentViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixPostContentViewModel.cs @@ -11,7 +11,7 @@ public MixPostContentViewModel() { } - public MixPostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo = null) : base(entity, uowInfo) + public MixPostContentViewModel(MixPostContent entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixPostViewModel.cs b/src/platform/mix.library/ViewModels/MixPostViewModel.cs index 115dfd6e9..f6aa39f9f 100644 --- a/src/platform/mix.library/ViewModels/MixPostViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixPostViewModel.cs @@ -9,7 +9,7 @@ public MixPostViewModel() { } - public MixPostViewModel(MixPost entity, UnitOfWorkInfo uowInfo = null) + public MixPostViewModel(MixPost entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixTemplateViewModel.cs b/src/platform/mix.library/ViewModels/MixTemplateViewModel.cs index f60b3f5a5..9ad3f85f0 100644 --- a/src/platform/mix.library/ViewModels/MixTemplateViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixTemplateViewModel.cs @@ -26,7 +26,7 @@ public MixTemplateViewModel() { } - public MixTemplateViewModel(MixTemplate entity, UnitOfWorkInfo uowInfo = null) + public MixTemplateViewModel(MixTemplate entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixThemeViewModel.cs b/src/platform/mix.library/ViewModels/MixThemeViewModel.cs index 7f3879f1e..d721dce2c 100644 --- a/src/platform/mix.library/ViewModels/MixThemeViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixThemeViewModel.cs @@ -22,7 +22,7 @@ public MixThemeViewModel() { } - public MixThemeViewModel(MixTheme entity, UnitOfWorkInfo uowInfo = null) + public MixThemeViewModel(MixTheme entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/MixUrlAliasViewModel.cs b/src/platform/mix.library/ViewModels/MixUrlAliasViewModel.cs index cf60ea581..4914d0863 100644 --- a/src/platform/mix.library/ViewModels/MixUrlAliasViewModel.cs +++ b/src/platform/mix.library/ViewModels/MixUrlAliasViewModel.cs @@ -24,7 +24,7 @@ public MixUrlAliasViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(unitOfWorkInfo { } - public MixUrlAliasViewModel(MixUrlAlias entity, UnitOfWorkInfo uowInfo = null) + public MixUrlAliasViewModel(MixUrlAlias entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.library/ViewModels/ReadOnly/MixDatabaseReadViewModel.cs b/src/platform/mix.library/ViewModels/ReadOnly/MixDatabaseReadViewModel.cs index dc97cdef0..f513b911d 100644 --- a/src/platform/mix.library/ViewModels/ReadOnly/MixDatabaseReadViewModel.cs +++ b/src/platform/mix.library/ViewModels/ReadOnly/MixDatabaseReadViewModel.cs @@ -24,7 +24,7 @@ public MixDatabaseContextReadViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(uni { } - public MixDatabaseContextReadViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseContextReadViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.log/Models/AuditLogDataModel.cs b/src/platform/mix.log/Models/AuditLogDataModel.cs index 0b419d5fc..e31a88430 100644 --- a/src/platform/mix.log/Models/AuditLogDataModel.cs +++ b/src/platform/mix.log/Models/AuditLogDataModel.cs @@ -15,11 +15,11 @@ namespace Mix.Log.Lib.Models public class AuditLogDataModel { public int StatusCode { get; set; } - public string RequestIp { get; set; } + public string? RequestIp { get; set; } public string Endpoint { get; set; } public string Method { get; set; } public string QueryString { get; set; } - public JObject Body { get; set; } + public JObject? Body { get; set; } public JObject Response { get; set; } public JObject Exception { get; set; } public string CreatedBy { get; set; } diff --git a/src/platform/mix.log/ServiceCollectionExtension.cs b/src/platform/mix.log/ServiceCollectionExtension.cs index d3c01db1c..de55d5604 100644 --- a/src/platform/mix.log/ServiceCollectionExtension.cs +++ b/src/platform/mix.log/ServiceCollectionExtension.cs @@ -2,6 +2,7 @@ using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.DependencyInjection.Extensions; +using Mix.Constant.Constants; using Mix.Database.Entities.AuditLog; using Mix.Database.Entities.Queue; using Mix.Log.Lib.Interfaces; @@ -27,7 +28,7 @@ public static class ServiceCollectionExtensions { public static IServiceCollection AddMixLog(this IServiceCollection services, IConfiguration configuration) { - var globalConfigs = configuration.Get(); + var globalConfigs = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get()!; services.AddDbContext(); services.AddDbContext(); diff --git a/src/platform/mix.quartz/ServiceCollectionExtensions.cs b/src/platform/mix.quartz/Extensions/ServiceCollectionExtensions.cs similarity index 100% rename from src/platform/mix.quartz/ServiceCollectionExtensions.cs rename to src/platform/mix.quartz/Extensions/ServiceCollectionExtensions.cs diff --git a/src/platform/mix.repodb/ServiceCollectionExtensions.cs b/src/platform/mix.repodb/ServiceCollectionExtensions.cs index 1bc59e135..48a582811 100644 --- a/src/platform/mix.repodb/ServiceCollectionExtensions.cs +++ b/src/platform/mix.repodb/ServiceCollectionExtensions.cs @@ -4,6 +4,7 @@ using Mix.RepoDb.Repositories; using Mix.RepoDb.Services; using Mix.RepoDb.Subscribers; +using Mix.Shared.Models.Configurations; using Mix.Shared.Services; using RepoDb; using RepoDb.Interfaces; @@ -12,7 +13,7 @@ namespace Microsoft.Extensions.DependencyInjection { public static class ServiceCollectionExtensions { - public static IServiceCollection AddMixRepoDb(this IServiceCollection services) + public static IServiceCollection AddMixRepoDb(this IServiceCollection services, GlobalSettingsModel globalConfig) { services.TryAddScoped(); services.TryAddScoped(); @@ -21,7 +22,7 @@ public static IServiceCollection AddMixRepoDb(this IServiceCollection services) services.AddHostedService(); services.AddHostedService(); - if (!GlobalConfigService.Instance.AppSettings.IsInit) + if (!globalConfig.IsInit && globalConfig.IsUpdateSystemDatabases) { var mixDbService = services.GetService(); mixDbService.MigrateSystemDatabases().GetAwaiter().GetResult(); diff --git a/src/platform/mix.repodb/Services/MixDbDataService.cs b/src/platform/mix.repodb/Services/MixDbDataService.cs index f73a7d667..5c4827548 100644 --- a/src/platform/mix.repodb/Services/MixDbDataService.cs +++ b/src/platform/mix.repodb/Services/MixDbDataService.cs @@ -535,7 +535,7 @@ private async Task ParseDto(string tableName, JObject dto) if (!result.ContainsKey(IdFieldName)) { - result.Add(new JProperty(IdFieldName, null)); + result.Add(new JProperty(IdFieldName, string.Empty)); if (!result.ContainsKey(CreatedDateFieldName)) { result.Add(new JProperty(CreatedDateFieldName, DateTime.UtcNow)); diff --git a/src/platform/mix.repodb/Services/MixDbService.cs b/src/platform/mix.repodb/Services/MixDbService.cs index b67e79ddd..60fb1177d 100644 --- a/src/platform/mix.repodb/Services/MixDbService.cs +++ b/src/platform/mix.repodb/Services/MixDbService.cs @@ -487,7 +487,7 @@ private Operation ParseSearchOperation(MixCompareOperator? searchMethod) public async Task MigrateDatabase(string name) { MixDatabaseViewModel database = await MixDatabaseViewModel.GetRepository(_cmsUow, CacheService).GetSingleAsync(m => m.SystemName == name); - + if (database.MixDatabaseContextId.HasValue) { await SwitchDbContext(database.MixDatabaseContextId.Value); @@ -522,56 +522,52 @@ private async Task SwitchDbContext(int dbContextId) _ => throw new NotImplementedException() }; _repository = new MixRepoDbRepository(_cache, dbContext.DatabaseProvider, dbContext.ConnectionString, _cmsUow); - + } public async Task MigrateSystemDatabases() { - if (GlobalConfigService.Instance.AppSettings.MigrateSystemDatabases) + var strMixDbs = MixFileHelper.GetFile( + "system-databases", MixFileExtensions.Json, MixFolders.JsonDataFolder); + var obj = JObject.Parse(strMixDbs.Content); + var databases = obj.Value("databases")?.ToObject>(); + var columns = obj.Value("columns")?.ToObject>(); + if (databases != null) { - - var strMixDbs = MixFileHelper.GetFile( - "system-databases", MixFileExtensions.Json, MixFolders.JsonDataFolder); - var obj = JObject.Parse(strMixDbs.Content); - var databases = obj.Value("databases")?.ToObject>(); - var columns = obj.Value("columns")?.ToObject>(); - if (databases != null) + foreach (var database in databases) { - foreach (var database in databases) + if (!await CheckTableExist(database.SystemName, _repository)) { - if (!await CheckTableExist(database.SystemName, _repository)) + MixDatabaseViewModel currentDb = await MixDatabaseViewModel.GetRepository(_cmsUow, CacheService) + .GetSingleAsync(m => m.SystemName == database.SystemName); + if (currentDb == null) { - MixDatabaseViewModel currentDb = await MixDatabaseViewModel.GetRepository(_cmsUow, CacheService) - .GetSingleAsync(m => m.SystemName == database.SystemName); - if (currentDb == null) - { - currentDb = new(database, _cmsUow); - currentDb.Id = 0; - currentDb.MixTenantId = CurrentTenant?.Id ?? 1; - currentDb.CreatedDateTime = DateTime.UtcNow; - currentDb.Columns = new(); + currentDb = new(database, _cmsUow); + currentDb.Id = 0; + currentDb.MixTenantId = CurrentTenant?.Id ?? 1; + currentDb.CreatedDateTime = DateTime.UtcNow; + currentDb.Columns = new(); - if (columns is not null) + if (columns is not null) + { + var cols = columns.Where(c => c.MixDatabaseName == database.SystemName).ToList(); + foreach (var col in cols) { - var cols = columns.Where(c => c.MixDatabaseName == database.SystemName).ToList(); - foreach (var col in cols) - { - currentDb.Columns.Add(new(col, _cmsUow)); - } + currentDb.Columns.Add(new(col, _cmsUow)); } - - await currentDb.SaveAsync(); } - if (currentDb is { Columns.Count: > 0 }) - { - await Migrate(currentDb, _databaseService.DatabaseProvider, _repository); - } + await currentDb.SaveAsync(); } - } - return true; + if (currentDb is { Columns.Count: > 0 }) + { + await Migrate(currentDb, _databaseService.DatabaseProvider, _repository); + } + } } + return true; + } return false; } diff --git a/src/platform/mix.repodb/ViewModels/MixDatabaseContextReadViewModel.cs b/src/platform/mix.repodb/ViewModels/MixDatabaseContextReadViewModel.cs index c9a3f8f62..dcd3c5528 100644 --- a/src/platform/mix.repodb/ViewModels/MixDatabaseContextReadViewModel.cs +++ b/src/platform/mix.repodb/ViewModels/MixDatabaseContextReadViewModel.cs @@ -28,7 +28,7 @@ public MixDatabaseContextReadViewModel(UnitOfWorkInfo unitOfWorkInfo) : base(uni { } - public MixDatabaseContextReadViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo = null) + public MixDatabaseContextReadViewModel(MixDatabaseContext entity, UnitOfWorkInfo uowInfo) : base(entity, uowInfo) { } diff --git a/src/platform/mix.service/Services/MixPermissionService.cs b/src/platform/mix.service/Services/MixPermissionService.cs index bf60493a4..45a4be7fb 100644 --- a/src/platform/mix.service/Services/MixPermissionService.cs +++ b/src/platform/mix.service/Services/MixPermissionService.cs @@ -4,6 +4,7 @@ using Mix.Database.Entities.Account; using Mix.Database.Entities.MixDb; using Mix.Database.Services; +using Mix.Heart.Exceptions; using Mix.Heart.UnitOfWork; using Mix.Shared.Extensions; using Mix.Shared.Services; @@ -78,6 +79,7 @@ public async Task Reload() } catch (Exception ex) { + throw new MixException(Heart.Enums.MixErrorStatus.Badrequest, ex); } finally { diff --git a/src/platform/mix.shared/Interfaces/IGlobalConfigurations.cs b/src/platform/mix.shared/Interfaces/IGlobalConfigurations.cs index 258b49a97..6390d3882 100644 --- a/src/platform/mix.shared/Interfaces/IGlobalConfigurations.cs +++ b/src/platform/mix.shared/Interfaces/IGlobalConfigurations.cs @@ -11,7 +11,7 @@ public interface IGlobalConfigurations bool IsHttps { get; set; } bool IsInit { get; set; } bool IsLogStream { get; set; } - bool MigrateSystemDatabases { get; set; } + bool IsUpdateSystemDatabases { get; set; } int ResponseCache { get; set; } } } \ No newline at end of file diff --git a/src/platform/mix.shared/Models/Configurations/GlobalConfigurations.cs b/src/platform/mix.shared/Models/Configurations/GlobalSettingsModel.cs similarity index 77% rename from src/platform/mix.shared/Models/Configurations/GlobalConfigurations.cs rename to src/platform/mix.shared/Models/Configurations/GlobalSettingsModel.cs index b6256071e..9e80b9e5f 100644 --- a/src/platform/mix.shared/Models/Configurations/GlobalConfigurations.cs +++ b/src/platform/mix.shared/Models/Configurations/GlobalSettingsModel.cs @@ -2,16 +2,17 @@ namespace Mix.Shared.Models.Configurations { - public class GlobalConfigurations : IGlobalConfigurations + public class GlobalSettingsModel : IGlobalConfigurations { public bool IsInit { get; set; } - public bool MigrateSystemDatabases { get; set; } + public bool IsUpdateSystemDatabases { get; set; } public bool EnableAuditLog { get; set; } public bool IsLogStream { get; set; } public bool AllowAnyOrigin { get; set; } public bool IsHttps { get; set; } public int ResponseCache { get; set; } public string ApiEncryptKey { get; set; } + public string AesKey { get; set; } public string DefaultDomain { get; set; } public bool EnableOcelot { get; set; } public InitStep InitStatus { get; set; } diff --git a/src/platform/mix.shared/Services/GlobalConfigService.cs b/src/platform/mix.shared/Services/GlobalConfigService.cs index 3156d6ca7..daf008ab7 100644 --- a/src/platform/mix.shared/Services/GlobalConfigService.cs +++ b/src/platform/mix.shared/Services/GlobalConfigService.cs @@ -2,7 +2,7 @@ namespace Mix.Shared.Services { - public class GlobalConfigService : ConfigurationServiceBase + public class GlobalConfigService : ConfigurationServiceBase { #region Instance @@ -37,7 +37,7 @@ public static GlobalConfigService Instance #endregion public GlobalConfigService() - : base(MixAppConfigFilePaths.Global) + : base(MixAppConfigFilePaths.Global, MixAppSettingsSection.GlobalSettings) { } public new string AesKey diff --git a/src/modules/mix.messenger/Domain/ServiceCollectionExtensions.cs b/src/platform/mix.signalr.hub/Extensions/ServiceCollectionExtensions.cs similarity index 100% rename from src/modules/mix.messenger/Domain/ServiceCollectionExtensions.cs rename to src/platform/mix.signalr.hub/Extensions/ServiceCollectionExtensions.cs diff --git a/src/platform/mix.signalr.hub/Hubs/HighFrequencyHub.cs b/src/platform/mix.signalr.hub/Hubs/HighFrequencyHub.cs index fa53ed985..9fc1227e5 100644 --- a/src/platform/mix.signalr.hub/Hubs/HighFrequencyHub.cs +++ b/src/platform/mix.signalr.hub/Hubs/HighFrequencyHub.cs @@ -19,8 +19,12 @@ public async Task UploadStream(IAsyncEnumerable stream, string room) try { var msg = JObject.Parse(message).ToObject(); - msg.From ??= GetCurrentUser(); - _ = Clients.GroupExcept(room, Context.ConnectionId).SendAsync(HubMethods.ReceiveMethod, msg.ToString()); + if (msg != null) + { + + msg.From ??= GetCurrentUser(); + _ = Clients.GroupExcept(room, Context.ConnectionId).SendAsync(HubMethods.ReceiveMethod, msg.ToString()); + } } catch (Exception ex) { diff --git a/src/platform/mix.signalr.hub/Hubs/VideoCallHub.cs b/src/platform/mix.signalr.hub/Hubs/VideoCallHub.cs index 573bbf5e3..75377379e 100644 --- a/src/platform/mix.signalr.hub/Hubs/VideoCallHub.cs +++ b/src/platform/mix.signalr.hub/Hubs/VideoCallHub.cs @@ -26,7 +26,7 @@ public VideoCallHub(IAuditLogService auditLogService, IMixTenantService mixTenan { } - public async Task Join(string username) + public override async Task Join(string username) { // Add the new user Users.Add(new User diff --git a/src/services/ecommerces/mix.services.ecommerce.lib/Entities/Mix/EntityConfigurations/OrderConfiguration.cs b/src/services/ecommerces/mix.services.ecommerce.lib/Entities/Mix/EntityConfigurations/OrderConfiguration.cs index 6df2add52..69a33f48c 100644 --- a/src/services/ecommerces/mix.services.ecommerce.lib/Entities/Mix/EntityConfigurations/OrderConfiguration.cs +++ b/src/services/ecommerces/mix.services.ecommerce.lib/Entities/Mix/EntityConfigurations/OrderConfiguration.cs @@ -26,21 +26,21 @@ public override void Configure(EntityTypeBuilder builder) builder.Property(e => e.PaymentRequest) .HasConversion( - v => v.ToString(Newtonsoft.Json.Formatting.None), + v => v != null ? v.ToString(Newtonsoft.Json.Formatting.None) : null, v => !string.IsNullOrEmpty(v) ? JObject.Parse(v) : new()) .IsRequired(false) .HasColumnType(Config.Text); builder.Property(e => e.ShippingAddress) .HasConversion( - v => v.ToString(Newtonsoft.Json.Formatting.None), + v => v != null ? v.ToString(Newtonsoft.Json.Formatting.None) : null, v => !string.IsNullOrEmpty(v) ? JObject.Parse(v) : new()) .IsRequired(false) .HasColumnType(Config.Text); - + builder.Property(e => e.PaymentResponse) .HasConversion( - v => v.ToString(Newtonsoft.Json.Formatting.None), + v => v != null ? v.ToString(Newtonsoft.Json.Formatting.None) : null, v => !string.IsNullOrEmpty(v) ? JObject.Parse(v) : new()) .IsRequired(false) .HasColumnType(Config.Text); diff --git a/src/services/ecommerces/mix.services.ecommerce.lib/Extensions/EcommerceServiceProviderExtensions.cs b/src/services/ecommerces/mix.services.ecommerce.lib/Extensions/EcommerceServiceProviderExtensions.cs index 9b7f0f86b..c72913682 100644 --- a/src/services/ecommerces/mix.services.ecommerce.lib/Extensions/EcommerceServiceProviderExtensions.cs +++ b/src/services/ecommerces/mix.services.ecommerce.lib/Extensions/EcommerceServiceProviderExtensions.cs @@ -1,11 +1,14 @@ using Microsoft.EntityFrameworkCore; +using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection.Extensions; +using Mix.Constant.Constants; using Mix.Heart.UnitOfWork; using Mix.Lib.Middlewares; using Mix.Services.Ecommerce.Lib.Entities.Mix; using Mix.Services.Ecommerce.Lib.Entities.Onepay; using Mix.Services.Ecommerce.Lib.Entities.Paypal; using Mix.Services.Ecommerce.Lib.Interfaces; +using Mix.Services.Ecommerce.Lib.Models; using Mix.Services.Ecommerce.Lib.Services; using Mix.Shared.Services; @@ -13,13 +16,17 @@ namespace Microsoft.Extensions.DependencyInjection { public static class ServiceProviderExtensions { - public static void AddMixEcommerce(this IServiceCollection services) + public static void AddMixEcommerce(this IServiceCollection services, Configuration.IConfiguration configuration) { - services.AddMixOnepay(); - services.AddMixPaypal(); - services.AddEcommerceDb(); - services.TryAddScoped(); - services.TryAddScoped(); + var paymentSettings = configuration.GetSection(MixAppSettingsSection.Payments).Get(); + if (paymentSettings != null && paymentSettings.IsActive) + { + services.AddMixOnepay(); + services.AddMixPaypal(); + services.AddEcommerceDb(); + services.TryAddScoped(); + services.TryAddScoped(); + } } public static void AddEcommerceDb(this IServiceCollection services) { @@ -43,7 +50,7 @@ public static void AddMixOnepay(this IServiceCollection services) services.TryAddScoped(); services.TryAddScoped>(); UnitOfWorkMiddleware.AddUnitOfWork>(); - + if (!GlobalConfigService.Instance.IsInit) { using (var context = services.GetService()) diff --git a/src/services/ecommerces/mix.services.ecommerce.lib/Models/Onepay/OnepayConfigurations.cs b/src/services/ecommerces/mix.services.ecommerce.lib/Models/Onepay/OnepayConfigurations.cs index b726ba23e..5338c6d9a 100644 --- a/src/services/ecommerces/mix.services.ecommerce.lib/Models/Onepay/OnepayConfigurations.cs +++ b/src/services/ecommerces/mix.services.ecommerce.lib/Models/Onepay/OnepayConfigurations.cs @@ -2,6 +2,7 @@ { public sealed class OnepayConfigurations { + public bool Enabled { get; set; } public int Version { get; set; } public string Currency { get; set; } public string PaymentEndpoint { get; set; } diff --git a/src/services/ecommerces/mix.services.ecommerce.lib/Models/PaymentUrlsConfigurationModel.cs b/src/services/ecommerces/mix.services.ecommerce.lib/Models/PaymentUrlsConfigurationModel.cs index 55976cba7..acbae890f 100644 --- a/src/services/ecommerces/mix.services.ecommerce.lib/Models/PaymentUrlsConfigurationModel.cs +++ b/src/services/ecommerces/mix.services.ecommerce.lib/Models/PaymentUrlsConfigurationModel.cs @@ -4,6 +4,7 @@ namespace Mix.Services.Ecommerce.Lib.Models { public sealed class PaymentConfigurationModel { + public bool IsActive { get; set; } public OnepayConfigurations Onepay { get; set; } public PaymentUrls Urls { get; set; } } diff --git a/src/services/ecommerces/mix.services.ecommerce/Controllers/ApiEcommerceController.cs b/src/services/ecommerces/mix.services.ecommerce/Controllers/ApiEcommerceController.cs index cbd0211cc..6c90827e1 100644 --- a/src/services/ecommerces/mix.services.ecommerce/Controllers/ApiEcommerceController.cs +++ b/src/services/ecommerces/mix.services.ecommerce/Controllers/ApiEcommerceController.cs @@ -167,8 +167,7 @@ public async Task PaymentResponse([FromQuery] int? orderId, Cancel { return BadRequest(); } - - var paymentResponse = JObject.FromObject(query.AllKeys.ToDictionary(k => k, k => query[k])); + var paymentResponse = JObject.FromObject(query.AllKeys.ToDictionary(k => k!, k => query[k])); orderId ??= paymentResponse.Value("vpc_OrderInfo"); if (!orderId.HasValue) { diff --git a/src/services/ecommerces/mix.services.ecommerce/StartupService.cs b/src/services/ecommerces/mix.services.ecommerce/StartupService.cs index 7a7fd0e9d..9ae291fe1 100644 --- a/src/services/ecommerces/mix.services.ecommerce/StartupService.cs +++ b/src/services/ecommerces/mix.services.ecommerce/StartupService.cs @@ -1,9 +1,13 @@ -using Microsoft.Extensions.DependencyInjection.Extensions; +using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.DependencyInjection.Extensions; +using Mix.Constant.Constants; using Mix.Lib.Interfaces; using Mix.Services.Databases.Lib.Interfaces; using Mix.Services.Databases.Lib.Services; using Mix.Services.Ecommerce.Lib.Interfaces; +using Mix.Services.Ecommerce.Lib.Models; using Mix.Services.Ecommerce.Lib.Services; +using Mix.Shared.Models.Configurations; namespace Mix.Services.Ecommerce { @@ -11,10 +15,15 @@ public class StartupService : IStartupService { public void AddServices(IServiceCollection services, IConfiguration configuration) { - services.AddMixEcommerce(); - services.TryAddScoped(); - services.TryAddScoped(); - services.TryAddScoped(); + var globalSettings = configuration.GetSection(MixAppSettingsSection.GlobalSettings).Get(); + + if (!globalSettings!.IsInit) + { + services.AddMixEcommerce(configuration); + services.TryAddScoped(); + services.TryAddScoped(); + services.TryAddScoped(); + } } public void UseApps(IApplicationBuilder app, IConfiguration configuration, bool isDevelop) diff --git a/src/services/graphql/mix.services.graphql.lib/DbContextExtensions.cs b/src/services/graphql/mix.services.graphql.lib/DbContextExtensions.cs index c870abf74..7a83e4b7f 100644 --- a/src/services/graphql/mix.services.graphql.lib/DbContextExtensions.cs +++ b/src/services/graphql/mix.services.graphql.lib/DbContextExtensions.cs @@ -5,8 +5,11 @@ namespace Mix.Services.Graphql.Lib { public static class DbContextExtensions { - public static IQueryable? Query(this DbContext context, string entityName) => - context.Query(context.Model.FindEntityType(entityName).ClrType); + public static IQueryable? Query(this DbContext context, string entityName) + { + var entityType = context.Model.FindEntityType(entityName)?.ClrType; + return entityType != null ? context.Query(entityType) : default; + } static readonly MethodInfo? SetMethod = typeof(DbContext).GetMethod(nameof(DbContext.Set), new Type[] { }); public static IQueryable? Query(this DbContext context, Type entityType) => (IQueryable?)SetMethod!.MakeGenericMethod(entityType).Invoke(context, null); diff --git a/src/services/mix-databases/mix.services.databases.lib/Services/MixMetadataService.cs b/src/services/mix-databases/mix.services.databases.lib/Services/MixMetadataService.cs index a35b63993..90be15f90 100644 --- a/src/services/mix-databases/mix.services.databases.lib/Services/MixMetadataService.cs +++ b/src/services/mix-databases/mix.services.databases.lib/Services/MixMetadataService.cs @@ -236,9 +236,9 @@ on metadata.Id equals association.MetadataId } } - return andQueries.Count == 0 ? orQueryIds.Distinct() - : orQueries.Count == 0 ? andQueryIds.Distinct() - : andQueryIds.Where(m => orQueryIds.Contains(m)).Distinct(); + return andQueries.Count == 0 ? orQueryIds?.Distinct() + : orQueryIds == null || orQueries.Count == 0 ? andQueryIds?.Distinct() + : andQueryIds?.Where(m => orQueryIds.Contains(m)).Distinct(); } public IQueryable? GetQueryableMetadataByContentId(int contentId, MixContentType? contentType, string metadataType) diff --git a/src/shared/MixContent/Shared/AppConfigs/endpoint.json b/src/shared/MixContent/Shared/AppConfigs/endpoint.json deleted file mode 100644 index b8457ed43..000000000 --- a/src/shared/MixContent/Shared/AppConfigs/endpoint.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "Account": "", // https://localhost:5002 - "Common": "", // https://localhost:5004 - "Portal": "", // https://localhost:5006 - "Theme": "", // https://localhost:5008 - "Mixcore": "", // - "Messenger": "", // https://localhost:5012 - "Scheduler": "", // https://localhost:5014 - "Grpc": "", // https://localhost:5016 - "Storage": "", // https://localhost:5018 - "Store": "https://store.mixcore.org", - "UniversalPortal": "https://universal.mixcore.net", - "UniversalPortalDev": "https://mix-portal-angular.vercel.app", - "LocalPortalDev": "http://localhost:4200" -} \ No newline at end of file diff --git a/src/shared/MixContent/Shared/AppConfigs/global.json b/src/shared/MixContent/Shared/AppConfigs/global.json deleted file mode 100644 index d10ed6a89..000000000 --- a/src/shared/MixContent/Shared/AppConfigs/global.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "IsInit": true, - "IsLogStream": false, - "IsEncryptApi": false, - "EnableOcelot": false, - "PortalThemeSettings": null, - "IsMaintenance": false, - "IsHttps": false, - "MaxPageSize": 100, - "ResponseCache": 5, - "InitStatus": "Blank", - "DefaultCulture": "en-us", - "Domain": "", - "ApiEncryptKey": "NElUempOSmx4QVlXRFRmSys5Z0lpZz09LERBSENTUUlZWEVNYVRJRlErc256bE9Ibmo1Z0wwcm5PRm9iMDlXSEJSM0U9", - "LastUpdateConfiguration": null -} diff --git a/src/shared/MixContent/Shared/AppConfigs/payments.json b/src/shared/MixContent/Shared/AppConfigs/payments.json deleted file mode 100644 index a729a26e9..000000000 --- a/src/shared/MixContent/Shared/AppConfigs/payments.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "Payments":{ - - } -} \ No newline at end of file