forked from ytgov/sfa-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🚧 begin building out statistical section of application serializer.
- Loading branch information
1 parent
bd454b7
commit 3e2993b
Showing
5 changed files
with
93 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// TODO: question whether this should be in the database at all. | ||
// And if so, why is it its own table? | ||
enum Languages { | ||
ENGLISH = 1, | ||
FRENCH = 2, | ||
} | ||
|
||
export default class Language { | ||
id: number | ||
description: string | ||
isActive: boolean | ||
|
||
constructor({ | ||
id, | ||
description, | ||
isActive, | ||
}: { | ||
id: number | ||
description: string | ||
isActive: boolean | ||
}) { | ||
this.id = id | ||
this.description = description | ||
this.isActive = isActive | ||
} | ||
|
||
// not in database | ||
static readonly Types = Languages | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// TODO: question whether this should be in the database at all. | ||
// And if so, why is it its own table? | ||
enum Sexes { | ||
UNKNOWN = -1, | ||
PREFER_NOT_TO_SAY = 0, | ||
MALE = 1, | ||
FEMALE = 2, | ||
} | ||
|
||
export default class Sex { | ||
id: number | ||
description: string | ||
isActive: boolean | ||
|
||
constructor({ | ||
id, | ||
description, | ||
isActive, | ||
}: { | ||
id: number | ||
description: string | ||
isActive: boolean | ||
}) { | ||
this.id = id | ||
this.description = description | ||
this.isActive = isActive | ||
} | ||
|
||
// not in database | ||
static readonly Types = Sexes | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters