forked from trent_larson/crowd-funder-for-time-pwa
Complete Enhanced Triple Migration Pattern for contact components
- Migrate ContactBulkActions, ContactInputForm, ContactListHeader, ContactListItem, LargeIdenticonModal, and ContactsView to PlatformServiceMixin - Add comprehensive deep linking support to CapacitorPlatformService and WebPlatformService - Enhance PlatformService with new database operations and deep link handling - Update service worker and documentation for migration progress - Fix TypeScript type errors in util.ts and deepLinks.ts - Streamline circular dependency analysis and migration tracking docs
This commit is contained in:
@@ -155,6 +155,49 @@ export interface PlatformService {
|
||||
*/
|
||||
dbGetOneRow(sql: string, params?: unknown[]): Promise<unknown[] | undefined>;
|
||||
|
||||
// Database utility methods
|
||||
/**
|
||||
* Generates an INSERT SQL statement for a given model and table.
|
||||
* @param model - The model object containing the data to insert
|
||||
* @param tableName - The name of the table to insert into
|
||||
* @returns Object containing the SQL statement and parameters
|
||||
*/
|
||||
generateInsertStatement(
|
||||
model: Record<string, unknown>,
|
||||
tableName: string,
|
||||
): { sql: string; params: unknown[] };
|
||||
|
||||
/**
|
||||
* Updates default settings in the database.
|
||||
* @param settings - The settings object to update
|
||||
* @returns Promise that resolves when the update is complete
|
||||
*/
|
||||
updateDefaultSettings(settings: Record<string, unknown>): Promise<void>;
|
||||
|
||||
/**
|
||||
* Inserts DID-specific settings into the database.
|
||||
* @param did - The DID to associate with the settings
|
||||
* @returns Promise that resolves when the insertion is complete
|
||||
*/
|
||||
insertDidSpecificSettings(did: string): Promise<void>;
|
||||
|
||||
/**
|
||||
* Updates DID-specific settings in the database.
|
||||
* @param did - The DID to update settings for
|
||||
* @param settings - The settings object to update
|
||||
* @returns Promise that resolves when the update is complete
|
||||
*/
|
||||
updateDidSpecificSettings(
|
||||
did: string,
|
||||
settings: Record<string, unknown>,
|
||||
): Promise<void>;
|
||||
|
||||
/**
|
||||
* Retrieves settings for the active account.
|
||||
* @returns Promise resolving to the settings object
|
||||
*/
|
||||
retrieveSettingsForActiveAccount(): Promise<Record<string, unknown> | null>;
|
||||
|
||||
// --- PWA/Web-only methods (optional, only implemented on web) ---
|
||||
/**
|
||||
* Registers the service worker for PWA support (web only)
|
||||
|
||||
Reference in New Issue
Block a user