Skip to content

Commit

Permalink
Fix disappearing tp segment
Browse files Browse the repository at this point in the history
  • Loading branch information
ysubtle committed Jun 22, 2017
1 parent a51a96b commit 77b2e9f
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion app/elements/plan-view/plan-view.html
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ <h1 class="header">RSS: <span>{{day_rss}}</span></h1>
});
}

if (block.block_repeat === 0) {
block.block_repeat = 1;
}

for (var p = 0; p < block.block_repeat; p++) {
for (var o = 0; o < block.segments.length; o++) {
var segment = block.segments[o];
Expand All @@ -173,6 +177,9 @@ <h1 class="header">RSS: <span>{{day_rss}}</span></h1>
magnitude = segment.duration_distance * 3;
}
}
if (segment.distance_unit_selected === 'km') {
magnitude = segment.duration_distance * 5;
}
if (segment.distance_unit_selected === 'meter') {
magnitude = segment.duration_distance / 100;
}
Expand Down Expand Up @@ -212,7 +219,7 @@ <h1 class="header">RSS: <span>{{day_rss}}</span></h1>
theme: 'stryd',
autoResize: true,
autoMarginOffset: 20,
marginBottom: 40,
marginBottom: 100,
valueAxes: [{
stackType: 'regular',
position: 'left',
Expand Down

0 comments on commit 77b2e9f

Please sign in to comment.