Update Types
This commit is contained in:
parent
0d6b1d7e4c
commit
7dd8111b5b
21
package-shared/types/index.d.ts
vendored
21
package-shared/types/index.d.ts
vendored
@ -1174,26 +1174,31 @@ export type AuthFetchQuery = ServerQueryParam & {
|
|||||||
[key: string]: string | number | { [key: string]: any };
|
[key: string]: string | number | { [key: string]: any };
|
||||||
};
|
};
|
||||||
|
|
||||||
export type ServerQueryParamsJoin = {
|
export type ServerQueryParamsJoin<
|
||||||
|
Table extends string = string,
|
||||||
|
Field extends object = { [key: string]: any }
|
||||||
|
> = {
|
||||||
joinType: "INNER JOIN" | "JOIN" | "LEFT JOIN" | "RIGHT JOIN";
|
joinType: "INNER JOIN" | "JOIN" | "LEFT JOIN" | "RIGHT JOIN";
|
||||||
tableName: string;
|
tableName: Table;
|
||||||
match?:
|
match?:
|
||||||
| ServerQueryParamsJoinMatchObject
|
| ServerQueryParamsJoinMatchObject<Field>
|
||||||
| ServerQueryParamsJoinMatchObject[];
|
| ServerQueryParamsJoinMatchObject<Field>[];
|
||||||
selectFields?: (
|
selectFields?: (
|
||||||
| string
|
| keyof Field
|
||||||
| {
|
| {
|
||||||
field: string;
|
field: keyof Field;
|
||||||
alias?: string;
|
alias?: string;
|
||||||
}
|
}
|
||||||
)[];
|
)[];
|
||||||
};
|
};
|
||||||
|
|
||||||
export type ServerQueryParamsJoinMatchObject = {
|
export type ServerQueryParamsJoinMatchObject<
|
||||||
|
Field extends object = { [key: string]: any }
|
||||||
|
> = {
|
||||||
/** Field name from the **Root Table** */
|
/** Field name from the **Root Table** */
|
||||||
source: string | ServerQueryParamsJoinMatchSourceTargetObject;
|
source: string | ServerQueryParamsJoinMatchSourceTargetObject;
|
||||||
/** Field name from the **Join Table** */
|
/** Field name from the **Join Table** */
|
||||||
target: string | ServerQueryParamsJoinMatchSourceTargetObject;
|
target: keyof Field | ServerQueryParamsJoinMatchSourceTargetObject;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type ServerQueryParamsJoinMatchSourceTargetObject = {
|
export type ServerQueryParamsJoinMatchSourceTargetObject = {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@moduletrace/datasquirel",
|
"name": "@moduletrace/datasquirel",
|
||||||
"version": "2.5.6",
|
"version": "2.5.7",
|
||||||
"description": "Cloud-based SQL data management tool",
|
"description": "Cloud-based SQL data management tool",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"bin": {
|
"bin": {
|
||||||
|
Loading…
Reference in New Issue
Block a user