mirror of
https://github.com/nasa/openmct.git
synced 2025-06-19 07:38:15 +00:00
[Time Conductor] Support index domain from sine wave
This commit is contained in:
@ -49,6 +49,11 @@ define(
|
|||||||
Math.max(Math.floor(request.start / 1000), firstTime),
|
Math.max(Math.floor(request.start / 1000), firstTime),
|
||||||
offset = requestStart - firstTime;
|
offset = requestStart - firstTime;
|
||||||
|
|
||||||
|
if (request.domain === 'index') {
|
||||||
|
offset = Math.floor(request.start || 0);
|
||||||
|
count = Math.ceil(request.end || endTime);
|
||||||
|
}
|
||||||
|
|
||||||
if (request.size !== undefined) {
|
if (request.size !== undefined) {
|
||||||
offset = Math.max(offset, count - request.size);
|
offset = Math.max(offset, count - request.size);
|
||||||
}
|
}
|
||||||
@ -59,7 +64,7 @@ define(
|
|||||||
|
|
||||||
generatorData.getDomainValue = function (i, domain) {
|
generatorData.getDomainValue = function (i, domain) {
|
||||||
if (domain === 'index') {
|
if (domain === 'index') {
|
||||||
return i;
|
return i + offset;
|
||||||
}
|
}
|
||||||
return (i + offset) * 1000 + firstTime * 1000 -
|
return (i + offset) * 1000 + firstTime * 1000 -
|
||||||
(domain === 'yesterday' ? ONE_DAY : 0);
|
(domain === 'yesterday' ? ONE_DAY : 0);
|
||||||
|
Reference in New Issue
Block a user