Skip to content

Commit

Permalink
[database] Fix, Removes the limit for the page size (apache#7987)
Browse files Browse the repository at this point in the history
Old FAB API had no limits by default, this will keep this behaviour
but only for this endpoint
  • Loading branch information
dpgaspar authored and mistercrunch committed Aug 6, 2019
1 parent 0c817e5 commit 8db419f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion superset/assets/src/components/TableSelector.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ export default class TableSelector extends React.PureComponent {
'/api/v1/database/?q=' +
'(keys:!(none),' +
'filters:!((col:expose_in_sqllab,opr:eq,value:!t)),' +
'order_columns:database_name,order_direction:asc)'
'order_columns:database_name,order_direction:asc,' +
'page:0,page_size:-1)'
}
onChange={this.onDatabaseChange}
onAsyncError={() => this.props.handleError(t('Error while fetching database list'))}
Expand Down
2 changes: 2 additions & 0 deletions superset/views/database/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ class DatabaseRestApi(DatabaseMixin, ModelRestApi):
"allows_subquery",
"backend",
]
# Removes the local limit for the page size
max_page_size = -1


appbuilder.add_api(DatabaseRestApi)

0 comments on commit 8db419f

Please sign in to comment.