feat: include relation
This commit is contained in:
parent
9a824f3ddf
commit
5e8dd1ddad
1 changed files with 3 additions and 0 deletions
|
|
@ -732,6 +732,9 @@ export class EmployeeController extends Controller {
|
|||
@Get("{employeeId}/edit-history")
|
||||
async editHistory(@Path() employeeId: string) {
|
||||
return await prisma.employeeHistory.findMany({
|
||||
include: {
|
||||
updatedBy: true,
|
||||
},
|
||||
where: { masterId: employeeId },
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue