Add carrierName/writingCompanyName to tasks GET and PATCH API responses
This commit is contained in:
parent
e712420347
commit
36076ce90d
2 changed files with 4 additions and 2 deletions
|
|
@ -90,7 +90,7 @@ export async function PATCH(
|
||||||
data: updateData,
|
data: updateData,
|
||||||
include: {
|
include: {
|
||||||
client: { select: { id: true, name: true } },
|
client: { select: { id: true, name: true } },
|
||||||
policy: { select: { id: true, policyNumber: true, policyType: true, expirationDate: true } },
|
policy: { select: { id: true, policyNumber: true, policyType: true, expirationDate: true, carrierName: true, writingCompanyName: true } },
|
||||||
policyGroup: { select: { id: true, name: true, renewalDate: true } },
|
policyGroup: { select: { id: true, name: true, renewalDate: true } },
|
||||||
assignments: { include: { user: { select: { id: true, displayName: true, email: true } } } },
|
assignments: { include: { user: { select: { id: true, displayName: true, email: true } } } },
|
||||||
},
|
},
|
||||||
|
|
@ -109,7 +109,7 @@ export async function PATCH(
|
||||||
where: { id },
|
where: { id },
|
||||||
include: {
|
include: {
|
||||||
client: { select: { id: true, name: true } },
|
client: { select: { id: true, name: true } },
|
||||||
policy: { select: { id: true, policyNumber: true, policyType: true, expirationDate: true } },
|
policy: { select: { id: true, policyNumber: true, policyType: true, expirationDate: true, carrierName: true, writingCompanyName: true } },
|
||||||
policyGroup: { select: { id: true, name: true, renewalDate: true } },
|
policyGroup: { select: { id: true, name: true, renewalDate: true } },
|
||||||
assignments: { include: { user: { select: { id: true, displayName: true, email: true } } } },
|
assignments: { include: { user: { select: { id: true, displayName: true, email: true } } } },
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -101,6 +101,8 @@ export async function GET(request: NextRequest) {
|
||||||
policyNumber: true,
|
policyNumber: true,
|
||||||
policyType: true,
|
policyType: true,
|
||||||
expirationDate: true,
|
expirationDate: true,
|
||||||
|
carrierName: true,
|
||||||
|
writingCompanyName: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
policyGroup: {
|
policyGroup: {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue