From fec6812ff619fedb3228e01f9db46dbaad5e16a3 Mon Sep 17 00:00:00 2001 From: Methapon Metanipat Date: Tue, 27 Aug 2024 18:14:50 +0700 Subject: [PATCH] fix: add relation when get by id --- src/controllers/customer-branch-controller.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/controllers/customer-branch-controller.ts b/src/controllers/customer-branch-controller.ts index 2397a6c..d137400 100644 --- a/src/controllers/customer-branch-controller.ts +++ b/src/controllers/customer-branch-controller.ts @@ -203,6 +203,7 @@ export class CustomerBranchController extends Controller { async getById(@Path() branchId: string) { const record = await prisma.customerBranch.findFirst({ include: { + customer: true, province: true, district: true, subDistrict: true,