mirror of
https://github.com/nasa/openmct.git
synced 2025-02-15 07:02:28 +00:00
refactor: move to created
hook, remove initialize function
This commit is contained in:
parent
0d5041d289
commit
417ff41331
@ -199,21 +199,6 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.initialize();
|
||||
|
||||
this.status = this.openmct.status.get(this.series.domainObject.identifier);
|
||||
this.removeStatusListener = this.openmct.status.observe(
|
||||
this.series.domainObject.identifier,
|
||||
this.setStatus
|
||||
);
|
||||
},
|
||||
beforeUnmount() {
|
||||
if (this.removeStatusListener) {
|
||||
this.removeStatusListener();
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
initialize() {
|
||||
this.fields = [
|
||||
{
|
||||
modelProp: 'yKey',
|
||||
@ -261,7 +246,19 @@ export default {
|
||||
value: key
|
||||
};
|
||||
});
|
||||
|
||||
this.status = this.openmct.status.get(this.series.domainObject.identifier);
|
||||
this.removeStatusListener = this.openmct.status.observe(
|
||||
this.series.domainObject.identifier,
|
||||
this.setStatus
|
||||
);
|
||||
},
|
||||
beforeUnmount() {
|
||||
if (this.removeStatusListener) {
|
||||
this.removeStatusListener();
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
dynamicPathForKey(key) {
|
||||
return function (object, model) {
|
||||
const modelIdentifier = model.get('identifier');
|
||||
|
Loading…
x
Reference in New Issue
Block a user