summaryrefslogtreecommitdiff
path: root/sbhs/templates
diff options
context:
space:
mode:
authorCruiseDevice2018-11-01 20:54:35 +0530
committerCruiseDevice2018-11-02 12:43:56 +0530
commit3a1daffe5fdc2eb97be797b2ceea16f191ffbfb8 (patch)
tree25b573110d9ecd1bc740c817c4705ed9d145f3ad /sbhs/templates
parenta7553c125964748830712b6aee58189475547ee0 (diff)
downloadsbhs_server-3a1daffe5fdc2eb97be797b2ceea16f191ffbfb8.tar.gz
sbhs_server-3a1daffe5fdc2eb97be797b2ceea16f191ffbfb8.tar.bz2
sbhs_server-3a1daffe5fdc2eb97be797b2ceea16f191ffbfb8.zip
Modify show all webcam video feature
Diffstat (limited to 'sbhs/templates')
-rw-r--r--sbhs/templates/dashboard/all_images.html15
-rw-r--r--sbhs/templates/webcam/show_video.html10
2 files changed, 13 insertions, 12 deletions
diff --git a/sbhs/templates/dashboard/all_images.html b/sbhs/templates/dashboard/all_images.html
index 5a7b74e..8bc6e81 100644
--- a/sbhs/templates/dashboard/all_images.html
+++ b/sbhs/templates/dashboard/all_images.html
@@ -6,13 +6,14 @@
{% block main %}
<div class = "container">
<div class = "row">
- {% for b in boards %}
- <div class="span4" style="text-align: center; outline: 1px solid black">
- <img src="{% static b.image_link %}" alt="{{ b.mid }}" style="width:90%;">
- <br>
- Board MID: {{ b.mid }}
- </div>
- {% endfor %}
+ <table>
+ {% for board in image_links %}
+ <tr>
+ <td>{{board.board.mid}}</td>
+ <td><img src="{% static board.image_link %}"/></td>
+ </tr>
+ {% endfor %}
+ </table>
</div>
</div>
<script type="text/javascript">
diff --git a/sbhs/templates/webcam/show_video.html b/sbhs/templates/webcam/show_video.html
index 1f372d7..ba87635 100644
--- a/sbhs/templates/webcam/show_video.html
+++ b/sbhs/templates/webcam/show_video.html
@@ -20,7 +20,7 @@
</div>
<img src="{% static image_link %}" id="videoImage" alt="SBHS live feed" class = "offeset4">
<div class = "offeset4" style="text-align:center">
- <a href="#" onclick = "image_reloader()" id = "image_reloader" class = "btn btn-primary btn-large">Refresh Image.</a>
+ <a href="#" onclick = "image_reloader()" id = "image_reloader" class = "btn btn-primary btn-large">Refresh Image</a>
</div>
</div>
</div>
@@ -29,8 +29,8 @@
{% if request.user.profile.is_moderator %}
setInterval(function(){
var refresh = new Image();
- refresh.src = "{% url 'reload_image' mid %}";
- document.getElementById("videoImage").src = "{% static image_link %}" + new Date().getTime();
+ refresh.src = "{% static image_link %}";
+ document.getElementById("videoImage").src = "{% static image_link %}";
}, 2000);
{% else %}
window.image_reloader = function(){
@@ -39,8 +39,8 @@
if (!button.disabled){
button.setAttribute("disabled", true);
var refresh = new Image();
- refresh.src = "{% url 'reload_image' mid %}";
- document.getElementById("videoImage").src = "{% static image_link %}" + new Date.getTime();
+ refresh.src = "{% static image_link %}";
+ document.getElementById("videoImage").src = "{% static image_link %}";
setTimeout(function(){
button.removeAttribute("disabled");
}, 3000);