diff --git a/backend/API/Middlewares/ApiKeyValidationMiddleware.cs b/backend/API/Middlewares/ApiKeyValidationMiddleware.cs index 919132e..d95b3c5 100644 --- a/backend/API/Middlewares/ApiKeyValidationMiddleware.cs +++ b/backend/API/Middlewares/ApiKeyValidationMiddleware.cs @@ -1,42 +1,39 @@ -namespace API.Middlewares; +using Application.Endpoints; -public class ApiKeyValidationMiddleware +namespace API.Middlewares; + +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.Configuration; +using System.Threading.Tasks; + +public class ApiKeyMiddleware { - private const string APIKEYNAME = "ApiKey"; private readonly RequestDelegate _next; + private const string API_KEY_HEADER_NAME = "ApiKey"; + private readonly string _apiKey; - public ApiKeyValidationMiddleware(RequestDelegate next) + public ApiKeyMiddleware(RequestDelegate next, IConfiguration configuration) { _next = next; + _apiKey = configuration.GetValue("ApiKeySettings:ApiKey"); } public async Task InvokeAsync(HttpContext context) { - if (!context.Request.Headers.TryGetValue(APIKEYNAME, out var extractedApiKey)) + if (!context.Request.Headers.TryGetValue(API_KEY_HEADER_NAME, out var extractedApiKey)) { - context.Response.StatusCode = 401; - await context.Response.WriteAsync("API Key was not provided."); + context.Response.StatusCode = HttpStatusCodes.Unauthorized; // Unauthorized + await context.Response.WriteAsync("API Key is missing"); return; } - var appSettings = context.RequestServices.GetRequiredService(); - - var apiKey = appSettings.GetValue("ApiKey"); - - if (string.IsNullOrEmpty(apiKey)) + if (!_apiKey.Equals(extractedApiKey)) { - context.Response.StatusCode = 400; - await context.Response.WriteAsync("Unable to retrieve API key."); + context.Response.StatusCode = HttpStatusCodes.Forbidden; // Forbidden + await context.Response.WriteAsync("Invalid API Key"); return; } - if (!apiKey.Equals(extractedApiKey)) - { - context.Response.StatusCode = 401; - await context.Response.WriteAsync("Unauthorized client."); - return; - } - - await _next(context); + await _next(context); // API Key is valid, proceed to the next middleware } } \ No newline at end of file diff --git a/backend/API/Program.cs b/backend/API/Program.cs index 3902904..613c55b 100644 --- a/backend/API/Program.cs +++ b/backend/API/Program.cs @@ -51,7 +51,7 @@ app.UseAuthorization(); app.MapControllers(); // Middlewares -app.UseMiddleware(); +app.UseMiddleware(); app.UseMiddleware(); using (var scope = app.Services.CreateScope()) diff --git a/backend/API/appsettings.json b/backend/API/appsettings.json index 2942806..f2efee1 100644 --- a/backend/API/appsettings.json +++ b/backend/API/appsettings.json @@ -9,6 +9,8 @@ "HealthcareManagerDatabase": "Host=surus.db.elephantsql.com;Database=newbwuyu;Username=newbwuyu;Password=0end9Ixqo9PeTE4HVslX7_FVwruEhFf-;", "MongoDBDatabase": "mongodb+srv://andrei_cerbu:andrei_cerbu@cluster0.v80skg6.mongodb.net/?retryWrites=true&w=majority&appName=Cluster0" }, - "AllowedHosts": "*", - "ApiKey": "testapikey" + "ApiKeySettings": { + "ApiKey": "testapikey" + }, + "AllowedHosts": "*" } diff --git a/backend/API/bin/Debug/net8.0/API.dll b/backend/API/bin/Debug/net8.0/API.dll index 29e2afb..b3baeba 100644 Binary files a/backend/API/bin/Debug/net8.0/API.dll and b/backend/API/bin/Debug/net8.0/API.dll differ diff --git a/backend/API/bin/Debug/net8.0/API.exe b/backend/API/bin/Debug/net8.0/API.exe index c2a09cc..44b6d99 100644 Binary files a/backend/API/bin/Debug/net8.0/API.exe and b/backend/API/bin/Debug/net8.0/API.exe differ diff --git a/backend/API/bin/Debug/net8.0/API.pdb b/backend/API/bin/Debug/net8.0/API.pdb index 19f9461..b1245ea 100644 Binary files a/backend/API/bin/Debug/net8.0/API.pdb and b/backend/API/bin/Debug/net8.0/API.pdb differ diff --git a/backend/API/bin/Debug/net8.0/Application.dll b/backend/API/bin/Debug/net8.0/Application.dll index bed3154..dfab3d0 100644 Binary files a/backend/API/bin/Debug/net8.0/Application.dll and b/backend/API/bin/Debug/net8.0/Application.dll differ diff --git a/backend/API/bin/Debug/net8.0/Application.pdb b/backend/API/bin/Debug/net8.0/Application.pdb index 81cca86..44a5acb 100644 Binary files a/backend/API/bin/Debug/net8.0/Application.pdb and b/backend/API/bin/Debug/net8.0/Application.pdb differ diff --git a/backend/API/bin/Debug/net8.0/Infrastructure.dll b/backend/API/bin/Debug/net8.0/Infrastructure.dll index 8816b78..852a191 100644 Binary files a/backend/API/bin/Debug/net8.0/Infrastructure.dll and b/backend/API/bin/Debug/net8.0/Infrastructure.dll differ diff --git a/backend/API/bin/Debug/net8.0/Infrastructure.pdb b/backend/API/bin/Debug/net8.0/Infrastructure.pdb index e5940d7..fba4fca 100644 Binary files a/backend/API/bin/Debug/net8.0/Infrastructure.pdb and b/backend/API/bin/Debug/net8.0/Infrastructure.pdb differ diff --git a/backend/API/bin/Debug/net8.0/appsettings.json b/backend/API/bin/Debug/net8.0/appsettings.json index 2942806..f2efee1 100644 --- a/backend/API/bin/Debug/net8.0/appsettings.json +++ b/backend/API/bin/Debug/net8.0/appsettings.json @@ -9,6 +9,8 @@ "HealthcareManagerDatabase": "Host=surus.db.elephantsql.com;Database=newbwuyu;Username=newbwuyu;Password=0end9Ixqo9PeTE4HVslX7_FVwruEhFf-;", "MongoDBDatabase": "mongodb+srv://andrei_cerbu:andrei_cerbu@cluster0.v80skg6.mongodb.net/?retryWrites=true&w=majority&appName=Cluster0" }, - "AllowedHosts": "*", - "ApiKey": "testapikey" + "ApiKeySettings": { + "ApiKey": "testapikey" + }, + "AllowedHosts": "*" } diff --git a/backend/API/obj/Debug/net8.0/API.AssemblyInfo.cs b/backend/API/obj/Debug/net8.0/API.AssemblyInfo.cs index 3c6486a..3e3b283 100644 --- a/backend/API/obj/Debug/net8.0/API.AssemblyInfo.cs +++ b/backend/API/obj/Debug/net8.0/API.AssemblyInfo.cs @@ -13,7 +13,7 @@ using System.Reflection; [assembly: System.Reflection.AssemblyCompanyAttribute("API")] [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] -[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+2ccec617a59a712428e67340dc46bebefb152aca")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+b48d5ee19e5228d9bcb979f2140f996fe7a12723")] [assembly: System.Reflection.AssemblyProductAttribute("API")] [assembly: System.Reflection.AssemblyTitleAttribute("API")] [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] diff --git a/backend/API/obj/Debug/net8.0/API.AssemblyInfoInputs.cache b/backend/API/obj/Debug/net8.0/API.AssemblyInfoInputs.cache index 66961bc..7d5b8c0 100644 --- a/backend/API/obj/Debug/net8.0/API.AssemblyInfoInputs.cache +++ b/backend/API/obj/Debug/net8.0/API.AssemblyInfoInputs.cache @@ -1 +1 @@ -abd09d11442616a05d74c5cf91eb2ab3a3f4e18f9d1feb34f7d619b58a9ee139 +2a4e1c7096998582acfb9acc87d23cdf43dae534213aaa9d36839c4312b69e45 diff --git a/backend/API/obj/Debug/net8.0/API.csproj.AssemblyReference.cache b/backend/API/obj/Debug/net8.0/API.csproj.AssemblyReference.cache index a37112e..7460a14 100644 Binary files a/backend/API/obj/Debug/net8.0/API.csproj.AssemblyReference.cache and b/backend/API/obj/Debug/net8.0/API.csproj.AssemblyReference.cache differ diff --git a/backend/API/obj/Debug/net8.0/API.dll b/backend/API/obj/Debug/net8.0/API.dll index 29e2afb..b3baeba 100644 Binary files a/backend/API/obj/Debug/net8.0/API.dll and b/backend/API/obj/Debug/net8.0/API.dll differ diff --git a/backend/API/obj/Debug/net8.0/API.pdb b/backend/API/obj/Debug/net8.0/API.pdb index 19f9461..b1245ea 100644 Binary files a/backend/API/obj/Debug/net8.0/API.pdb and b/backend/API/obj/Debug/net8.0/API.pdb differ diff --git a/backend/API/obj/Debug/net8.0/API.sourcelink.json b/backend/API/obj/Debug/net8.0/API.sourcelink.json index e351cc3..78afa33 100644 --- a/backend/API/obj/Debug/net8.0/API.sourcelink.json +++ b/backend/API/obj/Debug/net8.0/API.sourcelink.json @@ -1 +1 @@ -{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/2ccec617a59a712428e67340dc46bebefb152aca/*"}} \ No newline at end of file +{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/b48d5ee19e5228d9bcb979f2140f996fe7a12723/*"}} \ No newline at end of file diff --git a/backend/API/obj/Debug/net8.0/apphost.exe b/backend/API/obj/Debug/net8.0/apphost.exe index c2a09cc..44b6d99 100644 Binary files a/backend/API/obj/Debug/net8.0/apphost.exe and b/backend/API/obj/Debug/net8.0/apphost.exe differ diff --git a/backend/API/obj/Debug/net8.0/ref/API.dll b/backend/API/obj/Debug/net8.0/ref/API.dll index b03f898..0065d2b 100644 Binary files a/backend/API/obj/Debug/net8.0/ref/API.dll and b/backend/API/obj/Debug/net8.0/ref/API.dll differ diff --git a/backend/API/obj/Debug/net8.0/refint/API.dll b/backend/API/obj/Debug/net8.0/refint/API.dll index b03f898..0065d2b 100644 Binary files a/backend/API/obj/Debug/net8.0/refint/API.dll and b/backend/API/obj/Debug/net8.0/refint/API.dll differ diff --git a/backend/Application/Endpoints/MedicalHistories/MedicalHistoryAuthorisationModel.cs b/backend/Application/Endpoints/MedicalHistories/MedicalHistoryAuthorisationModel.cs new file mode 100644 index 0000000..e13c31d --- /dev/null +++ b/backend/Application/Endpoints/MedicalHistories/MedicalHistoryAuthorisationModel.cs @@ -0,0 +1,7 @@ +namespace Application.Endpoints.MedicalHistories; + +public class MedicalHistoryAuthorisationModel +{ + public Guid Id { get; set; } + public List Authorisation { get; set; } = new List(); +} \ No newline at end of file diff --git a/backend/Application/Endpoints/MedicalHistories/MedicalHistoryHandler.cs b/backend/Application/Endpoints/MedicalHistories/MedicalHistoryHandler.cs index b20070d..db6181b 100644 --- a/backend/Application/Endpoints/MedicalHistories/MedicalHistoryHandler.cs +++ b/backend/Application/Endpoints/MedicalHistories/MedicalHistoryHandler.cs @@ -84,6 +84,15 @@ public class MedicalHistoryHandler //TODO add to MongoDB + var medicalHistoryId = medicalHistory.Id; + var newMedicalHistory = new MedicalHistoryAuthorisationModel + { + Id = medicalHistoryId, + Authorisation = new List() + }; + + await _mongoDbService.AddAsync("MedicalHistory", newMedicalHistory); + return new BaseResponse { StatusCode = HttpStatusCodes.Created, diff --git a/backend/Application/Endpoints/Patients/Registration/PatientRegistrationValidation.cs b/backend/Application/Endpoints/Patients/Registration/PatientRegistrationValidation.cs index cc625aa..f05ce5c 100644 --- a/backend/Application/Endpoints/Patients/Registration/PatientRegistrationValidation.cs +++ b/backend/Application/Endpoints/Patients/Registration/PatientRegistrationValidation.cs @@ -14,16 +14,19 @@ public class PatientRegistrationValidation : AbstractValidator x.Email) .NotEmpty().WithMessage("Email is required.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()) .EmailAddress().WithMessage("Invalid email format.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()) - .MustAsync(BeUniqueEmail).WithMessage("Email already exists.").WithErrorCode(HttpStatusCodes.Conflict.ToString()); - + .MustAsync(BeUniqueEmail).WithMessage("Email already exists.") + .WithErrorCode(HttpStatusCodes.Conflict.ToString()); + RuleFor(x => x.Password) .NotEmpty().WithMessage("Password is required.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()) - .MinimumLength(8).WithMessage("Password must be at least 8 characters long.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()); + .MinimumLength(8).WithMessage("Password must be at least 8 characters long.") + .WithErrorCode(HttpStatusCodes.BadRequest.ToString()); RuleFor(x => x.Name) .NotEmpty().WithMessage("Name is required.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()) - .MinimumLength(3).WithMessage("Name must be at least 3 characters long.").WithErrorCode(HttpStatusCodes.BadRequest.ToString()); + .MinimumLength(3).WithMessage("Name must be at least 3 characters long.") + .WithErrorCode(HttpStatusCodes.BadRequest.ToString()); } private async Task BeUniqueEmail(string email, CancellationToken cancellationToken) diff --git a/backend/Application/bin/Debug/net8.0/Application.dll b/backend/Application/bin/Debug/net8.0/Application.dll index bed3154..dfab3d0 100644 Binary files a/backend/Application/bin/Debug/net8.0/Application.dll and b/backend/Application/bin/Debug/net8.0/Application.dll differ diff --git a/backend/Application/bin/Debug/net8.0/Application.pdb b/backend/Application/bin/Debug/net8.0/Application.pdb index 81cca86..44a5acb 100644 Binary files a/backend/Application/bin/Debug/net8.0/Application.pdb and b/backend/Application/bin/Debug/net8.0/Application.pdb differ diff --git a/backend/Application/obj/Debug/net8.0/Application.AssemblyInfo.cs b/backend/Application/obj/Debug/net8.0/Application.AssemblyInfo.cs index 94d1c06..454a24f 100644 --- a/backend/Application/obj/Debug/net8.0/Application.AssemblyInfo.cs +++ b/backend/Application/obj/Debug/net8.0/Application.AssemblyInfo.cs @@ -13,7 +13,7 @@ using System.Reflection; [assembly: System.Reflection.AssemblyCompanyAttribute("Application")] [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] -[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+2ccec617a59a712428e67340dc46bebefb152aca")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+b48d5ee19e5228d9bcb979f2140f996fe7a12723")] [assembly: System.Reflection.AssemblyProductAttribute("Application")] [assembly: System.Reflection.AssemblyTitleAttribute("Application")] [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] diff --git a/backend/Application/obj/Debug/net8.0/Application.AssemblyInfoInputs.cache b/backend/Application/obj/Debug/net8.0/Application.AssemblyInfoInputs.cache index 457bd1f..b15c5dc 100644 --- a/backend/Application/obj/Debug/net8.0/Application.AssemblyInfoInputs.cache +++ b/backend/Application/obj/Debug/net8.0/Application.AssemblyInfoInputs.cache @@ -1 +1 @@ -43c727b13400f8e89ac74c76384ddd37b5c5e6f7a0de4c00bfcc4bc65f5d856d +e01bb5cb416ac609d6eb58b4e5e6dea85ea3572d0845400409f93dd3761941e3 diff --git a/backend/Application/obj/Debug/net8.0/Application.csproj.CoreCompileInputs.cache b/backend/Application/obj/Debug/net8.0/Application.csproj.CoreCompileInputs.cache index cc003b2..fba9cb9 100644 --- a/backend/Application/obj/Debug/net8.0/Application.csproj.CoreCompileInputs.cache +++ b/backend/Application/obj/Debug/net8.0/Application.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -a687c08ad227adac30cf205db23b335cafe12531e9fb53842e695d4fe5f9879a +747e745a68129206db481649de2eb8593ffa6704b63c0c2bd731c9a83a9d670a diff --git a/backend/Application/obj/Debug/net8.0/Application.dll b/backend/Application/obj/Debug/net8.0/Application.dll index bed3154..dfab3d0 100644 Binary files a/backend/Application/obj/Debug/net8.0/Application.dll and b/backend/Application/obj/Debug/net8.0/Application.dll differ diff --git a/backend/Application/obj/Debug/net8.0/Application.pdb b/backend/Application/obj/Debug/net8.0/Application.pdb index 81cca86..44a5acb 100644 Binary files a/backend/Application/obj/Debug/net8.0/Application.pdb and b/backend/Application/obj/Debug/net8.0/Application.pdb differ diff --git a/backend/Application/obj/Debug/net8.0/Application.sourcelink.json b/backend/Application/obj/Debug/net8.0/Application.sourcelink.json index e351cc3..78afa33 100644 --- a/backend/Application/obj/Debug/net8.0/Application.sourcelink.json +++ b/backend/Application/obj/Debug/net8.0/Application.sourcelink.json @@ -1 +1 @@ -{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/2ccec617a59a712428e67340dc46bebefb152aca/*"}} \ No newline at end of file +{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/b48d5ee19e5228d9bcb979f2140f996fe7a12723/*"}} \ No newline at end of file diff --git a/backend/Application/obj/Debug/net8.0/ref/Application.dll b/backend/Application/obj/Debug/net8.0/ref/Application.dll index df0cc13..6ed7e90 100644 Binary files a/backend/Application/obj/Debug/net8.0/ref/Application.dll and b/backend/Application/obj/Debug/net8.0/ref/Application.dll differ diff --git a/backend/Application/obj/Debug/net8.0/refint/Application.dll b/backend/Application/obj/Debug/net8.0/refint/Application.dll index df0cc13..6ed7e90 100644 Binary files a/backend/Application/obj/Debug/net8.0/refint/Application.dll and b/backend/Application/obj/Debug/net8.0/refint/Application.dll differ diff --git a/backend/Infrastructure/HealthcareManagerDatabase.cs b/backend/Infrastructure/HealthcareManagerDatabase.cs index 938a9e1..7330fa4 100644 --- a/backend/Infrastructure/HealthcareManagerDatabase.cs +++ b/backend/Infrastructure/HealthcareManagerDatabase.cs @@ -9,7 +9,7 @@ public class HealthcareManagerDatabase : DbContext { } - public DbSet Pacients { get; set; } + public DbSet Patients { get; set; } public DbSet MedicalHistories { get; set; } public DbSet Doctors { get; set; } diff --git a/backend/Infrastructure/Migrations/20240404131625_InitialCreate.cs b/backend/Infrastructure/Migrations/20240404131625_InitialCreate.cs index 2219d83..7b9be87 100644 --- a/backend/Infrastructure/Migrations/20240404131625_InitialCreate.cs +++ b/backend/Infrastructure/Migrations/20240404131625_InitialCreate.cs @@ -32,7 +32,7 @@ namespace Infrastructure.Migrations { Id = table.Column(type: "uuid", nullable: false), UserId = table.Column(type: "uuid", nullable: false), - Description = table.Column(type: "bytea", nullable: false) + Content = table.Column(type: "bytea", nullable: false) }, constraints: table => { @@ -40,7 +40,7 @@ namespace Infrastructure.Migrations }); migrationBuilder.CreateTable( - name: "Pacients", + name: "Patients", columns: table => new { Id = table.Column(type: "uuid", nullable: false), @@ -64,7 +64,7 @@ namespace Infrastructure.Migrations name: "MedicalHistories"); migrationBuilder.DropTable( - name: "Pacients"); + name: "Patients"); } } } diff --git a/backend/Infrastructure/Migrations/HealthcareManagerContextModelSnapshot.cs b/backend/Infrastructure/Migrations/HealthcareManagerContextModelSnapshot.cs index 66825ca..8c9e1af 100644 --- a/backend/Infrastructure/Migrations/HealthcareManagerContextModelSnapshot.cs +++ b/backend/Infrastructure/Migrations/HealthcareManagerContextModelSnapshot.cs @@ -51,7 +51,7 @@ namespace Infrastructure.Migrations .ValueGeneratedOnAdd() .HasColumnType("uuid"); - b.Property("Description") + b.Property("Content") .IsRequired() .HasColumnType("bytea"); @@ -63,7 +63,7 @@ namespace Infrastructure.Migrations b.ToTable("MedicalHistories"); }); - modelBuilder.Entity("Core.Entities.Pacient", b => + modelBuilder.Entity("Core.Entities.Patient", b => { b.Property("Id") .ValueGeneratedOnAdd() @@ -80,7 +80,7 @@ namespace Infrastructure.Migrations b.HasKey("Id"); - b.ToTable("Pacients"); + b.ToTable("Patients"); }); #pragma warning restore 612, 618 } diff --git a/backend/Infrastructure/Services/MongoDB/MongoDBServices.cs b/backend/Infrastructure/Services/MongoDB/MongoDBServices.cs index 633f2b9..6f89dfc 100644 --- a/backend/Infrastructure/Services/MongoDB/MongoDBServices.cs +++ b/backend/Infrastructure/Services/MongoDB/MongoDBServices.cs @@ -1,4 +1,5 @@ using Application.Services.Database; +using MongoDB.Bson; using MongoDB.Driver; namespace Infrastructure.Services.MongoDB; @@ -9,9 +10,16 @@ public class MongoDbService : IMongoDbService public MongoDbService(string connectionString) { - var url = new MongoUrl(connectionString); - var client = new MongoClient(url); - _database = client.GetDatabase(url.DatabaseName); + var settings = MongoClientSettings.FromConnectionString(connectionString); + settings.ServerApi = new ServerApi(ServerApiVersion.V1); + var _database = new MongoClient(settings); + + try { + var result = _database.GetDatabase("admin").RunCommand(new BsonDocument("ping", 1)); + Console.WriteLine("Pinged your deployment. You successfully connected to MongoDB!"); + } catch (Exception ex) { + Console.WriteLine(ex); + } } public IMongoCollection GetCollection(string collectionName) diff --git a/backend/Infrastructure/Services/PostgreSQL/PatientRepository.cs b/backend/Infrastructure/Services/PostgreSQL/PatientRepository.cs index b6c0bed..5b606ca 100644 --- a/backend/Infrastructure/Services/PostgreSQL/PatientRepository.cs +++ b/backend/Infrastructure/Services/PostgreSQL/PatientRepository.cs @@ -10,6 +10,6 @@ public class PatientRepository(HealthcareManagerDatabase context) { public async Task FindByEmailAsync(string email) { - return await _context.Pacients.FirstOrDefaultAsync(d => d.Email == email); + return await _context.Patients.FirstOrDefaultAsync(d => d.Email == email); } } \ No newline at end of file diff --git a/backend/Infrastructure/bin/Debug/net8.0/Application.dll b/backend/Infrastructure/bin/Debug/net8.0/Application.dll index bed3154..dfab3d0 100644 Binary files a/backend/Infrastructure/bin/Debug/net8.0/Application.dll and b/backend/Infrastructure/bin/Debug/net8.0/Application.dll differ diff --git a/backend/Infrastructure/bin/Debug/net8.0/Application.pdb b/backend/Infrastructure/bin/Debug/net8.0/Application.pdb index 81cca86..44a5acb 100644 Binary files a/backend/Infrastructure/bin/Debug/net8.0/Application.pdb and b/backend/Infrastructure/bin/Debug/net8.0/Application.pdb differ diff --git a/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.dll b/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.dll index 8816b78..852a191 100644 Binary files a/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.dll and b/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.dll differ diff --git a/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.pdb b/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.pdb index e5940d7..fba4fca 100644 Binary files a/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.pdb and b/backend/Infrastructure/bin/Debug/net8.0/Infrastructure.pdb differ diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfo.cs b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfo.cs index 03ef75b..def11b8 100644 --- a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfo.cs +++ b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfo.cs @@ -13,7 +13,7 @@ using System.Reflection; [assembly: System.Reflection.AssemblyCompanyAttribute("Infrastructure")] [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] -[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+2ccec617a59a712428e67340dc46bebefb152aca")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+b48d5ee19e5228d9bcb979f2140f996fe7a12723")] [assembly: System.Reflection.AssemblyProductAttribute("Infrastructure")] [assembly: System.Reflection.AssemblyTitleAttribute("Infrastructure")] [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfoInputs.cache b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfoInputs.cache index e24041d..1d89c38 100644 --- a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfoInputs.cache +++ b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.AssemblyInfoInputs.cache @@ -1 +1 @@ -5c68101bdd997137e1cd8f3c58cb6d9e9b9d203289c90b0f6dca8b08cc72b5c9 +1eff5085180ba5a7e0c455493bf156ab7c10e42899382b41bdf7799d2b2ca6d6 diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.csproj.AssemblyReference.cache b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.csproj.AssemblyReference.cache index 22bb3db..972d114 100644 Binary files a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.csproj.AssemblyReference.cache and b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.csproj.AssemblyReference.cache differ diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.dll b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.dll index 8816b78..852a191 100644 Binary files a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.dll and b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.dll differ diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.pdb b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.pdb index e5940d7..fba4fca 100644 Binary files a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.pdb and b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.pdb differ diff --git a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.sourcelink.json b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.sourcelink.json index e351cc3..78afa33 100644 --- a/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.sourcelink.json +++ b/backend/Infrastructure/obj/Debug/net8.0/Infrastructure.sourcelink.json @@ -1 +1 @@ -{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/2ccec617a59a712428e67340dc46bebefb152aca/*"}} \ No newline at end of file +{"documents":{"C:\\Users\\Andrei Cerbu\\Documents\\FACULTATE\\CC-FinalProj\\*":"https://raw.githubusercontent.com/andrei-mihnea-cerbu/CC-FinalProj/b48d5ee19e5228d9bcb979f2140f996fe7a12723/*"}} \ No newline at end of file diff --git a/backend/Infrastructure/obj/Debug/net8.0/ref/Infrastructure.dll b/backend/Infrastructure/obj/Debug/net8.0/ref/Infrastructure.dll index 3a85117..47925d7 100644 Binary files a/backend/Infrastructure/obj/Debug/net8.0/ref/Infrastructure.dll and b/backend/Infrastructure/obj/Debug/net8.0/ref/Infrastructure.dll differ diff --git a/backend/Infrastructure/obj/Debug/net8.0/refint/Infrastructure.dll b/backend/Infrastructure/obj/Debug/net8.0/refint/Infrastructure.dll index 3a85117..47925d7 100644 Binary files a/backend/Infrastructure/obj/Debug/net8.0/refint/Infrastructure.dll and b/backend/Infrastructure/obj/Debug/net8.0/refint/Infrastructure.dll differ