datasquirel/dist/package-shared/functions/backend/db/updateDbEntry.d.ts
Benjamin Toby 3597b11342 Updates
2025-07-05 18:17:35 +01:00

26 lines
872 B
TypeScript

import { DbContextsArray } from "./runQuery";
import { APIResponseObject, DSQL_TableSchemaType, PostInsertReturn } from "../../../types";
type Param<T extends {
[k: string]: any;
} = any> = {
dbContext?: (typeof DbContextsArray)[number];
dbFullName?: string;
tableName: string;
encryptionKey?: string;
encryptionSalt?: string;
data?: T;
tableSchema?: DSQL_TableSchemaType;
identifierColumnName: keyof T;
identifierValue: string | number;
forceLocal?: boolean;
debug?: boolean;
};
/**
* # Update DB Function
* @description
*/
export default function updateDbEntry<T extends {
[k: string]: any;
} = any>({ dbContext, dbFullName, tableName, data, tableSchema, identifierColumnName, identifierValue, encryptionKey, encryptionSalt, forceLocal, debug, }: Param<T>): Promise<APIResponseObject<PostInsertReturn>>;
export {};