fix: getRecords action page→take/skip + prisma engine fix + CLI fixes
- getRecords automation action: translate page/pageSize to skip/take
before calling the records API (which ignores page/pageSize, causing
pagination to always return first 100 records)
- Add postbuild script to restore correct prisma engine binary after
nest build (which generates an incompatible engine causing SIGSEGV)
- CLI fixes (from earlier commits):
- deleteRecords: query params instead of JSON body
- deleteTable: add /base/{baseId} prefix
This commit is contained in:
Vendored
+15
-5
@@ -110,7 +110,10 @@ function tableCmd() {
|
||||
(0, output_1.printJson)(table);
|
||||
else {
|
||||
const t = table;
|
||||
(0, output_1.printKv)([['id', t.id], ['name', t.name]]);
|
||||
(0, output_1.printKv)([
|
||||
['id', t.id],
|
||||
['name', t.name],
|
||||
]);
|
||||
}
|
||||
}));
|
||||
cmd
|
||||
@@ -197,7 +200,11 @@ function fieldCmd() {
|
||||
(0, output_1.printJson)(field);
|
||||
else {
|
||||
const f = field;
|
||||
(0, output_1.printKv)([['id', f.id], ['name', f.name], ['type', f.type]]);
|
||||
(0, output_1.printKv)([
|
||||
['id', f.id],
|
||||
['name', f.name],
|
||||
['type', f.type],
|
||||
]);
|
||||
}
|
||||
}));
|
||||
cmd
|
||||
@@ -364,8 +371,7 @@ function recordCmd() {
|
||||
.split(',')
|
||||
.map((s) => s.trim())
|
||||
.filter(Boolean);
|
||||
const body = { records: ids };
|
||||
const result = await ctx.client.deleteRecord(opts.tableId, body);
|
||||
const result = await ctx.client.deleteRecords(opts.tableId, ids);
|
||||
if (ctx.json)
|
||||
(0, output_1.printJson)(result);
|
||||
else
|
||||
@@ -428,7 +434,11 @@ function viewCmd() {
|
||||
(0, output_1.printJson)(view);
|
||||
else {
|
||||
const v = view;
|
||||
(0, output_1.printKv)([['id', v.id], ['name', v.name], ['type', v.type]]);
|
||||
(0, output_1.printKv)([
|
||||
['id', v.id],
|
||||
['name', v.name],
|
||||
['type', v.type],
|
||||
]);
|
||||
}
|
||||
}));
|
||||
cmd
|
||||
|
||||
Reference in New Issue
Block a user