From a167ef4a168ea516c01e35563ed35a4d072f46d3 Mon Sep 17 00:00:00 2001 From: Dan Gowans Date: Thu, 24 Apr 2025 09:24:25 -0400 Subject: [PATCH] rename types files --- bin/www.ts | 2 +- cypress/e2e/01-admin/feeManagement.cy.ts | 2 +- cypress/e2e/02-update/cemeteries.cy.ts | 2 +- data/config.base.d.ts | 2 +- data/config.base.ts | 2 +- data/config.baseOntario.d.ts | 2 +- data/config.baseSsm.d.ts | 2 +- data/config.baseSsm.ts | 2 +- data/config.defaultValues.d.ts | 2 +- data/config.defaultValues.ts | 2 +- data/config.testing.d.ts | 2 +- data/config.testing.ts | 2 +- database/addContractFee.ts | 2 +- database/copyContract.ts | 2 +- database/getBurialSite.d.ts | 2 +- database/getBurialSite.ts | 2 +- database/getBurialSiteComments.d.ts | 2 +- database/getBurialSiteComments.ts | 2 +- database/getBurialSiteFields.d.ts | 2 +- database/getBurialSiteFields.ts | 2 +- database/getBurialSiteStatusSummary.d.ts | 2 +- database/getBurialSiteStatusSummary.ts | 2 +- database/getBurialSiteStatuses.d.ts | 2 +- database/getBurialSiteStatuses.ts | 2 +- database/getBurialSiteTypeFields.d.ts | 2 +- database/getBurialSiteTypeFields.ts | 2 +- database/getBurialSiteTypeSummary.d.ts | 2 +- database/getBurialSiteTypeSummary.ts | 2 +- database/getBurialSiteTypes.d.ts | 2 +- database/getBurialSiteTypes.ts | 2 +- database/getBurialSites.d.ts | 2 +- database/getBurialSites.ts | 2 +- database/getCemeteries.d.ts | 2 +- database/getCemeteries.ts | 2 +- database/getCemetery.d.ts | 2 +- database/getCemetery.ts | 2 +- database/getCommittalTypes.d.ts | 2 +- database/getCommittalTypes.ts | 2 +- database/getContract.d.ts | 2 +- database/getContract.ts | 2 +- database/getContractComments.d.ts | 2 +- database/getContractComments.ts | 2 +- database/getContractFees.d.ts | 2 +- database/getContractFees.ts | 2 +- database/getContractFields.d.ts | 2 +- database/getContractFields.ts | 2 +- database/getContractInterments.d.ts | 2 +- database/getContractInterments.ts | 2 +- database/getContractTransactions.d.ts | 2 +- database/getContractTransactions.ts | 2 +- database/getContractTypeFields.d.ts | 2 +- database/getContractTypeFields.ts | 2 +- database/getContractTypes.d.ts | 2 +- database/getContractTypes.ts | 2 +- database/getContracts.d.ts | 2 +- database/getContracts.ts | 2 +- database/getFee.d.ts | 2 +- database/getFee.ts | 2 +- database/getFeeCategories.d.ts | 2 +- database/getFeeCategories.ts | 2 +- database/getFees.d.ts | 2 +- database/getFees.ts | 2 +- database/getFuneralHome.d.ts | 2 +- database/getFuneralHome.ts | 2 +- database/getFuneralHomes.d.ts | 2 +- database/getFuneralHomes.ts | 2 +- database/getIntermentContainerTypes.d.ts | 2 +- database/getIntermentContainerTypes.ts | 2 +- database/getWorkOrder.d.ts | 2 +- database/getWorkOrder.ts | 2 +- database/getWorkOrderComments.d.ts | 2 +- database/getWorkOrderComments.ts | 2 +- database/getWorkOrderMilestoneTypes.d.ts | 2 +- database/getWorkOrderMilestoneTypes.ts | 2 +- database/getWorkOrderMilestones.d.ts | 2 +- database/getWorkOrderMilestones.ts | 2 +- database/getWorkOrderTypes.d.ts | 2 +- database/getWorkOrderTypes.ts | 2 +- database/getWorkOrders.d.ts | 2 +- database/getWorkOrders.ts | 2 +- database/moveFee.ts | 2 +- handlers/api-get/milestoneICS.ts | 2 +- handlers/burialSites-get/new.ts | 2 +- handlers/cemeteries-get/new.ts | 2 +- handlers/contracts-get/new.ts | 2 +- .../contracts-post/doGetContractTypeFields.ts | 2 +- handlers/contracts-post/doGetFees.ts | 2 +- handlers/funeralHomes-get/new.ts | 2 +- handlers/workOrders-get/new.ts | 2 +- helpers/burialSites.helpers.ts | 2 +- helpers/contracts.helpers.d.ts | 2 +- helpers/contracts.helpers.ts | 2 +- helpers/functions.cache.d.ts | 2 +- helpers/functions.cache.ts | 4 ++-- helpers/functions.dynamicsGP.d.ts | 2 +- helpers/functions.dynamicsGP.ts | 4 ++-- helpers/functions.fee.d.ts | 2 +- helpers/functions.fee.ts | 2 +- helpers/functions.print.d.ts | 2 +- helpers/functions.print.ts | 2 +- public/javascripts/burialSite.edit.ts | 2 +- public/javascripts/burialSite.search.ts | 2 +- public/javascripts/burialSiteTypes.admin.ts | 2 +- public/javascripts/cemetery.search.ts | 2 +- public/javascripts/contract.edit.ts | 2 +- public/javascripts/contract.editComments.ts | 2 +- public/javascripts/contract.editFees.ts | 2 +- public/javascripts/contract.editInterments.ts | 2 +- public/javascripts/contract.editWorkOrders.ts | 2 +- public/javascripts/contract.search.ts | 2 +- public/javascripts/contractTypes.admin.ts | 2 +- public/javascripts/fees.admin.ts | 2 +- public/javascripts/funeralHome.search.ts | 2 +- public/javascripts/tables.admin.ts | 2 +- public/javascripts/workOrder.edit.ts | 2 +- public/javascripts/workOrder.editComments.ts | 2 +- public/javascripts/workOrder.editRelated.ts | 2 +- .../workOrder.milestoneCalendar.ts | 2 +- public/javascripts/workOrder.search.ts | 2 +- temp/legacyImportFromCsv/data.funeralHomes.ts | 2 +- temp/legacyImportFromCsv/data.ids.d.ts | 6 ++--- temp/legacyImportFromCsv/index.ts | 2 +- ...ationTypes.d.ts => application.types.d.ts} | 0 ...plicationTypes.ts => application.types.ts} | 0 types/{configTypes.d.ts => config.types.d.ts} | 0 types/{configTypes.ts => config.types.ts} | 0 types/{recordTypes.d.ts => record.types.d.ts} | 16 ------------- types/{recordTypes.ts => record.types.ts} | 23 ------------------- types/user.types.d.ts | 16 +++++++++++++ types/user.types.ts | 18 +++++++++++++++ 130 files changed, 160 insertions(+), 165 deletions(-) rename types/{applicationTypes.d.ts => application.types.d.ts} (100%) rename types/{applicationTypes.ts => application.types.ts} (100%) rename types/{configTypes.d.ts => config.types.d.ts} (100%) rename types/{configTypes.ts => config.types.ts} (100%) rename types/{recordTypes.d.ts => record.types.d.ts} (97%) rename types/{recordTypes.ts => record.types.ts} (96%) create mode 100644 types/user.types.d.ts create mode 100644 types/user.types.ts diff --git a/bin/www.ts b/bin/www.ts index a1baf412..8bbf40cd 100644 --- a/bin/www.ts +++ b/bin/www.ts @@ -11,7 +11,7 @@ import exitHook from 'exit-hook' import { initializeDatabase } from '../database/initializeDatabase.js' import { DEBUG_NAMESPACE } from '../debug.config.js' import { getConfigProperty } from '../helpers/config.helpers.js' -import type { WorkerMessage } from '../types/applicationTypes.js' +import type { WorkerMessage } from '../types/application.types.js' import version from '../version.js' const debug = Debug(`${DEBUG_NAMESPACE}:www:${process.pid}`) diff --git a/cypress/e2e/01-admin/feeManagement.cy.ts b/cypress/e2e/01-admin/feeManagement.cy.ts index b2ada34d..d195ee4b 100644 --- a/cypress/e2e/01-admin/feeManagement.cy.ts +++ b/cypress/e2e/01-admin/feeManagement.cy.ts @@ -1,6 +1,6 @@ import { getConfigProperty } from '../../../helpers/config.helpers.js' import { testAdmin } from '../../../test/_globals.js' -import type { Fee } from '../../../types/recordTypes.js' +import type { Fee } from '../../../types/record.types.js' import { ajaxDelayMillis, login, logout } from '../../support/index.js' describe('Admin - Fee Management', () => { diff --git a/cypress/e2e/02-update/cemeteries.cy.ts b/cypress/e2e/02-update/cemeteries.cy.ts index 8bc66847..e66e455b 100644 --- a/cypress/e2e/02-update/cemeteries.cy.ts +++ b/cypress/e2e/02-update/cemeteries.cy.ts @@ -1,6 +1,6 @@ import { getConfigProperty } from '../../../helpers/config.helpers.js' import { testUpdate } from '../../../test/_globals.js' -import type { Cemetery } from '../../../types/recordTypes.js' +import type { Cemetery } from '../../../types/record.types.js' import { login, logout } from '../../support/index.js' describe('Update - Cemeteries', () => { diff --git a/data/config.base.d.ts b/data/config.base.d.ts index 7a20dd7a..e3338890 100644 --- a/data/config.base.d.ts +++ b/data/config.base.d.ts @@ -1,3 +1,3 @@ -import type { Config } from '../types/configTypes.js'; +import type { Config } from '../types/config.types.js'; export declare const config: Config; export default config; diff --git a/data/config.base.ts b/data/config.base.ts index a53cd22d..30c04045 100644 --- a/data/config.base.ts +++ b/data/config.base.ts @@ -1,4 +1,4 @@ -import type { Config } from '../types/configTypes.js' +import type { Config } from '../types/config.types.js' export const config: Config = { aliases: {}, diff --git a/data/config.baseOntario.d.ts b/data/config.baseOntario.d.ts index 4cc10144..8f507f37 100644 --- a/data/config.baseOntario.d.ts +++ b/data/config.baseOntario.d.ts @@ -1,2 +1,2 @@ -export declare const config: import("../types/configTypes.js").Config; +export declare const config: import("../types/config.types.js").Config; export default config; diff --git a/data/config.baseSsm.d.ts b/data/config.baseSsm.d.ts index 7a20dd7a..e3338890 100644 --- a/data/config.baseSsm.d.ts +++ b/data/config.baseSsm.d.ts @@ -1,3 +1,3 @@ -import type { Config } from '../types/configTypes.js'; +import type { Config } from '../types/config.types.js'; export declare const config: Config; export default config; diff --git a/data/config.baseSsm.ts b/data/config.baseSsm.ts index e9dd0ca1..f816d409 100644 --- a/data/config.baseSsm.ts +++ b/data/config.baseSsm.ts @@ -1,4 +1,4 @@ -import type { Config } from '../types/configTypes.js' +import type { Config } from '../types/config.types.js' import { config as cemeteryConfig } from './config.baseOntario.js' diff --git a/data/config.defaultValues.d.ts b/data/config.defaultValues.d.ts index 7e689d6e..1a0e8dcf 100644 --- a/data/config.defaultValues.d.ts +++ b/data/config.defaultValues.d.ts @@ -1,5 +1,5 @@ import type { config as MSSQLConfig } from 'mssql'; -import type { ConfigActiveDirectory, ConfigBurialSiteNameSegments, ConfigNtfyStartup, DynamicsGPLookup } from '../types/configTypes.js'; +import type { ConfigActiveDirectory, ConfigBurialSiteNameSegments, ConfigNtfyStartup, DynamicsGPLookup } from '../types/config.types.js'; export declare const configDefaultValues: { activeDirectory: ConfigActiveDirectory; 'application.applicationName': string; diff --git a/data/config.defaultValues.ts b/data/config.defaultValues.ts index 7738d28b..a161093b 100644 --- a/data/config.defaultValues.ts +++ b/data/config.defaultValues.ts @@ -7,7 +7,7 @@ import type { ConfigBurialSiteNameSegments, ConfigNtfyStartup, DynamicsGPLookup -} from '../types/configTypes.js' +} from '../types/config.types.js' export const configDefaultValues = { activeDirectory: undefined as unknown as ConfigActiveDirectory, diff --git a/data/config.testing.d.ts b/data/config.testing.d.ts index 7a20dd7a..e3338890 100644 --- a/data/config.testing.d.ts +++ b/data/config.testing.d.ts @@ -1,3 +1,3 @@ -import type { Config } from '../types/configTypes.js'; +import type { Config } from '../types/config.types.js'; export declare const config: Config; export default config; diff --git a/data/config.testing.ts b/data/config.testing.ts index 984205bc..6ad7a29e 100644 --- a/data/config.testing.ts +++ b/data/config.testing.ts @@ -1,4 +1,4 @@ -import type { Config } from '../types/configTypes.js' +import type { Config } from '../types/config.types.js' import { config as cemeteryConfig } from './config.baseSsm.js' diff --git a/database/addContractFee.ts b/database/addContractFee.ts index 15b1c250..b82c0eb3 100644 --- a/database/addContractFee.ts +++ b/database/addContractFee.ts @@ -4,7 +4,7 @@ import { calculateFeeAmount, calculateTaxAmount } from '../helpers/functions.fee.js' -import type { Contract, Fee } from '../types/recordTypes.js' +import type { Contract, Fee } from '../types/record.types.js' import getContract from './getContract.js' import getFee from './getFee.js' diff --git a/database/copyContract.ts b/database/copyContract.ts index 55a58d14..f123b41c 100644 --- a/database/copyContract.ts +++ b/database/copyContract.ts @@ -1,6 +1,6 @@ import { dateToString } from '@cityssm/utils-datetime' -import type { Contract } from '../types/recordTypes.js' +import type { Contract } from '../types/record.types.js' import addContract from './addContract.js' import addContractComment from './addContractComment.js' diff --git a/database/getBurialSite.d.ts b/database/getBurialSite.d.ts index a43e7226..d8f77727 100644 --- a/database/getBurialSite.d.ts +++ b/database/getBurialSite.d.ts @@ -1,3 +1,3 @@ -import type { BurialSite } from '../types/recordTypes.js'; +import type { BurialSite } from '../types/record.types.js'; export default function getBurialSite(burialSiteId: number | string): Promise; export declare function getBurialSiteByBurialSiteName(burialSiteName: string): Promise; diff --git a/database/getBurialSite.ts b/database/getBurialSite.ts index a41dcded..92c8d379 100644 --- a/database/getBurialSite.ts +++ b/database/getBurialSite.ts @@ -1,4 +1,4 @@ -import type { BurialSite } from '../types/recordTypes.js' +import type { BurialSite } from '../types/record.types.js' import getBurialSiteComments from './getBurialSiteComments.js' import getBurialSiteFields from './getBurialSiteFields.js' diff --git a/database/getBurialSiteComments.d.ts b/database/getBurialSiteComments.d.ts index b0dbe7bc..527aa88b 100644 --- a/database/getBurialSiteComments.d.ts +++ b/database/getBurialSiteComments.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { BurialSiteComment } from '../types/recordTypes.js'; +import type { BurialSiteComment } from '../types/record.types.js'; export default function getBurialSiteComments(burialSiteId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getBurialSiteComments.ts b/database/getBurialSiteComments.ts index 5326a1cf..a563e1bb 100644 --- a/database/getBurialSiteComments.ts +++ b/database/getBurialSiteComments.ts @@ -6,7 +6,7 @@ import { timeIntegerToString } from '@cityssm/utils-datetime' -import type { BurialSiteComment } from '../types/recordTypes.js' +import type { BurialSiteComment } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getBurialSiteFields.d.ts b/database/getBurialSiteFields.d.ts index 1532b6a9..a46c6477 100644 --- a/database/getBurialSiteFields.d.ts +++ b/database/getBurialSiteFields.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { BurialSiteField } from '../types/recordTypes.js'; +import type { BurialSiteField } from '../types/record.types.js'; export default function getBurialSiteFields(burialSiteId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getBurialSiteFields.ts b/database/getBurialSiteFields.ts index 35c41986..c3fefe07 100644 --- a/database/getBurialSiteFields.ts +++ b/database/getBurialSiteFields.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { BurialSiteField } from '../types/recordTypes.js' +import type { BurialSiteField } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getBurialSiteStatusSummary.d.ts b/database/getBurialSiteStatusSummary.d.ts index f6792d2d..81ed792c 100644 --- a/database/getBurialSiteStatusSummary.d.ts +++ b/database/getBurialSiteStatusSummary.d.ts @@ -1,4 +1,4 @@ -import type { BurialSiteStatus } from '../types/recordTypes.js'; +import type { BurialSiteStatus } from '../types/record.types.js'; interface GetFilters { cemeteryId?: number | string; } diff --git a/database/getBurialSiteStatusSummary.ts b/database/getBurialSiteStatusSummary.ts index fbe8dc0b..7354784e 100644 --- a/database/getBurialSiteStatusSummary.ts +++ b/database/getBurialSiteStatusSummary.ts @@ -1,4 +1,4 @@ -import type { BurialSiteStatus } from '../types/recordTypes.js' +import type { BurialSiteStatus } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getBurialSiteStatuses.d.ts b/database/getBurialSiteStatuses.d.ts index 96222547..c61c5925 100644 --- a/database/getBurialSiteStatuses.d.ts +++ b/database/getBurialSiteStatuses.d.ts @@ -1,2 +1,2 @@ -import type { BurialSiteStatus } from '../types/recordTypes.js'; +import type { BurialSiteStatus } from '../types/record.types.js'; export default function getBurialSiteStatuses(): Promise; diff --git a/database/getBurialSiteStatuses.ts b/database/getBurialSiteStatuses.ts index b18be3a6..9ed4d510 100644 --- a/database/getBurialSiteStatuses.ts +++ b/database/getBurialSiteStatuses.ts @@ -1,4 +1,4 @@ -import type { BurialSiteStatus } from '../types/recordTypes.js' +import type { BurialSiteStatus } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getBurialSiteTypeFields.d.ts b/database/getBurialSiteTypeFields.d.ts index 4e879874..9ccc52bc 100644 --- a/database/getBurialSiteTypeFields.d.ts +++ b/database/getBurialSiteTypeFields.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { BurialSiteTypeField } from '../types/recordTypes.js'; +import type { BurialSiteTypeField } from '../types/record.types.js'; export default function getBurialSiteTypeFields(burialSiteTypeId: number, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getBurialSiteTypeFields.ts b/database/getBurialSiteTypeFields.ts index aa659cad..0f7dc069 100644 --- a/database/getBurialSiteTypeFields.ts +++ b/database/getBurialSiteTypeFields.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { BurialSiteTypeField } from '../types/recordTypes.js' +import type { BurialSiteTypeField } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getBurialSiteTypeSummary.d.ts b/database/getBurialSiteTypeSummary.d.ts index e0808779..57fd34ae 100644 --- a/database/getBurialSiteTypeSummary.d.ts +++ b/database/getBurialSiteTypeSummary.d.ts @@ -1,4 +1,4 @@ -import type { BurialSiteType } from '../types/recordTypes.js'; +import type { BurialSiteType } from '../types/record.types.js'; interface BurialSiteTypeSummary extends BurialSiteType { lotCount: number; } diff --git a/database/getBurialSiteTypeSummary.ts b/database/getBurialSiteTypeSummary.ts index fb78e4fc..50173bbf 100644 --- a/database/getBurialSiteTypeSummary.ts +++ b/database/getBurialSiteTypeSummary.ts @@ -1,4 +1,4 @@ -import type { BurialSiteType } from '../types/recordTypes.js' +import type { BurialSiteType } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getBurialSiteTypes.d.ts b/database/getBurialSiteTypes.d.ts index b02e4720..16bf5485 100644 --- a/database/getBurialSiteTypes.d.ts +++ b/database/getBurialSiteTypes.d.ts @@ -1,2 +1,2 @@ -import type { BurialSiteType } from '../types/recordTypes.js'; +import type { BurialSiteType } from '../types/record.types.js'; export default function getBurialSiteTypes(): Promise; diff --git a/database/getBurialSiteTypes.ts b/database/getBurialSiteTypes.ts index 065d0008..3d18889e 100644 --- a/database/getBurialSiteTypes.ts +++ b/database/getBurialSiteTypes.ts @@ -1,4 +1,4 @@ -import type { BurialSiteType } from '../types/recordTypes.js' +import type { BurialSiteType } from '../types/record.types.js' import getBurialSiteTypeFields from './getBurialSiteTypeFields.js' import { acquireConnection } from './pool.js' diff --git a/database/getBurialSites.d.ts b/database/getBurialSites.d.ts index 53a0e8ae..3a35bdd3 100644 --- a/database/getBurialSites.d.ts +++ b/database/getBurialSites.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { BurialSite } from '../types/recordTypes.js'; +import type { BurialSite } from '../types/record.types.js'; export interface GetBurialSitesFilters { burialSiteNameSearchType?: '' | 'endsWith' | 'startsWith'; burialSiteName?: string; diff --git a/database/getBurialSites.ts b/database/getBurialSites.ts index e595a139..a23ba6f7 100644 --- a/database/getBurialSites.ts +++ b/database/getBurialSites.ts @@ -3,7 +3,7 @@ import type { PoolConnection } from 'better-sqlite-pool' import { dateToInteger } from '@cityssm/utils-datetime' import { getBurialSiteNameWhereClause } from '../helpers/functions.sqlFilters.js' -import type { BurialSite } from '../types/recordTypes.js' +import type { BurialSite } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getCemeteries.d.ts b/database/getCemeteries.d.ts index b930213c..94cbaaec 100644 --- a/database/getCemeteries.d.ts +++ b/database/getCemeteries.d.ts @@ -1,4 +1,4 @@ -import type { Cemetery } from '../types/recordTypes.js'; +import type { Cemetery } from '../types/record.types.js'; export default function getCemeteries(filters?: { parentCemeteryId?: number | string; }): Promise; diff --git a/database/getCemeteries.ts b/database/getCemeteries.ts index 88ce34d7..bd0ad948 100644 --- a/database/getCemeteries.ts +++ b/database/getCemeteries.ts @@ -1,4 +1,4 @@ -import type { Cemetery } from '../types/recordTypes.js' +import type { Cemetery } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getCemetery.d.ts b/database/getCemetery.d.ts index 02c99c31..7c36df82 100644 --- a/database/getCemetery.d.ts +++ b/database/getCemetery.d.ts @@ -1,4 +1,4 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { Cemetery } from '../types/recordTypes.js'; +import type { Cemetery } from '../types/record.types.js'; export default function getCemetery(cemeteryId: number | string, connectedDatabase?: PoolConnection): Promise; export declare function getCemeteryByKey(cemeteryKey: string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getCemetery.ts b/database/getCemetery.ts index de1d85a0..df7993dd 100644 --- a/database/getCemetery.ts +++ b/database/getCemetery.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { Cemetery } from '../types/recordTypes.js' +import type { Cemetery } from '../types/record.types.js' import getCemeteries from './getCemeteries.js' import { acquireConnection } from './pool.js' diff --git a/database/getCommittalTypes.d.ts b/database/getCommittalTypes.d.ts index 55569a89..c75426b1 100644 --- a/database/getCommittalTypes.d.ts +++ b/database/getCommittalTypes.d.ts @@ -1,2 +1,2 @@ -import type { CommittalType } from '../types/recordTypes.js'; +import type { CommittalType } from '../types/record.types.js'; export default function getCommittalTypes(): Promise; diff --git a/database/getCommittalTypes.ts b/database/getCommittalTypes.ts index 497b6b85..057c33d0 100644 --- a/database/getCommittalTypes.ts +++ b/database/getCommittalTypes.ts @@ -1,4 +1,4 @@ -import type { CommittalType } from '../types/recordTypes.js' +import type { CommittalType } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getContract.d.ts b/database/getContract.d.ts index 9d759f55..5e706afc 100644 --- a/database/getContract.d.ts +++ b/database/getContract.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { Contract } from '../types/recordTypes.js'; +import type { Contract } from '../types/record.types.js'; export default function getContract(contractId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContract.ts b/database/getContract.ts index bf9d2d9d..4b951c57 100644 --- a/database/getContract.ts +++ b/database/getContract.ts @@ -2,7 +2,7 @@ import type { PoolConnection } from 'better-sqlite-pool' import { dateIntegerToString, timeIntegerToPeriodString, timeIntegerToString } from '@cityssm/utils-datetime' -import type { Contract } from '../types/recordTypes.js' +import type { Contract } from '../types/record.types.js' import getContractComments from './getContractComments.js' import getContractFees from './getContractFees.js' diff --git a/database/getContractComments.d.ts b/database/getContractComments.d.ts index c2fc196f..1827b54f 100644 --- a/database/getContractComments.d.ts +++ b/database/getContractComments.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractComment } from '../types/recordTypes.js'; +import type { ContractComment } from '../types/record.types.js'; export default function getContractComments(contractId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractComments.ts b/database/getContractComments.ts index 0f8389db..e22df4b3 100644 --- a/database/getContractComments.ts +++ b/database/getContractComments.ts @@ -6,7 +6,7 @@ import { timeIntegerToString } from '@cityssm/utils-datetime' -import type { ContractComment } from '../types/recordTypes.js' +import type { ContractComment } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getContractFees.d.ts b/database/getContractFees.d.ts index 157dc9e0..d0e2f691 100644 --- a/database/getContractFees.d.ts +++ b/database/getContractFees.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractFee } from '../types/recordTypes.js'; +import type { ContractFee } from '../types/record.types.js'; export default function getContractFees(contractId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractFees.ts b/database/getContractFees.ts index 577685c4..2db47223 100644 --- a/database/getContractFees.ts +++ b/database/getContractFees.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { ContractFee } from '../types/recordTypes.js' +import type { ContractFee } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getContractFields.d.ts b/database/getContractFields.d.ts index a2e3cbc3..714f51da 100644 --- a/database/getContractFields.d.ts +++ b/database/getContractFields.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractField } from '../types/recordTypes.js'; +import type { ContractField } from '../types/record.types.js'; export default function getContractField(contractId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractFields.ts b/database/getContractFields.ts index 2df018a7..078c9f83 100644 --- a/database/getContractFields.ts +++ b/database/getContractFields.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { ContractField } from '../types/recordTypes.js' +import type { ContractField } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getContractInterments.d.ts b/database/getContractInterments.d.ts index fa51d170..0570f749 100644 --- a/database/getContractInterments.d.ts +++ b/database/getContractInterments.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractInterment } from '../types/recordTypes.js'; +import type { ContractInterment } from '../types/record.types.js'; export default function getContractInterments(contractId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractInterments.ts b/database/getContractInterments.ts index 03e944f8..decd7d09 100644 --- a/database/getContractInterments.ts +++ b/database/getContractInterments.ts @@ -4,7 +4,7 @@ import { dateIntegerToString } from '@cityssm/utils-datetime' -import type { ContractInterment } from '../types/recordTypes.js' +import type { ContractInterment } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getContractTransactions.d.ts b/database/getContractTransactions.d.ts index 948438ed..2192bcee 100644 --- a/database/getContractTransactions.d.ts +++ b/database/getContractTransactions.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractTransaction } from '../types/recordTypes.js'; +import type { ContractTransaction } from '../types/record.types.js'; export default function GetContractTransactions(contractId: number | string, options: { includeIntegrations: boolean; }, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractTransactions.ts b/database/getContractTransactions.ts index 278809f3..afd2fbc9 100644 --- a/database/getContractTransactions.ts +++ b/database/getContractTransactions.ts @@ -7,7 +7,7 @@ import { import { getConfigProperty } from '../helpers/config.helpers.js' import { getDynamicsGPDocument } from '../helpers/functions.dynamicsGP.js' -import type { ContractTransaction } from '../types/recordTypes.js' +import type { ContractTransaction } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getContractTypeFields.d.ts b/database/getContractTypeFields.d.ts index 9978475a..57ecbb99 100644 --- a/database/getContractTypeFields.d.ts +++ b/database/getContractTypeFields.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { ContractTypeField } from '../types/recordTypes.js'; +import type { ContractTypeField } from '../types/record.types.js'; export default function getContractTypeFields(contractTypeId?: number, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getContractTypeFields.ts b/database/getContractTypeFields.ts index 86b9068a..24b9907a 100644 --- a/database/getContractTypeFields.ts +++ b/database/getContractTypeFields.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { ContractTypeField } from '../types/recordTypes.js' +import type { ContractTypeField } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getContractTypes.d.ts b/database/getContractTypes.d.ts index 3e8cab74..3ab3f17e 100644 --- a/database/getContractTypes.d.ts +++ b/database/getContractTypes.d.ts @@ -1,2 +1,2 @@ -import type { ContractType } from '../types/recordTypes.js'; +import type { ContractType } from '../types/record.types.js'; export default function getContractTypes(): Promise; diff --git a/database/getContractTypes.ts b/database/getContractTypes.ts index 17b4f1f5..fb5e89df 100644 --- a/database/getContractTypes.ts +++ b/database/getContractTypes.ts @@ -1,4 +1,4 @@ -import type { ContractType } from '../types/recordTypes.js' +import type { ContractType } from '../types/record.types.js' import getContractTypeFields from './getContractTypeFields.js' import getContractTypePrints from './getContractTypePrints.js' diff --git a/database/getContracts.d.ts b/database/getContracts.d.ts index 40eed359..1d4d3b52 100644 --- a/database/getContracts.d.ts +++ b/database/getContracts.d.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool'; import { type DateString } from '@cityssm/utils-datetime'; -import type { Contract } from '../types/recordTypes.js'; +import type { Contract } from '../types/record.types.js'; export interface GetContractsFilters { burialSiteId?: number | string; contractEffectiveDateString?: string; diff --git a/database/getContracts.ts b/database/getContracts.ts index 66978b44..a0965e22 100644 --- a/database/getContracts.ts +++ b/database/getContracts.ts @@ -14,7 +14,7 @@ import { getContractTimeWhereClause, getDeceasedNameWhereClause } from '../helpers/functions.sqlFilters.js' -import type { Contract } from '../types/recordTypes.js' +import type { Contract } from '../types/record.types.js' import getContractFees from './getContractFees.js' import getContractInterments from './getContractInterments.js' diff --git a/database/getFee.d.ts b/database/getFee.d.ts index 3d632de0..d69a92c4 100644 --- a/database/getFee.d.ts +++ b/database/getFee.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { Fee } from '../types/recordTypes.js'; +import type { Fee } from '../types/record.types.js'; export default function getFee(feeId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getFee.ts b/database/getFee.ts index 73c24953..b8d5cd2a 100644 --- a/database/getFee.ts +++ b/database/getFee.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { Fee } from '../types/recordTypes.js' +import type { Fee } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getFeeCategories.d.ts b/database/getFeeCategories.d.ts index 6628aadf..aa7b34f7 100644 --- a/database/getFeeCategories.d.ts +++ b/database/getFeeCategories.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { FeeCategory } from '../types/recordTypes.js'; +import type { FeeCategory } from '../types/record.types.js'; interface GetFeeCategoriesFilters { burialSiteTypeId?: number | string; contractTypeId?: number | string; diff --git a/database/getFeeCategories.ts b/database/getFeeCategories.ts index 98cadcc6..f94d1a6f 100644 --- a/database/getFeeCategories.ts +++ b/database/getFeeCategories.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { FeeCategory } from '../types/recordTypes.js' +import type { FeeCategory } from '../types/record.types.js' import getFees from './getFees.js' import { acquireConnection } from './pool.js' diff --git a/database/getFees.d.ts b/database/getFees.d.ts index 587bfce6..ba1316e6 100644 --- a/database/getFees.d.ts +++ b/database/getFees.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { Fee } from '../types/recordTypes.js'; +import type { Fee } from '../types/record.types.js'; interface GetFeesFilters { burialSiteTypeId?: number | string; contractTypeId?: number | string; diff --git a/database/getFees.ts b/database/getFees.ts index f7d57191..e1772727 100644 --- a/database/getFees.ts +++ b/database/getFees.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool' -import type { Fee } from '../types/recordTypes.js' +import type { Fee } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getFuneralHome.d.ts b/database/getFuneralHome.d.ts index dc0a4338..a63035aa 100644 --- a/database/getFuneralHome.d.ts +++ b/database/getFuneralHome.d.ts @@ -1,3 +1,3 @@ -import type { FuneralHome } from '../types/recordTypes.js'; +import type { FuneralHome } from '../types/record.types.js'; export default function getFuneralHome(funeralHomeId: number | string): Promise; export declare function getFuneralHomeByKey(funeralHomeKey: string): Promise; diff --git a/database/getFuneralHome.ts b/database/getFuneralHome.ts index 33a84b09..6654a117 100644 --- a/database/getFuneralHome.ts +++ b/database/getFuneralHome.ts @@ -1,4 +1,4 @@ -import type { Cemetery, FuneralHome } from '../types/recordTypes.js' +import type { Cemetery, FuneralHome } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getFuneralHomes.d.ts b/database/getFuneralHomes.d.ts index 4fb76855..9f24ddfc 100644 --- a/database/getFuneralHomes.d.ts +++ b/database/getFuneralHomes.d.ts @@ -1,2 +1,2 @@ -import type { FuneralHome } from '../types/recordTypes.js'; +import type { FuneralHome } from '../types/record.types.js'; export default function getFuneralHomes(): Promise; diff --git a/database/getFuneralHomes.ts b/database/getFuneralHomes.ts index 4139a1c6..e35665c1 100644 --- a/database/getFuneralHomes.ts +++ b/database/getFuneralHomes.ts @@ -1,4 +1,4 @@ -import type { Cemetery, FuneralHome } from '../types/recordTypes.js' +import type { Cemetery, FuneralHome } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getIntermentContainerTypes.d.ts b/database/getIntermentContainerTypes.d.ts index d3be3712..905f41ce 100644 --- a/database/getIntermentContainerTypes.d.ts +++ b/database/getIntermentContainerTypes.d.ts @@ -1,2 +1,2 @@ -import type { IntermentContainerType } from '../types/recordTypes.js'; +import type { IntermentContainerType } from '../types/record.types.js'; export default function getIntermentContainerTypes(): Promise; diff --git a/database/getIntermentContainerTypes.ts b/database/getIntermentContainerTypes.ts index 8347037d..97da52d0 100644 --- a/database/getIntermentContainerTypes.ts +++ b/database/getIntermentContainerTypes.ts @@ -1,4 +1,4 @@ -import type { IntermentContainerType } from '../types/recordTypes.js' +import type { IntermentContainerType } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getWorkOrder.d.ts b/database/getWorkOrder.d.ts index 2fed6f37..545a5b55 100644 --- a/database/getWorkOrder.d.ts +++ b/database/getWorkOrder.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { WorkOrder } from '../types/recordTypes.js'; +import type { WorkOrder } from '../types/record.types.js'; interface WorkOrderOptions { includeBurialSites: boolean; includeComments: boolean; diff --git a/database/getWorkOrder.ts b/database/getWorkOrder.ts index 10787638..61a5ce7d 100644 --- a/database/getWorkOrder.ts +++ b/database/getWorkOrder.ts @@ -2,7 +2,7 @@ import type { PoolConnection } from 'better-sqlite-pool' import { dateIntegerToString } from '@cityssm/utils-datetime' -import type { WorkOrder } from '../types/recordTypes.js' +import type { WorkOrder } from '../types/record.types.js' import getBurialSites from './getBurialSites.js' import getContracts from './getContracts.js' diff --git a/database/getWorkOrderComments.d.ts b/database/getWorkOrderComments.d.ts index 852423fa..e11bb495 100644 --- a/database/getWorkOrderComments.d.ts +++ b/database/getWorkOrderComments.d.ts @@ -1,3 +1,3 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { WorkOrderComment } from '../types/recordTypes.js'; +import type { WorkOrderComment } from '../types/record.types.js'; export default function getWorkOrderComments(workOrderId: number | string, connectedDatabase?: PoolConnection): Promise; diff --git a/database/getWorkOrderComments.ts b/database/getWorkOrderComments.ts index cbab58c4..9f19a938 100644 --- a/database/getWorkOrderComments.ts +++ b/database/getWorkOrderComments.ts @@ -6,7 +6,7 @@ import { timeIntegerToString } from '@cityssm/utils-datetime' -import type { WorkOrderComment } from '../types/recordTypes.js' +import type { WorkOrderComment } from '../types/record.types.js' import { acquireConnection } from './pool.js' diff --git a/database/getWorkOrderMilestoneTypes.d.ts b/database/getWorkOrderMilestoneTypes.d.ts index 6e6aa2e1..dedd17b1 100644 --- a/database/getWorkOrderMilestoneTypes.d.ts +++ b/database/getWorkOrderMilestoneTypes.d.ts @@ -1,2 +1,2 @@ -import type { WorkOrderMilestoneType } from '../types/recordTypes.js'; +import type { WorkOrderMilestoneType } from '../types/record.types.js'; export default function getWorkOrderMilestoneTypes(): Promise; diff --git a/database/getWorkOrderMilestoneTypes.ts b/database/getWorkOrderMilestoneTypes.ts index 6d04b616..5938eef8 100644 --- a/database/getWorkOrderMilestoneTypes.ts +++ b/database/getWorkOrderMilestoneTypes.ts @@ -1,4 +1,4 @@ -import type { WorkOrderMilestoneType } from '../types/recordTypes.js' +import type { WorkOrderMilestoneType } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getWorkOrderMilestones.d.ts b/database/getWorkOrderMilestones.d.ts index c64503e4..5704cfa2 100644 --- a/database/getWorkOrderMilestones.d.ts +++ b/database/getWorkOrderMilestones.d.ts @@ -1,6 +1,6 @@ import type { PoolConnection } from 'better-sqlite-pool'; import { type DateString } from '@cityssm/utils-datetime'; -import type { WorkOrderMilestone } from '../types/recordTypes.js'; +import type { WorkOrderMilestone } from '../types/record.types.js'; export interface WorkOrderMilestoneFilters { workOrderId?: number | string; workOrderMilestoneTypeIds?: string; diff --git a/database/getWorkOrderMilestones.ts b/database/getWorkOrderMilestones.ts index 277cb591..e9f2b0ca 100644 --- a/database/getWorkOrderMilestones.ts +++ b/database/getWorkOrderMilestones.ts @@ -10,7 +10,7 @@ import { } from '@cityssm/utils-datetime' import { getConfigProperty } from '../helpers/config.helpers.js' -import type { WorkOrderMilestone } from '../types/recordTypes.js' +import type { WorkOrderMilestone } from '../types/record.types.js' import getBurialSites from './getBurialSites.js' import getContracts from './getContracts.js' diff --git a/database/getWorkOrderTypes.d.ts b/database/getWorkOrderTypes.d.ts index 024e3763..f19b9d08 100644 --- a/database/getWorkOrderTypes.d.ts +++ b/database/getWorkOrderTypes.d.ts @@ -1,2 +1,2 @@ -import type { WorkOrderType } from '../types/recordTypes.js'; +import type { WorkOrderType } from '../types/record.types.js'; export default function getWorkOrderTypes(): Promise; diff --git a/database/getWorkOrderTypes.ts b/database/getWorkOrderTypes.ts index b81deab5..0ced1dd1 100644 --- a/database/getWorkOrderTypes.ts +++ b/database/getWorkOrderTypes.ts @@ -1,4 +1,4 @@ -import type { WorkOrderType } from '../types/recordTypes.js' +import type { WorkOrderType } from '../types/record.types.js' import { acquireConnection } from './pool.js' import { updateRecordOrderNumber } from './updateRecordOrderNumber.js' diff --git a/database/getWorkOrders.d.ts b/database/getWorkOrders.d.ts index 923a04b2..0cc1e28c 100644 --- a/database/getWorkOrders.d.ts +++ b/database/getWorkOrders.d.ts @@ -1,5 +1,5 @@ import type { PoolConnection } from 'better-sqlite-pool'; -import type { WorkOrder } from '../types/recordTypes.js'; +import type { WorkOrder } from '../types/record.types.js'; export interface GetWorkOrdersFilters { workOrderTypeId?: number | string; workOrderOpenDateString?: string; diff --git a/database/getWorkOrders.ts b/database/getWorkOrders.ts index bcc64680..38d1b5f3 100644 --- a/database/getWorkOrders.ts +++ b/database/getWorkOrders.ts @@ -10,7 +10,7 @@ import { getBurialSiteNameWhereClause, getDeceasedNameWhereClause } from '../helpers/functions.sqlFilters.js' -import type { WorkOrder } from '../types/recordTypes.js' +import type { WorkOrder } from '../types/record.types.js' import getBurialSites from './getBurialSites.js' import getContracts from './getContracts.js' diff --git a/database/moveFee.ts b/database/moveFee.ts index d3c0bb1c..5ac279b7 100644 --- a/database/moveFee.ts +++ b/database/moveFee.ts @@ -1,4 +1,4 @@ -import type { Fee } from '../types/recordTypes.js' +import type { Fee } from '../types/record.types.js' import getFee from './getFee.js' import { acquireConnection } from './pool.js' diff --git a/handlers/api-get/milestoneICS.ts b/handlers/api-get/milestoneICS.ts index 4ec008df..ff45bb6b 100644 --- a/handlers/api-get/milestoneICS.ts +++ b/handlers/api-get/milestoneICS.ts @@ -8,7 +8,7 @@ import getWorkOrderMilestones, { } from '../../database/getWorkOrderMilestones.js' import { getConfigProperty } from '../../helpers/config.helpers.js' import { getPrintConfig } from '../../helpers/functions.print.js' -import type { WorkOrderMilestone } from '../../types/recordTypes.js' +import type { WorkOrderMilestone } from '../../types/record.types.js' const calendarCompany = 'cityssm.github.io' const calendarProduct = getConfigProperty('application.applicationName') diff --git a/handlers/burialSites-get/new.ts b/handlers/burialSites-get/new.ts index 690adfa5..07f257ea 100644 --- a/handlers/burialSites-get/new.ts +++ b/handlers/burialSites-get/new.ts @@ -6,7 +6,7 @@ import { getBurialSiteTypes } from '../../helpers/functions.cache.js' import { getBurialSiteImages } from '../../helpers/images.helpers.js' -import type { BurialSite } from '../../types/recordTypes.js' +import type { BurialSite } from '../../types/record.types.js' export default async function handler( request: Request, diff --git a/handlers/cemeteries-get/new.ts b/handlers/cemeteries-get/new.ts index fbe8c0da..549aa964 100644 --- a/handlers/cemeteries-get/new.ts +++ b/handlers/cemeteries-get/new.ts @@ -3,7 +3,7 @@ import type { Request, Response } from 'express' import getCemeteries from '../../database/getCemeteries.js' import { getConfigProperty } from '../../helpers/config.helpers.js' import { getCemeterySVGs } from '../../helpers/images.helpers.js' -import type { Cemetery } from '../../types/recordTypes.js' +import type { Cemetery } from '../../types/record.types.js' export default async function handler( _request: Request, diff --git a/handlers/contracts-get/new.ts b/handlers/contracts-get/new.ts index 34a7b416..b8df21db 100644 --- a/handlers/contracts-get/new.ts +++ b/handlers/contracts-get/new.ts @@ -6,7 +6,7 @@ import getBurialSite from '../../database/getBurialSite.js' import getFuneralHomes from '../../database/getFuneralHomes.js' import { getConfigProperty } from '../../helpers/config.helpers.js' import { getCommittalTypes, getContractTypes, getIntermentContainerTypes } from '../../helpers/functions.cache.js' -import type { Contract } from '../../types/recordTypes.js' +import type { Contract } from '../../types/record.types.js' export default async function handler( request: Request, diff --git a/handlers/contracts-post/doGetContractTypeFields.ts b/handlers/contracts-post/doGetContractTypeFields.ts index 2391f91c..74c11d51 100644 --- a/handlers/contracts-post/doGetContractTypeFields.ts +++ b/handlers/contracts-post/doGetContractTypeFields.ts @@ -4,7 +4,7 @@ import { getAllContractTypeFields, getContractTypeById } from '../../helpers/functions.cache.js' -import type { ContractType } from '../../types/recordTypes.js' +import type { ContractType } from '../../types/record.types.js' export default async function handler( request: Request, diff --git a/handlers/contracts-post/doGetFees.ts b/handlers/contracts-post/doGetFees.ts index 882c551c..a464728f 100644 --- a/handlers/contracts-post/doGetFees.ts +++ b/handlers/contracts-post/doGetFees.ts @@ -2,7 +2,7 @@ import type { Request, Response } from 'express' import getContract from '../../database/getContract.js' import getFeeCategories from '../../database/getFeeCategories.js' -import type { Contract } from '../../types/recordTypes.js' +import type { Contract } from '../../types/record.types.js' export default async function handler( request: Request, diff --git a/handlers/funeralHomes-get/new.ts b/handlers/funeralHomes-get/new.ts index 1bb3515b..d571a43e 100644 --- a/handlers/funeralHomes-get/new.ts +++ b/handlers/funeralHomes-get/new.ts @@ -1,7 +1,7 @@ import type { Request, Response } from 'express' import { getConfigProperty } from '../../helpers/config.helpers.js' -import type { FuneralHome } from '../../types/recordTypes.js' +import type { FuneralHome } from '../../types/record.types.js' export default function handler(_request: Request, response: Response): void { const funeralHome: FuneralHome = { diff --git a/handlers/workOrders-get/new.ts b/handlers/workOrders-get/new.ts index 6234dd35..511665ff 100644 --- a/handlers/workOrders-get/new.ts +++ b/handlers/workOrders-get/new.ts @@ -3,7 +3,7 @@ import type { Request, Response } from 'express' import { dateToInteger, dateToString } from '@cityssm/utils-datetime' import { getWorkOrderTypes } from '../../helpers/functions.cache.js' -import type { WorkOrder } from '../../types/recordTypes.js' +import type { WorkOrder } from '../../types/record.types.js' export default async function handler( request: Request, diff --git a/helpers/burialSites.helpers.ts b/helpers/burialSites.helpers.ts index 96a0a38b..4b00563e 100644 --- a/helpers/burialSites.helpers.ts +++ b/helpers/burialSites.helpers.ts @@ -13,7 +13,7 @@ import { DEBUG_NAMESPACE } from '../debug.config.js' import type { CacheBurialSiteIdsWorkerMessage, ClearNextPreviousBurialSiteIdsCacheWorkerMessage -} from '../types/applicationTypes.js' +} from '../types/application.types.js' import { getConfigProperty } from './config.helpers.js' diff --git a/helpers/contracts.helpers.d.ts b/helpers/contracts.helpers.d.ts index fee85ebd..18c15de7 100644 --- a/helpers/contracts.helpers.d.ts +++ b/helpers/contracts.helpers.d.ts @@ -1,4 +1,4 @@ -import type { Contract, ContractFee } from '../types/recordTypes.js'; +import type { Contract, ContractFee } from '../types/record.types.js'; export declare function getFeesByFeeCategory(contract: Contract, feeCategory: string, feeCategoryContains?: boolean): ContractFee[]; export declare function getFieldValueByContractTypeField(contract: Contract, contractTypeField: string): string | undefined; export declare function getTransactionTotal(contract: Contract): number; diff --git a/helpers/contracts.helpers.ts b/helpers/contracts.helpers.ts index 8ee765d9..2917eefb 100644 --- a/helpers/contracts.helpers.ts +++ b/helpers/contracts.helpers.ts @@ -1,7 +1,7 @@ import type { Contract, ContractFee -} from '../types/recordTypes.js' +} from '../types/record.types.js' export function getFeesByFeeCategory( contract: Contract, diff --git a/helpers/functions.cache.d.ts b/helpers/functions.cache.d.ts index bc10e310..4d833f2e 100644 --- a/helpers/functions.cache.d.ts +++ b/helpers/functions.cache.d.ts @@ -1,4 +1,4 @@ -import type { BurialSiteStatus, BurialSiteType, CommittalType, ContractType, ContractTypeField, IntermentContainerType, WorkOrderMilestoneType, WorkOrderType } from '../types/recordTypes.js'; +import type { BurialSiteStatus, BurialSiteType, CommittalType, ContractType, ContractTypeField, IntermentContainerType, WorkOrderMilestoneType, WorkOrderType } from '../types/record.types.js'; export declare function getBurialSiteStatusByBurialSiteStatus(burialSiteStatus: string): Promise; export declare function getBurialSiteStatusById(burialSiteStatusId: number): Promise; export declare function getBurialSiteStatuses(): Promise; diff --git a/helpers/functions.cache.ts b/helpers/functions.cache.ts index 4c98a06b..ec819f35 100644 --- a/helpers/functions.cache.ts +++ b/helpers/functions.cache.ts @@ -17,7 +17,7 @@ import { DEBUG_NAMESPACE } from '../debug.config.js' import type { ClearCacheWorkerMessage, WorkerMessage -} from '../types/applicationTypes.js' +} from '../types/application.types.js' import type { BurialSiteStatus, BurialSiteType, @@ -27,7 +27,7 @@ import type { IntermentContainerType, WorkOrderMilestoneType, WorkOrderType -} from '../types/recordTypes.js' +} from '../types/record.types.js' import { getConfigProperty } from './config.helpers.js' diff --git a/helpers/functions.dynamicsGP.d.ts b/helpers/functions.dynamicsGP.d.ts index 9974f68d..3fb588a4 100644 --- a/helpers/functions.dynamicsGP.d.ts +++ b/helpers/functions.dynamicsGP.d.ts @@ -1,2 +1,2 @@ -import type { DynamicsGPDocument } from '../types/recordTypes.js'; +import type { DynamicsGPDocument } from '../types/record.types.js'; export declare function getDynamicsGPDocument(documentNumber: string): Promise; diff --git a/helpers/functions.dynamicsGP.ts b/helpers/functions.dynamicsGP.ts index a276457c..aa3497e8 100644 --- a/helpers/functions.dynamicsGP.ts +++ b/helpers/functions.dynamicsGP.ts @@ -5,8 +5,8 @@ import { DynamicsGP } from '@cityssm/dynamics-gp' -import type { DynamicsGPLookup } from '../types/configTypes.js' -import type { DynamicsGPDocument } from '../types/recordTypes.js' +import type { DynamicsGPLookup } from '../types/config.types.js' +import type { DynamicsGPDocument } from '../types/record.types.js' import { getConfigProperty } from './config.helpers.js' diff --git a/helpers/functions.fee.d.ts b/helpers/functions.fee.d.ts index 469ff4da..8e42df4c 100644 --- a/helpers/functions.fee.d.ts +++ b/helpers/functions.fee.d.ts @@ -1,3 +1,3 @@ -import type { Contract, Fee } from '../types/recordTypes.js'; +import type { Contract, Fee } from '../types/record.types.js'; export declare function calculateFeeAmount(fee: Fee, contract: Contract): number; export declare function calculateTaxAmount(fee: Fee, feeAmount: number): number; diff --git a/helpers/functions.fee.ts b/helpers/functions.fee.ts index 815a468b..51a91876 100644 --- a/helpers/functions.fee.ts +++ b/helpers/functions.fee.ts @@ -1,4 +1,4 @@ -import type { Contract, Fee } from '../types/recordTypes.js' +import type { Contract, Fee } from '../types/record.types.js' export function calculateFeeAmount( fee: Fee, diff --git a/helpers/functions.print.d.ts b/helpers/functions.print.d.ts index ecbd9a9f..cc84a0a6 100644 --- a/helpers/functions.print.d.ts +++ b/helpers/functions.print.d.ts @@ -1,4 +1,4 @@ -import type { BurialSite, Contract, WorkOrder } from '../types/recordTypes.js'; +import type { BurialSite, Contract, WorkOrder } from '../types/record.types.js'; interface PrintConfig { params: string[]; title: string; diff --git a/helpers/functions.print.ts b/helpers/functions.print.ts index 200480a8..5a04369b 100644 --- a/helpers/functions.print.ts +++ b/helpers/functions.print.ts @@ -6,7 +6,7 @@ import * as dateTimeFunctions from '@cityssm/utils-datetime' import getBurialSite from '../database/getBurialSite.js' import getContract from '../database/getContract.js' import getWorkOrder from '../database/getWorkOrder.js' -import type { BurialSite, Contract, WorkOrder } from '../types/recordTypes.js' +import type { BurialSite, Contract, WorkOrder } from '../types/record.types.js' import * as configFunctions from './config.helpers.js' import * as contractFunctions from './contracts.helpers.js' diff --git a/public/javascripts/burialSite.edit.ts b/public/javascripts/burialSite.edit.ts index 46fb30a4..315aa6c3 100644 --- a/public/javascripts/burialSite.edit.ts +++ b/public/javascripts/burialSite.edit.ts @@ -7,7 +7,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { BurialSiteComment, BurialSiteTypeField -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/burialSite.search.ts b/public/javascripts/burialSite.search.ts index 9afb4876..fc691ed4 100644 --- a/public/javascripts/burialSite.search.ts +++ b/public/javascripts/burialSite.search.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { BurialSite } from '../../types/recordTypes.js' +import type { BurialSite } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/burialSiteTypes.admin.ts b/public/javascripts/burialSiteTypes.admin.ts index dd85c16e..a59ca573 100644 --- a/public/javascripts/burialSiteTypes.admin.ts +++ b/public/javascripts/burialSiteTypes.admin.ts @@ -7,7 +7,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { BurialSiteType, BurialSiteTypeField -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/cemetery.search.ts b/public/javascripts/cemetery.search.ts index ed64b465..eb880887 100644 --- a/public/javascripts/cemetery.search.ts +++ b/public/javascripts/cemetery.search.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { Cemetery } from '../../types/recordTypes.js' +import type { Cemetery } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contract.edit.ts b/public/javascripts/contract.edit.ts index bc9e9b04..7b1907a0 100644 --- a/public/javascripts/contract.edit.ts +++ b/public/javascripts/contract.edit.ts @@ -7,7 +7,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { BurialSite, ContractTypeField -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contract.editComments.ts b/public/javascripts/contract.editComments.ts index c91c1eea..99d40659 100644 --- a/public/javascripts/contract.editComments.ts +++ b/public/javascripts/contract.editComments.ts @@ -1,7 +1,7 @@ import type { BulmaJS } from '@cityssm/bulma-js/types.js' import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { ContractComment } from '../../types/recordTypes.js' +import type { ContractComment } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contract.editFees.ts b/public/javascripts/contract.editFees.ts index f7daffa9..eee5e7fc 100644 --- a/public/javascripts/contract.editFees.ts +++ b/public/javascripts/contract.editFees.ts @@ -10,7 +10,7 @@ import type { DynamicsGPDocument, Fee, FeeCategory -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contract.editInterments.ts b/public/javascripts/contract.editInterments.ts index 8cb36d5e..54d904bd 100644 --- a/public/javascripts/contract.editInterments.ts +++ b/public/javascripts/contract.editInterments.ts @@ -4,7 +4,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { ContractInterment, IntermentContainerType -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' declare const cityssm: cityssmGlobal declare const bulmaJS: BulmaJS diff --git a/public/javascripts/contract.editWorkOrders.ts b/public/javascripts/contract.editWorkOrders.ts index 449b12c3..4a189040 100644 --- a/public/javascripts/contract.editWorkOrders.ts +++ b/public/javascripts/contract.editWorkOrders.ts @@ -1,7 +1,7 @@ import type { BulmaJS } from '@cityssm/bulma-js/types.js' import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { WorkOrderType } from '../../types/recordTypes.js' +import type { WorkOrderType } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contract.search.ts b/public/javascripts/contract.search.ts index 698b48a6..58e72020 100644 --- a/public/javascripts/contract.search.ts +++ b/public/javascripts/contract.search.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { Contract } from '../../types/recordTypes.js' +import type { Contract } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/contractTypes.admin.ts b/public/javascripts/contractTypes.admin.ts index efad62a6..e0bfb080 100644 --- a/public/javascripts/contractTypes.admin.ts +++ b/public/javascripts/contractTypes.admin.ts @@ -7,7 +7,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { ContractType, ContractTypeField -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/fees.admin.ts b/public/javascripts/fees.admin.ts index 4b06ae8a..f92fdfc8 100644 --- a/public/javascripts/fees.admin.ts +++ b/public/javascripts/fees.admin.ts @@ -9,7 +9,7 @@ import type { ContractType, Fee, FeeCategory -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/funeralHome.search.ts b/public/javascripts/funeralHome.search.ts index 1f141d94..de0d99a9 100644 --- a/public/javascripts/funeralHome.search.ts +++ b/public/javascripts/funeralHome.search.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { FuneralHome } from '../../types/recordTypes.js' +import type { FuneralHome } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/tables.admin.ts b/public/javascripts/tables.admin.ts index 684c2261..c703c729 100644 --- a/public/javascripts/tables.admin.ts +++ b/public/javascripts/tables.admin.ts @@ -8,7 +8,7 @@ import type { BurialSiteStatus, WorkOrderMilestoneType, WorkOrderType -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/workOrder.edit.ts b/public/javascripts/workOrder.edit.ts index 141a539a..21e809b6 100644 --- a/public/javascripts/workOrder.edit.ts +++ b/public/javascripts/workOrder.edit.ts @@ -7,7 +7,7 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' import type { WorkOrderMilestone, WorkOrderMilestoneType -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/workOrder.editComments.ts b/public/javascripts/workOrder.editComments.ts index bf3f5c39..76379b56 100644 --- a/public/javascripts/workOrder.editComments.ts +++ b/public/javascripts/workOrder.editComments.ts @@ -1,7 +1,7 @@ import type { BulmaJS } from '@cityssm/bulma-js/types.js' import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { WorkOrderComment } from '../../types/recordTypes.js' +import type { WorkOrderComment } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/workOrder.editRelated.ts b/public/javascripts/workOrder.editRelated.ts index dce59a72..065b92a4 100644 --- a/public/javascripts/workOrder.editRelated.ts +++ b/public/javascripts/workOrder.editRelated.ts @@ -8,7 +8,7 @@ import type { BurialSite, BurialSiteStatus, Contract -} from '../../types/recordTypes.js' +} from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/workOrder.milestoneCalendar.ts b/public/javascripts/workOrder.milestoneCalendar.ts index ce450e5e..faa8e958 100644 --- a/public/javascripts/workOrder.milestoneCalendar.ts +++ b/public/javascripts/workOrder.milestoneCalendar.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { WorkOrderMilestone } from '../../types/recordTypes.js' +import type { WorkOrderMilestone } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/public/javascripts/workOrder.search.ts b/public/javascripts/workOrder.search.ts index ebe2dae1..db76273e 100644 --- a/public/javascripts/workOrder.search.ts +++ b/public/javascripts/workOrder.search.ts @@ -1,6 +1,6 @@ import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js' -import type { WorkOrder } from '../../types/recordTypes.js' +import type { WorkOrder } from '../../types/record.types.js' import type { Sunrise } from './types.js' diff --git a/temp/legacyImportFromCsv/data.funeralHomes.ts b/temp/legacyImportFromCsv/data.funeralHomes.ts index 66627da4..977203fc 100644 --- a/temp/legacyImportFromCsv/data.funeralHomes.ts +++ b/temp/legacyImportFromCsv/data.funeralHomes.ts @@ -1,5 +1,5 @@ import addFuneralHome from '../../database/addFuneralHome.js' -import type { FuneralHome } from '../../types/recordTypes.js' +import type { FuneralHome } from '../../types/record.types.js' const funeralHomes: FuneralHome[] = [ { diff --git a/temp/legacyImportFromCsv/data.ids.d.ts b/temp/legacyImportFromCsv/data.ids.d.ts index d48eea59..cbf75263 100644 --- a/temp/legacyImportFromCsv/data.ids.d.ts +++ b/temp/legacyImportFromCsv/data.ids.d.ts @@ -1,9 +1,9 @@ export declare const availableBurialSiteStatusId: number; export declare const reservedBurialSiteStatusId: number; export declare const takenBurialSiteStatusId: number; -export declare const preneedContractType: import("../../types/recordTypes.js").ContractType; -export declare const deceasedContractType: import("../../types/recordTypes.js").ContractType; -export declare const cremationContractType: import("../../types/recordTypes.js").ContractType; +export declare const preneedContractType: import("../../types/record.types.js").ContractType; +export declare const deceasedContractType: import("../../types/record.types.js").ContractType; +export declare const cremationContractType: import("../../types/record.types.js").ContractType; export declare const acknowledgedWorkOrderMilestoneTypeId: number | undefined; export declare const deathWorkOrderMilestoneTypeId: number | undefined; export declare const funeralWorkOrderMilestoneTypeId: number | undefined; diff --git a/temp/legacyImportFromCsv/index.ts b/temp/legacyImportFromCsv/index.ts index 8052a3af..59ba56e5 100644 --- a/temp/legacyImportFromCsv/index.ts +++ b/temp/legacyImportFromCsv/index.ts @@ -33,7 +33,7 @@ import reopenWorkOrder from '../../database/reopenWorkOrder.js' import { updateBurialSiteStatus } from '../../database/updateBurialSite.js' import { buildBurialSiteName } from '../../helpers/burialSites.helpers.js' import { sunriseDB as databasePath } from '../../helpers/database.helpers.js' -import type * as recordTypes from '../../types/recordTypes.js' +import type * as recordTypes from '../../types/record.types.js' import { getBurialSiteTypeId } from './data.burialSiteTypes.js' import { getCemeteryIdByKey } from './data.cemeteries.js' diff --git a/types/applicationTypes.d.ts b/types/application.types.d.ts similarity index 100% rename from types/applicationTypes.d.ts rename to types/application.types.d.ts diff --git a/types/applicationTypes.ts b/types/application.types.ts similarity index 100% rename from types/applicationTypes.ts rename to types/application.types.ts diff --git a/types/configTypes.d.ts b/types/config.types.d.ts similarity index 100% rename from types/configTypes.d.ts rename to types/config.types.d.ts diff --git a/types/configTypes.ts b/types/config.types.ts similarity index 100% rename from types/configTypes.ts rename to types/config.types.ts diff --git a/types/recordTypes.d.ts b/types/record.types.d.ts similarity index 97% rename from types/recordTypes.d.ts rename to types/record.types.d.ts index 101b35a6..ee293aec 100644 --- a/types/recordTypes.d.ts +++ b/types/record.types.d.ts @@ -334,19 +334,3 @@ export interface WorkOrderType extends Record { workOrderType?: string; orderNumber?: number; } -declare global { - export interface User { - userName: string; - userProperties?: UserProperties; - } -} -export interface UserProperties { - apiKey: string; - canUpdate: boolean; - isAdmin: boolean; -} -declare module 'express-session' { - interface Session { - user?: User; - } -} diff --git a/types/recordTypes.ts b/types/record.types.ts similarity index 96% rename from types/recordTypes.ts rename to types/record.types.ts index edfd36ac..a0b869ec 100644 --- a/types/recordTypes.ts +++ b/types/record.types.ts @@ -464,26 +464,3 @@ export interface WorkOrderType extends Record { orderNumber?: number } - -/* - * USER TYPES - */ - -declare global { - export interface User { - userName: string - userProperties?: UserProperties - } -} - -export interface UserProperties { - apiKey: string - canUpdate: boolean - isAdmin: boolean -} - -declare module 'express-session' { - interface Session { - user?: User - } -} diff --git a/types/user.types.d.ts b/types/user.types.d.ts new file mode 100644 index 00000000..cc360606 --- /dev/null +++ b/types/user.types.d.ts @@ -0,0 +1,16 @@ +declare global { + export interface User { + userName: string; + userProperties?: UserProperties; + } +} +export interface UserProperties { + apiKey: string; + canUpdate: boolean; + isAdmin: boolean; +} +declare module 'express-session' { + interface Session { + user?: User; + } +} diff --git a/types/user.types.ts b/types/user.types.ts new file mode 100644 index 00000000..2af0cdfa --- /dev/null +++ b/types/user.types.ts @@ -0,0 +1,18 @@ +declare global { + export interface User { + userName: string + userProperties?: UserProperties + } +} + +export interface UserProperties { + apiKey: string + canUpdate: boolean + isAdmin: boolean +} + +declare module 'express-session' { + interface Session { + user?: User + } +}