@ -35,7 +35,10 @@
* /
import { PlatformServiceFactory } from "@/services/PlatformServiceFactory" ;
import type { PlatformService } from "@/services/PlatformService" ;
import type {
PlatformService ,
PlatformCapabilities ,
} from "@/services/PlatformService" ;
import { mapColumnsToValues , parseJsonField } from "@/db/databaseUtil" ;
import { MASTER_SETTINGS_KEY , type Settings } from "@/db/tables/settings" ;
import * as databaseUtil from "@/db/databaseUtil" ;
@ -671,9 +674,12 @@ export const PlatformServiceMixin = {
* /
export interface IPlatformServiceMixin {
platformService : PlatformService ;
$dbQuery ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbExec ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbGetOneRow ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbQuery (
sql : string ,
params? : unknown [ ] ,
) : Promise < QueryExecResult | undefined > ;
$dbExec ( sql : string , params? : unknown [ ] ) : Promise < DatabaseExecResult > ;
$dbGetOneRow ( sql : string , params? : unknown [ ] ) : Promise < unknown [ ] | undefined > ;
$getSettings (
key : string ,
fallback? : Settings | null ,
@ -687,7 +693,7 @@ export interface IPlatformServiceMixin {
isCapacitor : boolean ;
isWeb : boolean ;
isElectron : boolean ;
capabilities : any ;
capabilities : PlatformCapabilities ;
}
// TypeScript declaration merging to eliminate (this as any) type assertions
@ -698,7 +704,7 @@ declare module "@vue/runtime-core" {
isCapacitor : boolean ;
isWeb : boolean ;
isElectron : boolean ;
capabilities : any ;
capabilities : PlatformCapabilities ;
// Ultra-concise database methods (shortest possible names)
$db ( sql : string , params? : unknown [ ] ) : Promise < QueryExecResult | undefined > ;
@ -716,9 +722,15 @@ declare module "@vue/runtime-core" {
) : Promise < T | null > ;
// Enhanced utility methods
$dbQuery ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbExec ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbGetOneRow ( sql : string , params? : unknown [ ] ) : Promise < any > ;
$dbQuery (
sql : string ,
params? : unknown [ ] ,
) : Promise < QueryExecResult | undefined > ;
$dbExec ( sql : string , params? : unknown [ ] ) : Promise < DatabaseExecResult > ;
$dbGetOneRow (
sql : string ,
params? : unknown [ ] ,
) : Promise < unknown [ ] | undefined > ;
$getSettings (
key : string ,
defaults? : Settings | null ,