dashboard: add Import button to manage page

This commit is contained in:
Alexander Zobnin 2018-06-05 19:37:47 +03:00
parent 4063ae37a4
commit 393f41cd14
No known key found for this signature in database
GPG Key ID: E17E9ABACEFA59EB
2 changed files with 14 additions and 0 deletions

View File

@ -13,6 +13,10 @@
<i class="fa fa-plus"></i>
Folder
</a>
<a class="btn btn-success" href="{{ctrl.importDashboardUrl()}}" ng-if="ctrl.hasEditPermissionInFolders || ctrl.canSave">
<i class="fa fa-plus"></i>
Import
</a>
</div>
<div class="page-action-bar page-action-bar--narrow" ng-show="ctrl.hasFilters">

View File

@ -294,6 +294,16 @@ export class ManageDashboardsCtrl {
return url;
}
importDashboardUrl() {
let url = 'dashboard/import';
if (this.folderId) {
url += `?folderId=${this.folderId}`;
}
return url;
}
}
export function manageDashboardsDirective() {