aboutsummaryrefslogtreecommitdiff
path: root/API/Database
diff options
context:
space:
mode:
authortranstrike <transtrike@gmail.com>2020-12-08 18:50:47 +0200
committertranstrike <transtrike@gmail.com>2020-12-08 18:50:47 +0200
commitce4e06a235efda69c72d34815863d0b367577301 (patch)
treeb546ded8c948798abbe095b6c7a1bae4794ce952 /API/Database
parentab0430b95cc440ed671beaf642c5749862e3b6b4 (diff)
downloadDevHive-ce4e06a235efda69c72d34815863d0b367577301.tar
DevHive-ce4e06a235efda69c72d34815863d0b367577301.tar.gz
DevHive-ce4e06a235efda69c72d34815863d0b367577301.zip
Added Authen, Author & Config in Startup. Fixed User class
Diffstat (limited to 'API/Database')
-rw-r--r--API/Database/DbRepository.cs4
-rw-r--r--API/Database/DevHiveContext.cs8
2 files changed, 8 insertions, 4 deletions
diff --git a/API/Database/DbRepository.cs b/API/Database/DbRepository.cs
new file mode 100644
index 0000000..a166682
--- /dev/null
+++ b/API/Database/DbRepository.cs
@@ -0,0 +1,4 @@
+namespace API.Database
+{
+
+} \ No newline at end of file
diff --git a/API/Database/DevHiveContext.cs b/API/Database/DevHiveContext.cs
index 6f2a20c..6db137a 100644
--- a/API/Database/DevHiveContext.cs
+++ b/API/Database/DevHiveContext.cs
@@ -4,9 +4,9 @@ using Models.Classes;
using Microsoft.AspNetCore.Identity.EntityFrameworkCore;
using Microsoft.AspNetCore.Identity;
-namespace Database
+namespace API.Database
{
- public class DevHiveContext : IdentityDbContext<User<int>, IdentityRole<int>, int>
+ public class DevHiveContext : IdentityDbContext<User, IdentityRole<int>, int>
{
public DevHiveContext(DbContextOptions options)
: base(options) { }
@@ -16,8 +16,8 @@ namespace Database
protected override void OnModelCreating(ModelBuilder builder)
{
- // builder.Entity<User>()
- // .HasKey(x => x.Id);
+ builder.Entity<User>()
+ .HasKey(x => x.Id);
base.OnModelCreating(builder);
}