-
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.
- Loading branch information
1 parent
d2c760d
commit ab1ba8f
Showing
1 changed file
with
86 additions
and
0 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,86 @@ | ||
|
||
entity User { | ||
name String, | ||
password String, | ||
} | ||
|
||
entity Role { | ||
name Role | ||
} | ||
|
||
/** | ||
* The Employee entity. | ||
*/ | ||
entity Employee { | ||
firstName String, | ||
lastName String, | ||
email String, | ||
hireDate Instant | ||
} | ||
|
||
entity Congee { | ||
date Instant | ||
} | ||
|
||
|
||
entity Department { | ||
departmentName String required | ||
} | ||
|
||
|
||
|
||
entity JobHistory { | ||
startDate Instant, | ||
endDate Instant, | ||
language Language | ||
} | ||
|
||
enum Role { | ||
USER, DRH, DG, DGA | ||
} | ||
|
||
relationship OneToOne { | ||
User{employee} to Employee | ||
} | ||
|
||
relationship OneToOne { | ||
User{role} to Role | ||
} | ||
|
||
relationship OneToOne { | ||
Employee{department} to Department | ||
} | ||
|
||
relationship OneToMany { | ||
Department{employees} to Employee | ||
} | ||
|
||
|
||
|
||
// defining multiple OneToMany relationships with comments | ||
relationship OneToMany { | ||
Employee{job} to Job, | ||
/** | ||
* A relationship | ||
*/ | ||
Department{employee} to | ||
/** | ||
* Another side of the same relationship | ||
*/ | ||
Employee | ||
} | ||
|
||
relationship ManyToOne { | ||
Employee{manager} to Employee | ||
} | ||
|
||
|
||
// Set pagination options | ||
// paginate JobHistory, Employee with infinite-scroll | ||
// paginate Job with pagination | ||
dto * with mapstruct | ||
|
||
// Set service options to all except few | ||
service all with serviceImpl except Employee, Job | ||
// Set an angular suffix | ||
angularSuffix * with mySuffix |