Added parsing for partialMatch parameter in generateReadQuery function. To see all contents, send no params. To see exact matches, send no partialMatch param or send partialMatch: false. Send partialMatch: true to see all partial matches.

Additionally, moved parameter definitions out of paramLibrary into paramsConfig.json - you can now add/remove/change parameter data type definitions inside of this file. If you get a console error of "Unsupported Param Type" then you may need to also update paramLibrary with handling for the data type you're using- use the existing definitions in functions such as formatMSSQLParams as a guide.

Added testing for the partialMatch parameter to client.js.
This commit is contained in:
2025-08-21 22:10:50 -04:00
parent 136ce71a0e
commit 4e8998d5ed
5 changed files with 279 additions and 98 deletions

View File

@@ -61,7 +61,16 @@ async function testQuery(table, operation, params) {
} );
// READ: See all rows in a table
await testQuery('Test', 'READ');
await testQuery('Test', 'READ', {
Name: 'Tested item name',
});
// READ: See all rows in a table
await testQuery('Test', 'READ', {
partialMatch: true,
Name: 'Test',
});
// DELETE: Ensure the ID is present
await testQuery('Test', 'DELETE', {