This commit is contained in:
2025-12-16 11:52:26 +01:00
parent ce82b7822b
commit 9a891ac8b3
586 changed files with 1320 additions and 1563 deletions

View File

@@ -4,7 +4,7 @@
* In-memory implementation of IAchievementRepository
*/
import { Logger } from '@gridpilot/core/shared/application';
import { Logger } from '@core/shared/application';
import {
Achievement,
AchievementCategory,

View File

@@ -1,11 +1,11 @@
import { IAuthRepository } from '@gridpilot/core/identity/domain/repositories/IAuthRepository';
import { IUserRepository, StoredUser } from '@gridpilot/core/identity/domain/repositories/IUserRepository';
import { IPasswordHashingService } from '@gridpilot/core/identity/domain/services/PasswordHashingService';
import { User } from '@gridpilot/core/identity/domain/entities/User';
import { IAuthRepository } from '@core/identity/domain/repositories/IAuthRepository';
import { IUserRepository, StoredUser } from '@core/identity/domain/repositories/IUserRepository';
import { IPasswordHashingService } from '@core/identity/domain/services/PasswordHashingService';
import { User } from '@core/identity/domain/entities/User';
import { EmailAddress } from '@gridpilot/core/identity/domain/value-objects/EmailAddress';
import { EmailAddress } from '@core/identity/domain/value-objects/EmailAddress';
import { randomUUID } from 'crypto';
import { Logger } from '@gridpilot/core/shared/application';
import { Logger } from '@core/shared/application';
export class InMemoryAuthRepository implements IAuthRepository {
constructor(

View File

@@ -7,7 +7,7 @@
import type { ISponsorAccountRepository } from '../../domain/repositories/ISponsorAccountRepository';
import type { SponsorAccount } from '../../domain/entities/SponsorAccount';
import type { UserId } from '../../domain/value-objects/UserId';
import { Logger } from '@gridpilot/core/shared/application';
import { Logger } from '@core/shared/application';
export class InMemorySponsorAccountRepository implements ISponsorAccountRepository {
private accounts: Map<string, SponsorAccount> = new Map();

View File

@@ -6,7 +6,7 @@
import { UserRating } from '../../domain/value-objects/UserRating';
import type { IUserRatingRepository } from '../../domain/repositories/IUserRatingRepository';
import { Logger } from '@gridpilot/core/shared/application';
import { Logger } from '@core/shared/application';
export class InMemoryUserRatingRepository implements IUserRatingRepository {
private ratings: Map<string, UserRating> = new Map();

View File

@@ -4,7 +4,7 @@
* Stores users in memory for demo/development purposes.
*/
import { Logger } from '@gridpilot/core/shared/application';
import { Logger } from '@core/shared/application';
import type { IUserRepository, StoredUser } from '../../domain/repositories/IUserRepository';
export class InMemoryUserRepository implements IUserRepository {

View File

@@ -5,7 +5,7 @@
* NOT FOR PRODUCTION USE - uses a simple string reversal as "hashing".
*/
import type { IPasswordHashingService } from '@gridpilot/core/identity/domain/services/PasswordHashingService';
import type { IPasswordHashingService } from '@core/identity/domain/services/PasswordHashingService';
export class InMemoryPasswordHashingService implements IPasswordHashingService {
async hash(plain: string): Promise<string> {

View File

@@ -4,10 +4,10 @@
* Manages user session using cookies. This is a placeholder implementation.
*/
import type { AuthenticatedUserDTO } from '@gridpilot/core/identity/application/dto/AuthenticatedUserDTO';
import type { AuthSessionDTO } from '@gridpilot/core/identity/application/dto/AuthSessionDTO';
import type { IdentitySessionPort } from '@gridpilot/core/identity/application/ports/IdentitySessionPort';
import { Logger } from '@gridpilot/core/shared/application';
import type { AuthenticatedUserDTO } from '@core/identity/application/dto/AuthenticatedUserDTO';
import type { AuthSessionDTO } from '@core/identity/application/dto/AuthSessionDTO';
import type { IdentitySessionPort } from '@core/identity/application/ports/IdentitySessionPort';
import { Logger } from '@core/shared/application';
export class CookieIdentitySessionAdapter implements IdentitySessionPort {
private currentSession: AuthSessionDTO | null = null;