mirror of
https://github.com/rgrgogu/new_starr.git
synced 2026-09-27 00:12:54 +08:00
Adjusted
This commit is contained in:
@@ -151,12 +151,13 @@ async function paginate(model, req, {
|
||||
const totalPages = Math.ceil(count / limit);
|
||||
|
||||
// ← Append computed metadata
|
||||
const computedMeta = computedAttributes.map(({ key, label, type, order: ord }) => ({
|
||||
const computedMeta = computedAttributes.map(({ key, label, type, order: ord, filterable }) => ({
|
||||
name: label ?? key,
|
||||
type: type ?? 'text',
|
||||
field: key,
|
||||
order: ord ?? Infinity,
|
||||
options: {},
|
||||
filterable: filterable
|
||||
}));
|
||||
|
||||
// ← Merge, sort, THEN strip order
|
||||
|
||||
Reference in New Issue
Block a user