Major version update. Refactor sql generator function. Add core select directives like SUM, MIN, MAX, etc

This commit is contained in:
2026-04-18 07:24:01 +01:00
parent 0a3320ff83
commit f3f1c42699
23 changed files with 1275 additions and 662 deletions
+22
View File
@@ -0,0 +1,22 @@
import type { ServerQueryParam, TableSelectFieldsObject } from "../types";
type Param<T extends {
[key: string]: any;
} = {
[key: string]: any;
}> = {
genObject?: ServerQueryParam<T>;
selectFields?: (keyof T | TableSelectFieldsObject<T>)[];
append_table_names?: boolean;
table_name: string;
full_text_match_str?: string;
full_text_search_str?: string;
};
export default function sqlGenGenQueryStr<T extends {
[key: string]: any;
} = {
[key: string]: any;
}>(params: Param<T>): {
str: string;
values: any[];
};
export {};