Skip to content

Commit 1aff1a5

Browse files
committed
Sort record ontology properties by canonical order (#293 #353)
1 parent 7d0057b commit 1aff1a5

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

frontend/vre/utils/record-ontology.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,17 @@
55
import _ from 'lodash';
66
import { FilteredCollection } from './filtered.collection.js';
77
import { JsonLdNestedCollection } from './jsonld.model';
8+
import { canonicalSort } from './generic-functions.js';
89

910
/**
1011
* A Backbone collection to access the properties defined by the ontology.
1112
*/
1213
export var PropertyList = JsonLdNestedCollection.extend({
1314
url: "/static/edpop-record-ontology.json",
1415
targetClass: "rdf:Property",
16+
comparator: function(item) {
17+
return canonicalSort(item.id);
18+
},
1519
});
1620

1721
export var properties = new PropertyList();

0 commit comments

Comments
 (0)