From 6cd518e2fbe3e7fbc7dceb7692dc233152f51f7e Mon Sep 17 00:00:00 2001 From: Sebastian Eicke Date: Thu, 31 Oct 2024 14:46:04 +0100 Subject: [PATCH 1/4] Disable form inputs/buttons within GenericDataVisu --- .../src/components/SubmodelElements/Blob.vue | 14 ++++++-- .../components/SubmodelElements/Entity.vue | 11 +++++- .../src/components/SubmodelElements/File.vue | 14 ++++++-- .../MultiLanguageProperty.vue | 12 ++++++- .../components/SubmodelElements/Operation.vue | 13 ++++++- .../components/SubmodelElements/Property.vue | 23 ++++++++++++- .../src/components/SubmodelElements/Range.vue | 12 ++++++- .../SubmodelElements/ReferenceElement.vue | 22 ++++++++++-- .../SubmodelElements/RelationshipElement.vue | 11 +++++- .../ValueTypes/BooleanType.vue | 21 +++++++++++- .../ValueTypes/DateTimeStampType.vue | 20 ++++++++++- .../ValueTypes/NumberType.vue | 22 ++++++++++-- .../ValueTypes/StringType.vue | 20 ++++++++++- .../UIComponents/GenericDataVisu.vue | 34 +++++++++++++------ 14 files changed, 222 insertions(+), 27 deletions(-) diff --git a/aas-web-ui/src/components/SubmodelElements/Blob.vue b/aas-web-ui/src/components/SubmodelElements/Blob.vue index a9c6aee..722d091 100644 --- a/aas-web-ui/src/components/SubmodelElements/Blob.vue +++ b/aas-web-ui/src/components/SubmodelElements/Blob.vue @@ -35,6 +35,7 @@ density="compact" :hide-details="isTruncated ? false : true" clearable + :disabled="!isEditable" :hint="isTruncated ? 'Blob string is truncated!' : ''" persistent-hint @keydown.enter="updateBlob()" @@ -59,7 +60,7 @@ - + + @@ -32,7 +33,16 @@ RelationshipElement, // SubmodelElementWrapper, }, - props: ['annotatedRelationshipElementObject'], + props: { + annotatedRelationshipElementObject: { + type: Object, + default: () => ({}), + }, + isEditable: { + type: Boolean, + default: true, + }, + }, setup() { const SubmodelElementWrapper = shallowRef(null) as any; diff --git a/aas-web-ui/src/components/SubmodelElements/Blob.vue b/aas-web-ui/src/components/SubmodelElements/Blob.vue index 722d091..1fe4e73 100644 --- a/aas-web-ui/src/components/SubmodelElements/Blob.vue +++ b/aas-web-ui/src/components/SubmodelElements/Blob.vue @@ -34,8 +34,8 @@ variant="outlined" density="compact" :hide-details="isTruncated ? false : true" - clearable - :disabled="!isEditable" + :clearable="isEditable" + :readonly="!isEditable" :hint="isTruncated ? 'Blob string is truncated!' : ''" persistent-hint @keydown.enter="updateBlob()" @@ -44,7 +44,7 @@