add new fields to list endpoints

This commit is contained in:
2025-02-10 15:21:23 +05:30
parent 0576329695
commit 6ae05cfe6b
3 changed files with 25 additions and 1 deletions

View File

@@ -51,7 +51,10 @@ export async function listNotifications(
$project: {
_id: 1,
pid: 1,
statusPipeline: 1,
permitNumber: 1,
permitLink: 1,
status: 1,
changes: 1,
createdAt: 1,
county: {
$let: {

View File

@@ -105,8 +105,18 @@ export async function listPermits(params: PageQueryParams, tenantId: string) {
permitDate: 1,
stage: 1,
status: 1,
link: 1,
address: 1,
recordType: 1,
description: 1,
applicationDetails: 1,
applicationInfo: 1,
applicationInfoTable: 1,
conditions: 1,
ownerDetails: 1,
parcelInfo: 1,
paymentData: 1,
inspections: 1,
county: {
$let: {
vars: { county: { $arrayElemAt: ["$countyRec", 0] } },
@@ -297,8 +307,18 @@ export async function searchPermit(params: PageQueryParams, tenantId: string) {
permitDate: 1,
stage: 1,
status: 1,
link: 1,
address: 1,
recordType: 1,
description: 1,
applicationDetails: 1,
applicationInfo: 1,
applicationInfoTable: 1,
conditions: 1,
ownerDetails: 1,
parcelInfo: 1,
paymentData: 1,
inspections: 1,
county: {
$let: {
vars: { county: { $arrayElemAt: ["$countyRec", 0] } },

View File

@@ -86,6 +86,7 @@ export async function listRts(params: PageQueryParams, tenantId: string) {
$project: {
_id: 1,
pid: 1,
documents: 1,
statusPipeline: 1,
createdAt: 1,
county: {