Fixes and experiments.
[wolnelektury.git] / src / experiments / templates / experiments / main_switch.html
index 2f866bc..7638e1f 100644 (file)
@@ -9,8 +9,11 @@
   <img src="https://upload.wikimedia.org/wikipedia/commons/c/c8/MH1Asimulator.JPG" style="width:100%">
 
   {% for exp in request.EXPERIMENTS.values %}
-    <div class="experiment" data-slug="{{ exp.slug }}">
-      {{ exp.name }}
+    {% if exp.switchable or request.user.is_staff %}
+    <div class="experiment nice-controls" data-slug="{{ exp.slug }}">
+      <span>
+        {{ exp.name }}
+      </span>
       <button
           {% if exp.value %}
           disabled class="active"
@@ -22,6 +25,7 @@
           {% endif %}
           data-value="off">wyłączony</button>
     </div>
+    {% endif %}
   {% endfor %}
 {% endblock %}