mirror of
https://github.com/nasa/openmct.git
synced 2025-04-19 08:36:24 +00:00
Should not show editable views for objects in flexible layout and display layout (#2304)
* fix issue where editable summary widget view shows up in display layout and flexible layout * keep consistent kebab case for props
This commit is contained in:
parent
6338bd1168
commit
95549f7be2
@ -27,6 +27,7 @@
|
||||
:domain-object="domainObject"
|
||||
:object-path="objectPath"
|
||||
:has-frame="item.hasFrame"
|
||||
:show-edit-view="false"
|
||||
ref="objectFrame">
|
||||
</object-frame>
|
||||
</layout-frame>
|
||||
|
@ -36,6 +36,7 @@
|
||||
:domain-object="domainObject"
|
||||
:object-path="objectPath"
|
||||
:has-frame="hasFrame"
|
||||
:show-edit-view="false"
|
||||
ref="objectFrame">
|
||||
</object-frame>
|
||||
|
||||
|
@ -42,9 +42,12 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<object-view class="c-so-view__object-view"
|
||||
ref="objectView"
|
||||
:object="domainObject"></object-view>
|
||||
<object-view
|
||||
class="c-so-view__object-view"
|
||||
ref="objectView"
|
||||
:object="domainObject"
|
||||
:show-edit-view="showEditView">
|
||||
</object-view>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -128,6 +131,10 @@
|
||||
domainObject: Object,
|
||||
objectPath: Array,
|
||||
hasFrame: Boolean,
|
||||
showEditView: {
|
||||
type: Boolean,
|
||||
default: () => true
|
||||
}
|
||||
},
|
||||
components: {
|
||||
ObjectView,
|
||||
|
@ -8,7 +8,8 @@ export default {
|
||||
inject: ["openmct"],
|
||||
props: {
|
||||
view: String,
|
||||
object: Object
|
||||
object: Object,
|
||||
showEditView: Boolean
|
||||
},
|
||||
destroyed() {
|
||||
this.clear();
|
||||
@ -79,7 +80,7 @@ export default {
|
||||
}
|
||||
|
||||
|
||||
if (provider.edit) {
|
||||
if (provider.edit && this.showEditView) {
|
||||
if (this.openmct.editor.isEditing()) {
|
||||
this.currentView = provider.edit(this.currentObject);
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user