mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-25 00:36:00 +00:00
perspectives: render simple table
This commit is contained in:
@@ -63,13 +63,20 @@
|
||||
// : null;
|
||||
|
||||
async function loader(props: PerspectiveDataLoadProps) {
|
||||
const { schemaName, pureName, bindingColumns, bindingValues } = props;
|
||||
const { schemaName, pureName, bindingColumns, bindingValues, dataColumns } = props;
|
||||
const select: Select = {
|
||||
commandType: 'select',
|
||||
from: {
|
||||
name: { schemaName, pureName },
|
||||
},
|
||||
selectAll: true,
|
||||
columns: dataColumns?.map(columnName => ({
|
||||
exprType: 'column',
|
||||
columnName,
|
||||
source: {
|
||||
name: { schemaName, pureName },
|
||||
},
|
||||
})),
|
||||
selectAll: !dataColumns,
|
||||
};
|
||||
if (bindingColumns?.length == 1) {
|
||||
select.where = {
|
||||
|
||||
Reference in New Issue
Block a user