Class: VersionTimelineGroups

VersionTimelineGroups()

A collection of Backbone models, each representing a contiguous segment of versions for a specific date label/date.

Constructor

new VersionTimelineGroups()

Backbone collection representing grouped timeline entries for the version history view. Each group is a contiguous segment of versions in chain order that share the same calendar day (or "Unknown Date" label).
Since:
  • 2.37.0
Source:

Members

model

The model representing a group of versions for a specific date segment.
Source:

Methods

comparator(modelA, modelB) → {number}

Sort groups strictly by their segment sequence in chain order.
Parameters:
Name Type Description
modelA Backbone.Model First model.
modelB Backbone.Model Other model.
Source:
Returns:
Comparator result.
Type
number

fromDataONEObjects(collection, optionsopt)

Populate the collection from a DataONEObjects collection using strict obsolescence-chain order, segmented into contiguous date buckets.
Parameters:
Name Type Attributes Description
collection DataONEObjects DataONEObjects collection to group.
options object <optional>
Options passed to `set`.
Properties
Name Type Attributes Description
remove boolean <optional>
Whether to remove existing models.
referencePid string Reference PID used to order the chain via versionHistory indexes.
groupingTimeZone "local" | "UTC" <optional>
Timezone used to determine day boundaries.
Source: