LT-275: Adding button to add labels to measurements

This commit is contained in:
Bruno Alves de Faria authored and Erik Ziegler committed 2016-11-15 08:24:30 +01:00
1 parent b1eb68521a
commit 3f0b9482d1
13 files changed
+77 -13

No files matched your search

@@ -64,9 +64,9 @@ Template.selectTree.onRendered(() => {
instance.component = component;
// Set the margin to display the common section
const isTreeColumns = instance.data.treeColumns;
const marginProperty = isTreeColumns ? 'margin-left' : 'margin-right';
const marginWidth = isTreeColumns ? $treeRoot.width() / 2 : $treeRoot.width();
const isthreeColumns = instance.data.threeColumns;
const marginProperty = isthreeColumns ? 'margin-left' : 'margin-right';
const marginWidth = isthreeColumns ? $treeRoot.width() / 2 : $treeRoot.width();
$treeRoot.children('.tree-content').css(marginProperty, marginWidth);
// Make the component respect the window boundaries
@@ -318,7 +318,7 @@ Template.selectTree.helpers({
}
// Return the items sorted for tree columns
if (instance.data.treeColumns) {
if (instance.data.threeColumns) {
const begin = items.splice(0, Math.ceil(items.length / 2));
const sortedItems = [];
_.each(begin, (item, index) => {