working on counter
This commit is contained in:
@@ -99,6 +99,8 @@
|
|||||||
<input type="range" min="0" max="{{ maxtime }}" value="{{ analysis.delay }}"
|
<input type="range" min="0" max="{{ maxtime }}" value="{{ analysis.delay }}"
|
||||||
id="myRange">
|
id="myRange">
|
||||||
</div>
|
</div>
|
||||||
|
<div id="dataplay"></div>
|
||||||
|
<div id="datastop"></div>
|
||||||
</li>
|
</li>
|
||||||
<li class="grid_2">
|
<li class="grid_2">
|
||||||
<div id="player"></div>
|
<div id="player"></div>
|
||||||
@@ -304,6 +306,7 @@
|
|||||||
$(document).ready( function() {
|
$(document).ready( function() {
|
||||||
// lock
|
// lock
|
||||||
var lock = document.getElementById("lock");
|
var lock = document.getElementById("lock");
|
||||||
|
// lock.onchange nog doen
|
||||||
var output = document.getElementById("id_delay");
|
var output = document.getElementById("id_delay");
|
||||||
{% if locked %}
|
{% if locked %}
|
||||||
lock.checked = true;
|
lock.checked = true;
|
||||||
@@ -468,7 +471,54 @@
|
|||||||
} else {
|
} else {
|
||||||
output.disabled = false;
|
output.disabled = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
// Slider start stop
|
||||||
|
// moet de buttons pas hieronder definieren en dan in de html
|
||||||
|
// pluggen
|
||||||
|
var timer;
|
||||||
|
|
||||||
|
function clock() {
|
||||||
|
timer = setInterval(myClock, 1000);
|
||||||
|
var c = parseInt(slider.value,10);
|
||||||
|
console.log('starting clock');
|
||||||
|
|
||||||
|
function myClock() {
|
||||||
|
document.getElementById("datatime").innerHTML = c;
|
||||||
|
c = c+1;
|
||||||
|
slider.value = c;
|
||||||
|
|
||||||
|
// update data fields
|
||||||
|
|
||||||
|
if (lock.checked) {
|
||||||
|
player.seekTo(c+parseInt(output.value));
|
||||||
|
}
|
||||||
|
if (c == latitude.length) {
|
||||||
|
clearInterval(timer);
|
||||||
|
c = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// onderstaande alleen als lock.checked
|
||||||
|
var dataplay = document.createElement("input");
|
||||||
|
dataplay.type = "button";
|
||||||
|
dataplay.value = "Play";
|
||||||
|
document.getElementById("dataplay").appendChild(dataplay);
|
||||||
|
|
||||||
|
var datastop = document.createElement("input");
|
||||||
|
datastop.type = "button";
|
||||||
|
datastop.value = "Stop";
|
||||||
|
document.getElementById("datastop").appendChild(datastop)
|
||||||
|
|
||||||
|
dataplay.onclick = function() {
|
||||||
|
clock();
|
||||||
|
}
|
||||||
|
|
||||||
|
datastop.onclick = function() {
|
||||||
|
console.log('stopping');
|
||||||
|
clearInterval(timer);
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<script type="text/javascript" src="https://bernii.github.io/gauge.js/dist/gauge.js"></script>
|
<script type="text/javascript" src="https://bernii.github.io/gauge.js/dist/gauge.js"></script>
|
||||||
|
|||||||
@@ -64,7 +64,7 @@
|
|||||||
if (d.getElementById(id)) return t;
|
if (d.getElementById(id)) return t;
|
||||||
js = d.createElement(s);
|
js = d.createElement(s);
|
||||||
js.id = id;
|
js.id = id;
|
||||||
js.async=true;
|
js.async=true;
|
||||||
js.src = "https://platform.twitter.com/widgets.js";
|
js.src = "https://platform.twitter.com/widgets.js";
|
||||||
fjs.parentNode.insertBefore(js, fjs);
|
fjs.parentNode.insertBefore(js, fjs);
|
||||||
|
|
||||||
@@ -72,7 +72,7 @@
|
|||||||
t.ready = function(f) {
|
t.ready = function(f) {
|
||||||
t._e.push(f);
|
t._e.push(f);
|
||||||
};
|
};
|
||||||
|
|
||||||
return t;
|
return t;
|
||||||
}(document, "script", "twitter-wjs"));</script>
|
}(document, "script", "twitter-wjs"));</script>
|
||||||
|
|
||||||
@@ -94,9 +94,9 @@
|
|||||||
window.addEventListener('DOMContentLoaded', function() {
|
window.addEventListener('DOMContentLoaded', function() {
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
var accordionsMenu = $('.cd-accordion-menu');
|
var accordionsMenu = $('.cd-accordion-menu');
|
||||||
|
|
||||||
if( accordionsMenu.length > 0 ) {
|
if( accordionsMenu.length > 0 ) {
|
||||||
|
|
||||||
accordionsMenu.each(function(){
|
accordionsMenu.each(function(){
|
||||||
var accordion = $(this);
|
var accordion = $(this);
|
||||||
//detect change in the input[type="checkbox"] value
|
//detect change in the input[type="checkbox"] value
|
||||||
@@ -121,7 +121,7 @@
|
|||||||
</script>
|
</script>
|
||||||
{% analytical_head_bottom %}
|
{% analytical_head_bottom %}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body data-root="https://webapiv2.navionics.com/dist/webapi/images">
|
<body data-root="https://webapiv2.navionics.com/dist/webapi/images">
|
||||||
<div class="wrapper">
|
<div class="wrapper">
|
||||||
|
|
||||||
@@ -184,10 +184,10 @@
|
|||||||
<side-nav class="side-nav">
|
<side-nav class="side-nav">
|
||||||
|
|
||||||
</side-nav>
|
</side-nav>
|
||||||
|
|
||||||
<nav class="main-nav">
|
<nav class="main-nav">
|
||||||
<ul>
|
<ul>
|
||||||
<li id="nav-workouts">
|
<li id="nav-workouts">
|
||||||
<a href="/rowers/list-workouts/">
|
<a href="/rowers/list-workouts/">
|
||||||
<i class="fas fa-clipboard-list"></i> Workouts
|
<i class="fas fa-clipboard-list"></i> Workouts
|
||||||
</a>
|
</a>
|
||||||
@@ -233,8 +233,8 @@
|
|||||||
<li class="grid_4">
|
<li class="grid_4">
|
||||||
<p class="successmessage">
|
<p class="successmessage">
|
||||||
You have {{ user.rower.planexpires|date_dif|ddays }} days left of your one year subscription. Please renew on or before {{ user.rower.planexpires }} or your plan will be reset to Basic. Click <a href="/rowers/paidplans/">here</a> to renew your membership.</p>
|
You have {{ user.rower.planexpires|date_dif|ddays }} days left of your one year subscription. Please renew on or before {{ user.rower.planexpires }} or your plan will be reset to Basic. Click <a href="/rowers/paidplans/">here</a> to renew your membership.</p>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if user.rower.protrialexpires and user.rower.protrialexpires|is_future_date %}
|
{% if user.rower.protrialexpires and user.rower.protrialexpires|is_future_date %}
|
||||||
@@ -292,17 +292,17 @@
|
|||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
{% block main %}
|
{% block main %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
</main>
|
</main>
|
||||||
|
|
||||||
<aside class="side">
|
<aside class="side">
|
||||||
{% block sidebar %}
|
{% block sidebar %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
<ad class="ad">
|
<ad class="ad">
|
||||||
{% if request|announcements %}
|
{% if request|announcements %}
|
||||||
<h1>News</h1>
|
<h2>News</h2>
|
||||||
{% for a in request|announcements %}
|
{% for a in request|announcements %}
|
||||||
<div class="site-announcement-box">
|
<div class="site-announcement-box">
|
||||||
<div class="site-announcement-white">
|
<div class="site-announcement-white">
|
||||||
@@ -346,7 +346,7 @@
|
|||||||
<p>
|
<p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<h1>Help</h1>
|
<h2>Help</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<a href="/rowers/help/">Help</a>
|
<a href="/rowers/help/">Help</a>
|
||||||
@@ -366,7 +366,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<h1>About</h1>
|
<h2>About</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<a href="/rowers/email/">Contact</a>
|
<a href="/rowers/email/">Contact</a>
|
||||||
@@ -386,7 +386,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<h1>Paid Plans</h1>
|
<h2>Paid Plans</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<a href="/rowers/paidplans/">Paid Plans</a>
|
<a href="/rowers/paidplans/">Paid Plans</a>
|
||||||
@@ -394,7 +394,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<h1>Legal</h1>
|
<h2>Legal</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<a href="/rowers/legal/">Terms and Conditions</a>
|
<a href="/rowers/legal/">Terms and Conditions</a>
|
||||||
|
|||||||
Reference in New Issue
Block a user