Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

chore: regen db types for purchaseOrders buyer columns

Gaurav Bhatt5d09b19a6ebd
diff --git a/packages/database/src/types.ts b/packages/database/src/types.ts
index 67a91d6ca1..8c023b4718 100644
--- a/packages/database/src/types.ts
+++ b/packages/database/src/types.ts
@@ -1995,180 +1995,6 @@ export type Database = {
},
]
}
- balloon: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- id: string
- inspectionDocumentId: string
- inspectionFeatureId: string
- pageNumber: number
- regionHeight: number
- regionWidth: number
- regionX: number
- regionY: number
- updatedAt: string | null
- updatedBy: string | null
- xCoordinate: number
- yCoordinate: number
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- id?: string
- inspectionDocumentId: string
- inspectionFeatureId: string
- pageNumber: number
- regionHeight: number
- regionWidth: number
- regionX: number
- regionY: number
- updatedAt?: string | null
- updatedBy?: string | null
- xCoordinate: number
- yCoordinate: number
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- id?: string
- inspectionDocumentId?: string
- inspectionFeatureId?: string
- pageNumber?: number
- regionHeight?: number
- regionWidth?: number
- regionX?: number
- regionY?: number
- updatedAt?: string | null
- updatedBy?: string | null
- xCoordinate?: number
- yCoordinate?: number
- }
- Relationships: [
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "balloon_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocument"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocuments"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_inspectionFeatureId_fkey"
- columns: ["inspectionFeatureId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionFeature"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
batchProperty: {
Row: {
companyId: string
@@ -12330,403 +12156,6 @@ export type Database = {
},
]
}
- inspectionDocument: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- defaultPageHeight: number | null
- defaultPageWidth: number | null
- drawingNumber: string | null
- fileName: string | null
- id: string
- pageCount: number | null
- partId: string
- storagePath: string | null
- updatedAt: string | null
- updatedBy: string | null
- uploadedBy: string | null
- version: number
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- defaultPageHeight?: number | null
- defaultPageWidth?: number | null
- drawingNumber?: string | null
- fileName?: string | null
- id?: string
- pageCount?: number | null
- partId: string
- storagePath?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- uploadedBy?: string | null
- version?: number
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- defaultPageHeight?: number | null
- defaultPageWidth?: number | null
- drawingNumber?: string | null
- fileName?: string | null
- id?: string
- pageCount?: number | null
- partId?: string
- storagePath?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- uploadedBy?: string | null
- version?: number
- }
- Relationships: [
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "consumables"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "item"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "materials"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "parts"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "services"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "tools"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
- inspectionFeature: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- description: string | null
- id: string
- inspectionDocumentId: string
- label: string
- nominalValue: string | null
- pageNumber: number
- toleranceMinus: string | null
- tolerancePlus: string | null
- type: Database["public"]["Enums"]["procedureStepType"]
- unit: string | null
- updatedAt: string | null
- updatedBy: string | null
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- description?: string | null
- id?: string
- inspectionDocumentId: string
- label: string
- nominalValue?: string | null
- pageNumber: number
- toleranceMinus?: string | null
- tolerancePlus?: string | null
- type?: Database["public"]["Enums"]["procedureStepType"]
- unit?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- description?: string | null
- id?: string
- inspectionDocumentId?: string
- label?: string
- nominalValue?: string | null
- pageNumber?: number
- toleranceMinus?: string | null
- tolerancePlus?: string | null
- type?: Database["public"]["Enums"]["procedureStepType"]
- unit?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- }
- Relationships: [
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionFeature_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocument"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocuments"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
integration: {
Row: {
id: string
@@ -18040,7 +17469,7 @@ export type Database = {
longitude: number | null
name: string
postalCode: string
- stateProvince: string
+ stateProvince: string | null
tags: string[] | null
timezone: string
updatedAt: string | null
@@ -18060,7 +17489,7 @@ export type Database = {
longitude?: number | null
name: string
postalCode: string
- stateProvince: string
+ stateProvince?: string | null
tags?: string[] | null
timezone: string
updatedAt?: string | null
@@ -18080,7 +17509,7 @@ export type Database = {
longitude?: number | null
name?: string
postalCode?: string
- stateProvince?: string
+ stateProvince?: string | null
tags?: string[] | null
timezone?: string
updatedAt?: string | null
@@ -38290,7 +37719,7 @@ export type Database = {
},
]
}
- searchIndex_LeWuwTjiAHb3YLLzZ4cpMt: {
+ searchIndex_NNpC4dvEPuwDGzAL82Y5fS: {
Row: {
createdAt: string
description: string | null
@@ -50553,203 +49982,6 @@ export type Database = {
},
]
}
- inspectionDocuments: {
- Row: {
- companyId: string | null
- createdAt: string | null
- createdBy: string | null
- defaultPageHeight: number | null
- defaultPageWidth: number | null
- drawingNumber: string | null
- fileName: string | null
- id: string | null
- pageCount: number | null
- partId: string | null
- partReadableId: string | null
- storagePath: string | null
- updatedAt: string | null
- updatedBy: string | null
- uploadedBy: string | null
- version: number | null
- }
- Relationships: [
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "consumables"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "item"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "materials"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "parts"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "services"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "tools"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
integrations: {
Row: {
active: boolean | null
@@ -53912,14 +53144,14 @@ export type Database = {
},
{
foreignKeyName: "partner_id_fkey"
- columns: ["supplierLocationId"]
+ columns: ["id"]
isOneToOne: false
referencedRelation: "supplierLocation"
referencedColumns: ["id"]
},
{
foreignKeyName: "partner_id_fkey"
- columns: ["id"]
+ columns: ["supplierLocationId"]
isOneToOne: false
referencedRelation: "supplierLocation"
referencedColumns: ["id"]
@@ -55430,7 +54662,13 @@ export type Database = {
}
purchaseOrders: {
Row: {
+ accountManagerEmail: string | null
+ accountManagerFullName: string | null
+ accountManagerPhone: string | null
assignee: string | null
+ assigneeEmail: string | null
+ assigneeFullName: string | null
+ assigneePhone: string | null
closedAt: string | null
closedBy: string | null
companyId: string | null
@@ -58841,21 +58079,21 @@ export type Database = {
Relationships: [
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["customerCountryCode"]
+ columns: ["shipmentCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
},
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["shipmentCountryCode"]
+ columns: ["invoiceCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
},
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["invoiceCountryCode"]
+ columns: ["customerCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
@@ -64508,20 +63746,6 @@ export type Database = {
Args: { p_item_id: string; p_receipt_id: string }
Returns: string
}
- save_inspection_document_atomic: {
- Args: {
- p_balloons?: Json
- p_company_id: string
- p_default_page_height?: number
- p_default_page_width?: number
- p_features?: Json
- p_inspection_document_id: string
- p_page_count?: number
- p_pdf_url?: string
- p_user_id: string
- }
- Returns: Json
- }
search_company_index: {
Args: {
p_company_id: string
diff --git a/packages/database/supabase/functions/lib/types.ts b/packages/database/supabase/functions/lib/types.ts
index 67a91d6ca1..8c023b4718 100644
--- a/packages/database/supabase/functions/lib/types.ts
+++ b/packages/database/supabase/functions/lib/types.ts
@@ -1995,180 +1995,6 @@ export type Database = {
},
]
}
- balloon: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- id: string
- inspectionDocumentId: string
- inspectionFeatureId: string
- pageNumber: number
- regionHeight: number
- regionWidth: number
- regionX: number
- regionY: number
- updatedAt: string | null
- updatedBy: string | null
- xCoordinate: number
- yCoordinate: number
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- id?: string
- inspectionDocumentId: string
- inspectionFeatureId: string
- pageNumber: number
- regionHeight: number
- regionWidth: number
- regionX: number
- regionY: number
- updatedAt?: string | null
- updatedBy?: string | null
- xCoordinate: number
- yCoordinate: number
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- id?: string
- inspectionDocumentId?: string
- inspectionFeatureId?: string
- pageNumber?: number
- regionHeight?: number
- regionWidth?: number
- regionX?: number
- regionY?: number
- updatedAt?: string | null
- updatedBy?: string | null
- xCoordinate?: number
- yCoordinate?: number
- }
- Relationships: [
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "balloon_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "balloon_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocument"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocuments"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_inspectionFeatureId_fkey"
- columns: ["inspectionFeatureId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionFeature"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "balloon_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
batchProperty: {
Row: {
companyId: string
@@ -12330,403 +12156,6 @@ export type Database = {
},
]
}
- inspectionDocument: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- defaultPageHeight: number | null
- defaultPageWidth: number | null
- drawingNumber: string | null
- fileName: string | null
- id: string
- pageCount: number | null
- partId: string
- storagePath: string | null
- updatedAt: string | null
- updatedBy: string | null
- uploadedBy: string | null
- version: number
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- defaultPageHeight?: number | null
- defaultPageWidth?: number | null
- drawingNumber?: string | null
- fileName?: string | null
- id?: string
- pageCount?: number | null
- partId: string
- storagePath?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- uploadedBy?: string | null
- version?: number
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- defaultPageHeight?: number | null
- defaultPageWidth?: number | null
- drawingNumber?: string | null
- fileName?: string | null
- id?: string
- pageCount?: number | null
- partId?: string
- storagePath?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- uploadedBy?: string | null
- version?: number
- }
- Relationships: [
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "consumables"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "item"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "materials"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "parts"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "services"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "tools"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
- inspectionFeature: {
- Row: {
- companyId: string
- createdAt: string
- createdBy: string
- description: string | null
- id: string
- inspectionDocumentId: string
- label: string
- nominalValue: string | null
- pageNumber: number
- toleranceMinus: string | null
- tolerancePlus: string | null
- type: Database["public"]["Enums"]["procedureStepType"]
- unit: string | null
- updatedAt: string | null
- updatedBy: string | null
- }
- Insert: {
- companyId: string
- createdAt?: string
- createdBy: string
- description?: string | null
- id?: string
- inspectionDocumentId: string
- label: string
- nominalValue?: string | null
- pageNumber: number
- toleranceMinus?: string | null
- tolerancePlus?: string | null
- type?: Database["public"]["Enums"]["procedureStepType"]
- unit?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- }
- Update: {
- companyId?: string
- createdAt?: string
- createdBy?: string
- description?: string | null
- id?: string
- inspectionDocumentId?: string
- label?: string
- nominalValue?: string | null
- pageNumber?: number
- toleranceMinus?: string | null
- tolerancePlus?: string | null
- type?: Database["public"]["Enums"]["procedureStepType"]
- unit?: string | null
- updatedAt?: string | null
- updatedBy?: string | null
- }
- Relationships: [
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionFeature_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocument"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_document_company_fkey"
- columns: ["inspectionDocumentId", "companyId"]
- isOneToOne: false
- referencedRelation: "inspectionDocuments"
- referencedColumns: ["id", "companyId"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionFeature_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
integration: {
Row: {
id: string
@@ -18040,7 +17469,7 @@ export type Database = {
longitude: number | null
name: string
postalCode: string
- stateProvince: string
+ stateProvince: string | null
tags: string[] | null
timezone: string
updatedAt: string | null
@@ -18060,7 +17489,7 @@ export type Database = {
longitude?: number | null
name: string
postalCode: string
- stateProvince: string
+ stateProvince?: string | null
tags?: string[] | null
timezone: string
updatedAt?: string | null
@@ -18080,7 +17509,7 @@ export type Database = {
longitude?: number | null
name?: string
postalCode?: string
- stateProvince?: string
+ stateProvince?: string | null
tags?: string[] | null
timezone?: string
updatedAt?: string | null
@@ -38290,7 +37719,7 @@ export type Database = {
},
]
}
- searchIndex_LeWuwTjiAHb3YLLzZ4cpMt: {
+ searchIndex_NNpC4dvEPuwDGzAL82Y5fS: {
Row: {
createdAt: string
description: string | null
@@ -50553,203 +49982,6 @@ export type Database = {
},
]
}
- inspectionDocuments: {
- Row: {
- companyId: string | null
- createdAt: string | null
- createdBy: string | null
- defaultPageHeight: number | null
- defaultPageWidth: number | null
- drawingNumber: string | null
- fileName: string | null
- id: string | null
- pageCount: number | null
- partId: string | null
- partReadableId: string | null
- storagePath: string | null
- updatedAt: string | null
- updatedBy: string | null
- uploadedBy: string | null
- version: number | null
- }
- Relationships: [
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "companies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "company"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "customFieldTables"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_companyId_fkey"
- columns: ["companyId"]
- isOneToOne: false
- referencedRelation: "integrations"
- referencedColumns: ["companyId"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_createdBy_fkey"
- columns: ["createdBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "consumables"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "item"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "materials"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "parts"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "services"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_partId_fkey"
- columns: ["partId"]
- isOneToOne: false
- referencedRelation: "tools"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_updatedBy_fkey"
- columns: ["updatedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employees"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeesAcrossCompanies"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "employeeSummary"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "user"
- referencedColumns: ["id"]
- },
- {
- foreignKeyName: "inspectionDocument_uploadedBy_fkey"
- columns: ["uploadedBy"]
- isOneToOne: false
- referencedRelation: "userDefaults"
- referencedColumns: ["userId"]
- },
- ]
- }
integrations: {
Row: {
active: boolean | null
@@ -53912,14 +53144,14 @@ export type Database = {
},
{
foreignKeyName: "partner_id_fkey"
- columns: ["supplierLocationId"]
+ columns: ["id"]
isOneToOne: false
referencedRelation: "supplierLocation"
referencedColumns: ["id"]
},
{
foreignKeyName: "partner_id_fkey"
- columns: ["id"]
+ columns: ["supplierLocationId"]
isOneToOne: false
referencedRelation: "supplierLocation"
referencedColumns: ["id"]
@@ -55430,7 +54662,13 @@ export type Database = {
}
purchaseOrders: {
Row: {
+ accountManagerEmail: string | null
+ accountManagerFullName: string | null
+ accountManagerPhone: string | null
assignee: string | null
+ assigneeEmail: string | null
+ assigneeFullName: string | null
+ assigneePhone: string | null
closedAt: string | null
closedBy: string | null
companyId: string | null
@@ -58841,21 +58079,21 @@ export type Database = {
Relationships: [
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["customerCountryCode"]
+ columns: ["shipmentCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
},
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["shipmentCountryCode"]
+ columns: ["invoiceCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
},
{
foreignKeyName: "address_countryCode_fkey"
- columns: ["invoiceCountryCode"]
+ columns: ["customerCountryCode"]
isOneToOne: false
referencedRelation: "country"
referencedColumns: ["alpha2"]
@@ -64508,20 +63746,6 @@ export type Database = {
Args: { p_item_id: string; p_receipt_id: string }
Returns: string
}
- save_inspection_document_atomic: {
- Args: {
- p_balloons?: Json
- p_company_id: string
- p_default_page_height?: number
- p_default_page_width?: number
- p_features?: Json
- p_inspection_document_id: string
- p_page_count?: number
- p_pdf_url?: string
- p_user_id: string
- }
- Returns: Json
- }
search_company_index: {
Args: {
p_company_id: string