summaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/view-models/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'catalog-ui/src/app/view-models/plugins')
-rw-r--r--catalog-ui/src/app/view-models/plugins/plugins-tab-view-model.ts6
-rw-r--r--catalog-ui/src/app/view-models/plugins/plugins-tab-view.html5
-rw-r--r--catalog-ui/src/app/view-models/plugins/plugins-tab.less10
3 files changed, 18 insertions, 3 deletions
diff --git a/catalog-ui/src/app/view-models/plugins/plugins-tab-view-model.ts b/catalog-ui/src/app/view-models/plugins/plugins-tab-view-model.ts
index 438cf4a60c..cb3f842648 100644
--- a/catalog-ui/src/app/view-models/plugins/plugins-tab-view-model.ts
+++ b/catalog-ui/src/app/view-models/plugins/plugins-tab-view-model.ts
@@ -30,11 +30,15 @@ export class PluginsTabViewModel {
}
private initScope = ():void => {
- this.$scope.isLoading = true;
this.$scope.plugin = this.pluginsService.getPluginByStateUrl(this.$stateParams.path);
this.$scope.version = this.cacheService.get('version');
this.$scope.user = this.cacheService.get('user');
+ // Don't show the loader if the plugin isn't online
+ if (this.$scope.plugin.isOnline) {
+ this.$scope.isLoading = true;
+ }
+
this.$scope.queryParams = {
userId: this.$scope.user.userId,
userRole: this.$scope.user.role,
diff --git a/catalog-ui/src/app/view-models/plugins/plugins-tab-view.html b/catalog-ui/src/app/view-models/plugins/plugins-tab-view.html
index bc404b46d1..6ee4855a4c 100644
--- a/catalog-ui/src/app/view-models/plugins/plugins-tab-view.html
+++ b/catalog-ui/src/app/view-models/plugins/plugins-tab-view.html
@@ -1,5 +1,6 @@
-<div class="sdc-catalog-container">
+<div class="sdc-catalog-container plugins-tab-container">
<loader display="isLoading"></loader>
<top-nav [version]="version" [hide-search]="true"></top-nav>
- <plugin-frame (on-loading-done)="onLoadingDone(plugin)" [plugin]="plugin" [query-params]="queryParams"></plugin-frame>
+ <plugin-frame data-ng-if="plugin.isOnline" (on-loading-done)="onLoadingDone(plugin)" [plugin]="plugin" [query-params]="queryParams"></plugin-frame>
+ <div class="offline-plugin-message" data-ng-if="!plugin.isOnline">The plugin {{plugin.pluginId}} is offline. Please try again later</div>
</div>
diff --git a/catalog-ui/src/app/view-models/plugins/plugins-tab.less b/catalog-ui/src/app/view-models/plugins/plugins-tab.less
new file mode 100644
index 0000000000..f821041436
--- /dev/null
+++ b/catalog-ui/src/app/view-models/plugins/plugins-tab.less
@@ -0,0 +1,10 @@
+.plugins-tab-container {
+
+ text-align: center;
+
+ .offline-plugin-message {
+ top: 50px;
+ position: relative;
+ display: inline-block;
+ }
+}