60 lines
1.7 KiB
TypeScript
60 lines
1.7 KiB
TypeScript
import { Prisma } from '@prisma/client';
|
|
interface UpsertData {
|
|
postalCode: string;
|
|
city?: string | null;
|
|
province?: string | null;
|
|
centroidLat?: number | null;
|
|
centroidLng?: number | null;
|
|
}
|
|
export declare const postalCodesService: {
|
|
upsert(data: UpsertData): Promise<{
|
|
id: string;
|
|
city: string | null;
|
|
postalCode: string;
|
|
province: string | null;
|
|
lastUpdated: Date;
|
|
centroidLat: Prisma.Decimal | null;
|
|
centroidLng: Prisma.Decimal | null;
|
|
}>;
|
|
findByPostalCode(code: string): Promise<{
|
|
id: string;
|
|
city: string | null;
|
|
postalCode: string;
|
|
province: string | null;
|
|
lastUpdated: Date;
|
|
centroidLat: Prisma.Decimal | null;
|
|
centroidLng: Prisma.Decimal | null;
|
|
} | null>;
|
|
findAll(filters: {
|
|
page: number;
|
|
limit: number;
|
|
search?: string;
|
|
}): Promise<{
|
|
postalCodes: {
|
|
id: string;
|
|
city: string | null;
|
|
postalCode: string;
|
|
province: string | null;
|
|
lastUpdated: Date;
|
|
centroidLat: Prisma.Decimal | null;
|
|
centroidLng: Prisma.Decimal | null;
|
|
}[];
|
|
pagination: {
|
|
page: number;
|
|
limit: number;
|
|
total: number;
|
|
totalPages: number;
|
|
};
|
|
}>;
|
|
delete(code: string): Promise<{
|
|
id: string;
|
|
city: string | null;
|
|
postalCode: string;
|
|
province: string | null;
|
|
lastUpdated: Date;
|
|
centroidLat: Prisma.Decimal | null;
|
|
centroidLng: Prisma.Decimal | null;
|
|
}>;
|
|
};
|
|
export {};
|
|
//# sourceMappingURL=postal-codes.service.d.ts.map
|