Allow database stats downloads (#738)
* Add button to download database stats * Return xml as well
This commit is contained in:
@@ -660,7 +660,7 @@ function showPaginatedTableContent() {
|
||||
showTableContent(sortColumn, sortOrder);
|
||||
}
|
||||
|
||||
function showTablesStats() {
|
||||
function showDatabaseStats() {
|
||||
getTablesStats(function(data) {
|
||||
buildTable(data);
|
||||
|
||||
@@ -671,6 +671,10 @@ function showTablesStats() {
|
||||
});
|
||||
}
|
||||
|
||||
function downloadDatabaseStats() {
|
||||
openInNewWindow("api/tables_stats", { format: "csv", export: "true" });
|
||||
}
|
||||
|
||||
function showTableStructure() {
|
||||
var name = getCurrentObject().name;
|
||||
|
||||
@@ -1267,8 +1271,11 @@ function bindCurrentDatabaseMenu() {
|
||||
var menuItem = $(e.target);
|
||||
|
||||
switch(menuItem.data("action")) {
|
||||
case "show_tables_stats":
|
||||
showTablesStats();
|
||||
case "show_db_stats":
|
||||
showDatabaseStats();
|
||||
break;
|
||||
case "download_db_stats":
|
||||
downloadDatabaseStats();
|
||||
break;
|
||||
case "export":
|
||||
openInNewWindow("api/export");
|
||||
|
||||
Reference in New Issue
Block a user