refactor(server)*: tsconfigs (#2689)

* refactor(server): tsconfigs

* chore: dummy commit

* fix: start.sh

* chore: restore original entry scripts
This commit is contained in:
Jason Rasmussen
2023-06-08 11:01:07 -04:00
committed by GitHub
parent a2130aa6c5
commit 8ebac41318
465 changed files with 209 additions and 332 deletions
@@ -0,0 +1,11 @@
export class CreateProfileImageResponseDto {
userId!: string;
profileImagePath!: string;
}
export function mapCreateProfileImageResponse(userId: string, profileImagePath: string): CreateProfileImageResponseDto {
return {
userId: userId,
profileImagePath: profileImagePath,
};
}
@@ -0,0 +1,3 @@
export * from './create-profile-image-response.dto';
export * from './user-count-response.dto';
export * from './user-response.dto';
@@ -0,0 +1,12 @@
import { ApiProperty } from '@nestjs/swagger';
export class UserCountResponseDto {
@ApiProperty({ type: 'integer' })
userCount!: number;
}
export function mapUserCountResponse(count: number): UserCountResponseDto {
return {
userCount: count,
};
}
@@ -0,0 +1,33 @@
import { UserEntity } from '@app/infra/entities';
export class UserResponseDto {
id!: string;
email!: string;
firstName!: string;
lastName!: string;
storageLabel!: string | null;
profileImagePath!: string;
shouldChangePassword!: boolean;
isAdmin!: boolean;
createdAt!: Date;
deletedAt!: Date | null;
updatedAt!: Date;
oauthId!: string;
}
export function mapUser(entity: UserEntity): UserResponseDto {
return {
id: entity.id,
email: entity.email,
firstName: entity.firstName,
lastName: entity.lastName,
storageLabel: entity.storageLabel,
profileImagePath: entity.profileImagePath,
shouldChangePassword: entity.shouldChangePassword,
isAdmin: entity.isAdmin,
createdAt: entity.createdAt,
deletedAt: entity.deletedAt,
updatedAt: entity.updatedAt,
oauthId: entity.oauthId,
};
}