frontend CHANGE cosmetic changes in displaying configuration data
diff --git a/frontend/config/tree-node.html b/frontend/config/tree-node.html
index d17b842..32bec85 100644
--- a/frontend/config/tree-node.html
+++ b/frontend/config/tree-node.html
@@ -52,8 +52,9 @@
<!-- leaf -->
<ng-container *ngIf="node['info']['type'] == 4">
- <span class="value_inline" *ngIf="!node['edit']" (click)="startEditing(node, $event.target);">{{node['value']}}</span>
- <span class="value_inline" *ngIf="node['edit']">{{node['info']['datatype']}}
+ <span *ngIf="!node['edit']" class="value_inline" [class.keys]="!isEditable(node)" [class.editable]="isEditable(node)"
+ (click)="startEditing(node, $event.target);">{{node['value']}}</span>
+ <span *ngIf="node['edit']" class="value_inline">{{node['info']['datatype']}}
<span *ngIf="node['info']['datatype'] != node['info']['datatypebase']">({{node['info']['datatypebase']}})</span>
</span>
</ng-container>
diff --git a/frontend/config/tree.component.scss b/frontend/config/tree.component.scss
index aaf0c99..2d590b4 100644
--- a/frontend/config/tree.component.scss
+++ b/frontend/config/tree.component.scss
@@ -60,6 +60,10 @@
background-color: $colorChanged;;
}
+.editable {
+ cursor: pointer;
+}
+
.status,
.keys {
color: grey;
diff --git a/frontend/config/tree.component.ts b/frontend/config/tree.component.ts
index c4eb01e..200782d 100644
--- a/frontend/config/tree.component.ts
+++ b/frontend/config/tree.component.ts
@@ -313,8 +313,15 @@
}
}
- startEditing(node, target) {
+ isEditable(node) {
if ((node['info']['key'] && !node['new']) || node['deleted']) {
+ return false;
+ }
+ return true;
+ }
+
+ startEditing(node, target) {
+ if (!this.isEditable(node)) {
return;
}