Starts in:
2 DAYS
10 HRS
55 MIN
48 SEC
Starts in:
2 D
10 H
55 M
48 S

Activities of "Spospisil"

I have given you access to a repository for another issue I'm having while creating this sample project for you.

Hi,

Do you have a place where I can share some sample code with you so you can help me determine what the issue is that I'm getting with this?

I am asking you specific questions and you’re not answering them at all.

I’ve asked you to detail where the changes such as the interface class goes representing the data filter so that it can be added to domain classes in other tiered modules I’m referencing.

This is what the current DBContext class is for my blazor app. I have not implemented the suggested changes from your post the details them out, but I don't want to have to make this change to all my other ABP generated modules in my solution. I asked previously if those other DB contexts ( ILanguageManagementDbContext, ISystemMaintenanceDbContext, IReportQuickDesignerDbContext and ISecurityDbContext) also need these changes or if just having the [ReplaceDBContext] negates that and you have not responded directly to that question.

I also asked if you could detail what projects each of the proposed changes in your post (https://abp.io/community/articles/switching-between-organization-units-i5tokpzt) as it's not clear which projects they should go so the project compiles correctly.

Again seeing an actual example of a tiered blazor WASM solution referencing an ABP Generated Module (with it's own DBContext) being referenced by this blazor wasm project would be helpful.


namespace CFDataSystems.StructureCloud.EntityFrameworkCore;

[ConnectionStringName(StructureCloudDbProperties.HostConnectionStringName)]
[ReplaceDbContext(typeof(IIdentityProDbContext))]
[ReplaceDbContext(typeof(IIdentityDbContext))]
[ReplaceDbContext(typeof(ISaasDbContext))]
[ReplaceDbContext(typeof(ILanguageManagementDbContext))]
[ReplaceDbContext(typeof(ISystemMaintenanceDbContext))]
[ReplaceDbContext(typeof(IReportQuickDesignerDbContext))]
[ReplaceDbContext(typeof(ISecurityDbContext))]
public class StructureCloudDbContext : AbpDbContext<StructureCloudDbContext>,
    IStructureCloudDbContext,
    IIdentityProDbContext,
    IIdentityDbContext,
    ISaasDbContext,
    ILanguageManagementDbContext,
    ISystemMaintenanceDbContext,
    IReportQuickDesignerDbContext,
    ISecurityDbContext
{

    //Custom Tables
    public DbSet<TenantInformation> TenantInformation { get; set; }

    public DbSet<Screen> Screens { get; set; }

    public DbSet<UserDashboard> UserDashboards { get; set; }
    public DbSet<UserInformation> UserInformation { get; set; }
    public DbSet<UserLaunch> UserLaunch { get; set; }
    public DbSet<Template> Template { get; set; }

	//Saas Tables
	public DbSet<Tenant> Tenants { get; set; }
    public DbSet<Edition> Editions { get; set; }
    public DbSet<TenantConnectionString> TenantConnectionStrings { get; set; }

    //Itentity Tables
    public DbSet<IdentityUser> Users { get; set; }
    public DbSet<IdentityRole> Roles { get; set; }
    public DbSet<IdentityClaimType> ClaimTypes { get; set; }
    public DbSet<OrganizationUnit> OrganizationUnits { get; set; }
    public DbSet<IdentitySecurityLog> SecurityLogs { get; set; }
    public DbSet<IdentityLinkUser> LinkUsers { get; set; }
    public DbSet<IdentityUserDelegation> UserDelegations { get; }

    //Language tables
    public DbSet<Language> Languages { get; set; }
    public DbSet<LanguageText> LanguageTexts { get; set; }
    public DbSet<LocalizationResourceRecord> LocalizationResources { get; set; }
    public DbSet<LocalizationTextRecord> LocalizationTexts { get; set; }

    //System Maintenance Tables
    public DbSet<SystemMaintenance.Domain.Attributes.Attribute> Attribute { get; set; }
    public DbSet<DataView> Views { get; set; }
    public DbSet<ViewJoin> ViewJoins { get; set; }
    public DbSet<JoinField> JoinFields { get; set; }
    public DbSet<CalculatedField> CalculatedFields { get; set; }
    public DbSet<ReferencedField> ReferencedFields { get; set; }
    public DbSet<DataType> DataTypes { get; set; }
    public DbSet<DataSourceQuery> DataSourceQueries { get; set; }
    public DbSet<DataSourceHeader> DataSourceHeaders { get; set; }
    public DbSet<DataSourceDetail> DataSourceDetails { get; set; }
    public DbSet<DataSourceProcedure> DataSourceProcedures { get; set; }
    public DbSet<Application> Applications { get; set; }
    public DbSet<Procedure> Procedures { get; set; }
    public DbSet<MenuGroup> MenuGroups { get; set; }
    public DbSet<RaiqiHeader> RaiqiHeader { get; set; }
    public DbSet<RaiqiDetail> RaiqiDetails { get; set; }
    public DbSet<Parameter> Parameters { get; set; }
    public DbSet<SqlTables> SqlTables { get; set; }

    //Security Tables
    public DbSet<SecurityRole> SecurityRoles { get; set; }
    public DbSet<SecurityRoleProcedure> SecurityRoleProcedures { get; set; }
    public DbSet<UserSecurityRole> UserSecurityRoles { get; set; }
    public DbSet<SecurityRoleStructure> SecurityRolesStructure { get; set; }
    public DbSet<SecurityRoleStructureWithProcedures> SecurityRolesStructureWithProcedures { get; set; }
    public DbSet<UserPermissionView> UserPermissions { get; set; }


    public StructureCloudDbContext(DbContextOptions<StructureCloudDbContext> options)
        : base(options)
    {
    }
    protected override void OnModelCreating(ModelBuilder builder)
    {
        //base.OnModelCreating(builder);
        builder.SetMultiTenancySide(MultiTenancySides.Host);

        if (builder.IsHostDatabase())
        {
            ConfigurDatabaseSettings(builder);
        }

        builder.HasDefaultSchema("public");
        base.OnModelCreating(builder);
    }

    private void ConfigurDatabaseSettings(ModelBuilder builder)
    {
        AbpCommonDbProperties.DbTablePrefix = string.Empty;
        builder.ConfigurePermissionManagement();
        builder.ConfigureSettingManagement();
        builder.ConfigureBackgroundJobs();
        builder.ConfigureIdentityPro();
        builder.ConfigureFeatureManagement();
        builder.ConfigureLanguageManagement();
        builder.ConfigureAuditLogging();
        //PaymentDbProperties.DbTablePrefix = string.Empty;
        //builder.ConfigurePayment();
        builder.ConfigureOpenIddict();
        SaasDbProperties.DbTablePrefix = string.Empty;
        builder.ConfigureSaas();
        TextTemplateManagementDbProperties.DbTablePrefix = string.Empty;
        builder.ConfigureTextTemplateManagement();
        builder.ConfigureBlobStoring();
        builder.ConfigureGdpr();
        //builder.ConfigureCmsKit();
        //builder.ConfigureCmsKitPro();

        builder.ConfigureHostTables();
        StructureCloudDbProperties.DbSchema = "structurecloud_settings";
        builder.ConfigureSystemMaintenance();
        builder.ConfigureSecurity();

        AccountsPayableDbProperties.DbSchema = "vision";
        builder.ConfigureAccountsPayable();
        AccountsReceivableDbProperties.DbSchema = "vision";  
        builder.ConfigureAccountsReceivable();
        JobCostDbProperties.DbSchema = "vision";
        builder.ConfigureJobCost();
        WorkOrderDbProperties.DbSchema = "vision";
        builder.ConfigureWorkOrders();
        PurchaseOrderDbProperties.DbSchema = "vision";
        builder.ConfigurePurchaseOrders();

        builder.ConfigureReportQuickDesigner();

    }


}

Hi,

Also what's confusing to me is that the link you provided is not specific to a Blazor WASM project, so it's confusing to know which of the classes mentioned in the link your provided go into which project in our tiered solution structure. As a reminder we are running a Blazor WASM project hosted in the abp generated 'public' website module. If you could also demonstrate where these classes go in terms of which project.

Is it possible you can generate a sample project of how to do what I originally asked for but using a Blazor WASM project?

Hi,

Would I use the method in this link (https://abp.io/docs/latest/framework/data/entity-framework-core#replacedbcontext-attribute) to achieve my requirement of having all the other DBContext objects, across all my modules in my solution applying this new data filter?

Hi,

I appreciate this link and it contains some helpful information however, I still do not see how this would be applied to all my DBContext implementations across all my modules as I indicated in my initial message.

I'll give it a try

Yes, I am aware of how to do that, but that's not one of the questions I'm asking.

I want to be able to apply a different layout (our own layout) to all the ABP module's pages without overriding every page specifying which layout to use

Just to be clear,

  • We are using the LexptonX theme
  • I want to be able to apply a different layout (our own layout) to all the ABP module's pages without overriding everypage specifying which layout to use
  • I want to be able to apply a different layout to all my 'application' pages that is different from the layout I specify for the ABP module's pages.
Showing 11 to 20 of 208 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06