Skip to content

Comments

Add EfCore database in AuthService#6

Open
petrukhinandrew wants to merge 1 commit intomainfrom
petrukhin/auth-db
Open

Add EfCore database in AuthService#6
petrukhinandrew wants to merge 1 commit intomainfrom
petrukhin/auth-db

Conversation

@petrukhinandrew
Copy link
Collaborator

No description provided.

Comment on lines +8 to +11
public static class EFInstaller
{
public static IServiceCollection AddEFConfiguration(this IServiceCollection services, IConfiguration configuration)
{
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

предпочтительно EfInstaller и AddEfConfiguration

Comment on lines +10 to +12
public AuthDbContext(DbContextOptions<AuthDbContext> options) : base(options)
{
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

используй primary конструктор

Comment on lines +17 to +20
public void Add(InsuranceAgent agent)
{
dbContext.InsuranceAgents.Add(agent);
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

не хватает сохранения контекста

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant