altyn
altyn
CC#
Created by altyn on 12/22/2023 in #help
ASP.NET get requests
Thanks, I will try
5 replies
CC#
Created by altyn on 12/17/2023 in #help
✅ Suggested pdf library
ty
3 replies
CC#
Created by altyn on 11/10/2023 in #help
Issues with EFCore
No description
8 replies
CC#
Created by altyn on 11/10/2023 in #help
Issues with EFCore
Inside the Dashboard.Persistence project\
8 replies
CC#
Created by altyn on 11/10/2023 in #help
Issues with EFCore
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
// Call the base OnModelCreating
base.OnModelCreating(modelBuilder);

// TODO: figure out why application from assembly doesn't work
// modelBuilder.ApplyConfigurationsFromAssembly(typeof(UserConfiguration).Assembly);
new PermissionConfiguration().Configure(modelBuilder.Entity<Permission>());
new RoleConfiguration().Configure(modelBuilder.Entity<Role>());
new UserConfiguration().Configure(modelBuilder.Entity<User>());
new LogConfiguration().Configure(modelBuilder.Entity<Log>());
}
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
// Call the base OnModelCreating
base.OnModelCreating(modelBuilder);

// TODO: figure out why application from assembly doesn't work
// modelBuilder.ApplyConfigurationsFromAssembly(typeof(UserConfiguration).Assembly);
new PermissionConfiguration().Configure(modelBuilder.Entity<Permission>());
new RoleConfiguration().Configure(modelBuilder.Entity<Role>());
new UserConfiguration().Configure(modelBuilder.Entity<User>());
new LogConfiguration().Configure(modelBuilder.Entity<Log>());
}
inside my DbContext
public class DashboardDbContext : DbContext, IDashboardDbContext
public class DashboardDbContext : DbContext, IDashboardDbContext
I also tried calling base on bottom, also doesn't work
8 replies
CC#
Created by altyn on 11/10/2023 in #help
Issues with EFCore
because when I don't do this
new PermissionConfiguration().Configure(modelBuilder.Entity<Permission>());
new RoleConfiguration().Configure(modelBuilder.Entity<Role>());
new UserConfiguration().Configure(modelBuilder.Entity<User>());
new PermissionConfiguration().Configure(modelBuilder.Entity<Permission>());
new RoleConfiguration().Configure(modelBuilder.Entity<Role>());
new UserConfiguration().Configure(modelBuilder.Entity<User>());
I get error that it can't link 2 entities to its foreign keys
8 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
public string? Foo {get;set;}
public string? Foo {get;set;}
or
public string Foo {get;set;} = string.Empty;
public string Foo {get;set;} = string.Empty;
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
you can either do
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
if you want it to go away you can either make it nullable or give it a default value (string.Empty)
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
this is just warning
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
if he deleted the event handler it will throw this error, he has 1 error my guess is this is that error
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
if so, delete that line
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
you probably dont have label1_Click anywhere defined
23 replies
CC#
Created by BrytanX on 11/10/2023 in #help
❔ Could u help me plz
it's in mexian pls translate
23 replies