Updates
This commit is contained in:
@@ -349,7 +349,7 @@ export default function sqlGenerator<
|
||||
|
||||
return genSqlSrchStr({
|
||||
queryObj: newSubQueryObj,
|
||||
field: _field,
|
||||
field: newSubQueryObj.fieldName || _field,
|
||||
join: genObject?.join,
|
||||
});
|
||||
});
|
||||
@@ -361,7 +361,11 @@ export default function sqlGenerator<
|
||||
);
|
||||
}
|
||||
|
||||
return genSqlSrchStr({ queryObj, field, join: genObject?.join });
|
||||
return genSqlSrchStr({
|
||||
queryObj,
|
||||
field: queryObj.fieldName || field,
|
||||
join: genObject?.join,
|
||||
});
|
||||
});
|
||||
|
||||
const cleanedUpSearchStr = sqlSearhString?.filter(
|
||||
|
||||
@@ -1108,6 +1108,11 @@ export type ServerQueryObject<
|
||||
operator?: (typeof ServerQueryOperators)[number];
|
||||
equality?: (typeof ServerQueryEqualities)[number];
|
||||
tableName?: K;
|
||||
/**
|
||||
* This will replace the top level field name if
|
||||
* provided
|
||||
*/
|
||||
fieldName?: string;
|
||||
__query?: {
|
||||
[key in keyof T]: Omit<ServerQueryObject<T>, "__query">;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user