diff --git a/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js b/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js
index 6694c87..7e7a409 100755
--- a/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js
+++ b/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js
@@ -683,6 +683,10 @@ module.controller('ClientListCtrl', function($scope, realm, clients, Client, ser
});
});
};
+
+ $scope.exportClient = function(client) {
+ saveAs(new Blob([angular.toJson(client, 4)], { type: 'application/json' }), client.clientId + '.json');
+ }
});
module.controller('ClientInstallationCtrl', function($scope, realm, client, serverInfo, ClientInstallation,$http, $routeParams) {
diff --git a/themes/src/main/resources/theme/base/admin/resources/partials/client-list.html b/themes/src/main/resources/theme/base/admin/resources/partials/client-list.html
index 9f08776..9bc8c95 100755
--- a/themes/src/main/resources/theme/base/admin/resources/partials/client-list.html
+++ b/themes/src/main/resources/theme/base/admin/resources/partials/client-list.html
@@ -7,7 +7,7 @@
<table class="table table-striped table-bordered">
<thead>
<tr>
- <th class="kc-table-actions" colspan="5">
+ <th class="kc-table-actions" colspan="6">
<div class="form-inline">
<div class="form-group">
<div class="input-group">
@@ -29,7 +29,7 @@
<th>{{:: 'client-id' | translate}}</th>
<th>{{:: 'enabled' | translate}}</th>
<th>{{:: 'base-url' | translate}}</th>
- <th colspan="2">{{:: 'actions' | translate}}</th>
+ <th colspan="3">{{:: 'actions' | translate}}</th>
</tr>
</thead>
<tbody>
@@ -44,6 +44,9 @@
<button class="btn btn-default btn-block btn-sm" kc-open="/realms/{{realm.realm}}/clients/{{client.id}}">{{:: 'edit' | translate}}</button>
</td>
<td class="kc-action-cell">
+ <button class="btn btn-default btn-block btn-sm" data-ng-click="exportClient(client)">{{:: 'export' | translate}}</button>
+ </td>
+ <td class="kc-action-cell">
<button class="btn btn-default btn-block btn-sm" data-ng-click="removeClient(client)">{{:: 'delete' | translate}}</button>
</td>
</tr>