mirror of
https://github.com/nasa/openmct.git
synced 2025-05-31 14:40:48 +00:00
timesystem works
This commit is contained in:
parent
87dc272a5a
commit
df3ca84fda
@ -9,7 +9,7 @@ export default class CompsManager extends EventEmitter {
|
|||||||
#dataFrame = {};
|
#dataFrame = {};
|
||||||
#batchedNewData = {};
|
#batchedNewData = {};
|
||||||
#batchPromises = {};
|
#batchPromises = {};
|
||||||
#BATCH_DEBOUNCE_MS = 100;
|
#BATCH_DEBOUNCE_MS = 1;
|
||||||
#telemetryLoadedPromises = [];
|
#telemetryLoadedPromises = [];
|
||||||
|
|
||||||
constructor(openmct, domainObject) {
|
constructor(openmct, domainObject) {
|
||||||
@ -23,9 +23,9 @@ export default class CompsManager extends EventEmitter {
|
|||||||
const metaData = this.#openmct.telemetry.getMetadata(telemetryObject);
|
const metaData = this.#openmct.telemetry.getMetadata(telemetryObject);
|
||||||
const specificTelemetryCollection = this.#telemetryCollections[keyString];
|
const specificTelemetryCollection = this.#telemetryCollections[keyString];
|
||||||
const specificTimeKey = specificTelemetryCollection.timeKey;
|
const specificTimeKey = specificTelemetryCollection.timeKey;
|
||||||
const timeMetaData = metaData.valueMetadatas.find(
|
const timeMetaData = metaData.valueMetadatas.find((metaDatum) => {
|
||||||
(metaDatum) => metaDatum.key === specificTimeKey
|
return metaDatum.key === specificTimeKey || metaDatum.source === specificTimeKey;
|
||||||
);
|
});
|
||||||
const random4Digit = Math.floor(1000 + Math.random() * 9000);
|
const random4Digit = Math.floor(1000 + Math.random() * 9000);
|
||||||
this.#domainObject.configuration.comps.parameters.push({
|
this.#domainObject.configuration.comps.parameters.push({
|
||||||
keyString,
|
keyString,
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
* this source code distribution or the Licensing information page available
|
* this source code distribution or the Licensing information page available
|
||||||
* at runtime from the About dialog for additional information.
|
* at runtime from the About dialog for additional information.
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
import CompsManager from './CompsManager.js';
|
||||||
|
|
||||||
export default class CompsMetadataProvider {
|
export default class CompsMetadataProvider {
|
||||||
#openmct = null;
|
#openmct = null;
|
||||||
@ -47,8 +48,11 @@ export default class CompsMetadataProvider {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getMetadata(domainObject) {
|
getMetadata(domainObject) {
|
||||||
const keyString = this.#openmct.objects.makeKeyString(domainObject.identifier);
|
const specificCompsManager = CompsManager.getCompsManager(
|
||||||
const specificCompsManager = this.#compsManagerPool[keyString];
|
domainObject,
|
||||||
|
this.#openmct,
|
||||||
|
this.#compsManagerPool
|
||||||
|
);
|
||||||
console.debug('📦 CompsMetadataProvider: getMetadata', specificCompsManager);
|
console.debug('📦 CompsMetadataProvider: getMetadata', specificCompsManager);
|
||||||
// if there are any parameters, grab the first one's timeMetaData
|
// if there are any parameters, grab the first one's timeMetaData
|
||||||
const timeMetaData = specificCompsManager?.getParameters()[0]?.timeMetaData;
|
const timeMetaData = specificCompsManager?.getParameters()[0]?.timeMetaData;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user