Browse Source

Merge branch 'related-entities-aggregation' of github.com:irynamatveieva/thingsboard into related-entities-aggregation

pull/14280/head
IrynaMatveieva 9 months ago
parent
commit
622ab42a00
  1. 2
      ui-ngx/src/app/modules/home/components/calculated-fields/components/related-entities-aggregation-configuration/related-entities-aggregation-component.component.ts
  2. 1
      ui-ngx/src/app/shared/models/calculated-field.models.ts

2
ui-ngx/src/app/modules/home/components/calculated-fields/components/related-entities-aggregation-configuration/related-entities-aggregation-component.component.ts

@ -105,6 +105,7 @@ export class RelatedEntitiesAggregationComponentComponent implements ControlValu
map(argumentsObj => getCalculatedFieldArgumentsHighlights(argumentsObj))
);
private readonly minAllowedScheduledUpdateIntervalInSecForCF = getCurrentAuthState(this.store).minAllowedScheduledUpdateIntervalInSecForCF;
private propagateChange: (config: CalculatedFieldRelatedAggregationConfiguration) => void = () => { };
constructor(private fb: FormBuilder,
@ -149,6 +150,7 @@ export class RelatedEntitiesAggregationComponentComponent implements ControlValu
private updatedModel(value: CalculatedFieldRelatedAggregationConfiguration): void {
value.type = CalculatedFieldType.RELATED_ENTITIES_AGGREGATION;
value.scheduledUpdateInterval = this.minAllowedScheduledUpdateIntervalInSecForCF;
this.propagateChange(value);
}
}

1
ui-ngx/src/app/shared/models/calculated-field.models.ts

@ -142,6 +142,7 @@ export interface CalculatedFieldRelatedAggregationConfiguration {
arguments: Record<string, CalculatedFieldArgument>;
metrics: Record<string, CalculatedFieldAggMetric>;
deduplicationIntervalInSec: number;
scheduledUpdateInterval?: number;
useLatestTs: boolean;
output: CalculatedFieldOutput & { decimalsByDefault?: number; };
}

Loading…
Cancel
Save