mirror of
https://github.com/nasa/openmct.git
synced 2025-05-28 21:24:20 +00:00
WIP renaming
This commit is contained in:
parent
7981424e9a
commit
ad64f00608
@ -20,16 +20,16 @@
|
|||||||
* at runtime from the About dialog for additional information.
|
* at runtime from the About dialog for additional information.
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
import ConditionCollectionComponent from './components/ConditionCollection.vue';
|
import ConditionSetComponent from './components/ConditionSet.vue';
|
||||||
import Vue from 'vue';
|
import Vue from 'vue';
|
||||||
|
|
||||||
export default function ConditionCollection(openmct) {
|
export default function ConditionSet(openmct) {
|
||||||
return {
|
return {
|
||||||
key: 'conditionCollection',
|
key: 'conditionSet',
|
||||||
name: 'Condition Set',
|
name: 'Condition Set',
|
||||||
cssClass: 'icon-page',
|
cssClass: 'icon-summary-widget',
|
||||||
canView: function (domainObject) {
|
canView: function (domainObject) {
|
||||||
return domainObject.type === 'conditionCollection';
|
return domainObject.type === 'conditionSet';
|
||||||
},
|
},
|
||||||
view: function (domainObject) {
|
view: function (domainObject) {
|
||||||
let component;
|
let component;
|
||||||
@ -39,13 +39,13 @@ export default function ConditionCollection(openmct) {
|
|||||||
component = new Vue({
|
component = new Vue({
|
||||||
el: element,
|
el: element,
|
||||||
components: {
|
components: {
|
||||||
ConditionCollectionComponent
|
ConditionSetComponent
|
||||||
},
|
},
|
||||||
provide: {
|
provide: {
|
||||||
openmct,
|
openmct,
|
||||||
domainObject
|
domainObject
|
||||||
},
|
},
|
||||||
template: '<condition-collection-component></condition-collection-component>'
|
template: '<condition-set-component></condition-set-component>'
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
destroy: function (element) {
|
destroy: function (element) {
|
@ -1,60 +0,0 @@
|
|||||||
/*****************************************************************************
|
|
||||||
* Open MCT, Copyright (c) 2014-2019, United States Government
|
|
||||||
* as represented by the Administrator of the National Aeronautics and Space
|
|
||||||
* Administration. All rights reserved.
|
|
||||||
*
|
|
||||||
* Open MCT is licensed under the Apache License, Version 2.0 (the
|
|
||||||
* "License"); you may not use this file except in compliance with the License.
|
|
||||||
* You may obtain a copy of the License at
|
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0.
|
|
||||||
*
|
|
||||||
* Unless required by applicable law or agreed to in writing, software
|
|
||||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
||||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
||||||
* License for the specific language governing permissions and limitations
|
|
||||||
* under the License.
|
|
||||||
*
|
|
||||||
* Open MCT includes source code licensed under additional open source
|
|
||||||
* licenses. See the Open Source Licenses file (LICENSES.md) included with
|
|
||||||
* this source code distribution or the Licensing information page available
|
|
||||||
* at runtime from the About dialog for additional information.
|
|
||||||
*****************************************************************************/
|
|
||||||
|
|
||||||
import ConditionComponent from './components/Condition.vue';
|
|
||||||
import Vue from 'vue';
|
|
||||||
|
|
||||||
export default function Condition(openmct) {
|
|
||||||
return {
|
|
||||||
key: 'condition',
|
|
||||||
name: 'Condition',
|
|
||||||
cssClass: 'icon-summary-widget',
|
|
||||||
canView: (domainObject => {
|
|
||||||
return domainObject.type === 'condition';
|
|
||||||
}),
|
|
||||||
view: (domainObject => {
|
|
||||||
let component;
|
|
||||||
|
|
||||||
return {
|
|
||||||
show: (element => {
|
|
||||||
component = new Vue({
|
|
||||||
el: element,
|
|
||||||
components: {
|
|
||||||
ConditionComponent
|
|
||||||
},
|
|
||||||
provide: {
|
|
||||||
openmct,
|
|
||||||
domainObject
|
|
||||||
},
|
|
||||||
template: '<condition-component></condition-component>'
|
|
||||||
});
|
|
||||||
}),
|
|
||||||
destroy: (element => {
|
|
||||||
component.$destroy();
|
|
||||||
component = undefined;
|
|
||||||
})
|
|
||||||
};
|
|
||||||
}),
|
|
||||||
priority: (() => { 1 });
|
|
||||||
}
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,7 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="l-iframe abs">
|
<div><!-- Condition Set component contents will go here --></div>
|
||||||
<iframe :src="currentDomainObject.url"></iframe>
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
@ -20,10 +20,10 @@
|
|||||||
* at runtime from the About dialog for additional information.
|
* at runtime from the About dialog for additional information.
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
export default function ConditionPlugin() {
|
export default function ConditionSetPlugin() {
|
||||||
const conditionType = {
|
const conditionSetType = {
|
||||||
name: 'Condition',
|
name: 'Condition Set',
|
||||||
description: 'A conditional rule based on user-specified criteria.',
|
description: 'A set of one or more conditional rules based on user-specified criteria.',
|
||||||
creatable: true,
|
creatable: true,
|
||||||
cssClass: 'icon-summary-widget',
|
cssClass: 'icon-summary-widget',
|
||||||
initialize: function (domainObject) {
|
initialize: function (domainObject) {
|
||||||
@ -33,6 +33,6 @@ export default function ConditionPlugin() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return function install(openmct) {
|
return function install(openmct) {
|
||||||
openmct.types.addType('condition', conditionType);
|
openmct.types.addType('conditionSet', conditionSetType);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user