Fixed issue with opening items on survey lists while pressing ctrl button
authordhans
Mon, 13 Jul 2009 11:19:55 +0200
changeset 2624 5604204998c5
parent 2623 9848682af610
child 2625 13a80adefcc6
Fixed issue with opening items on survey lists while pressing ctrl button
app/soc/templates/soc/grading_project_survey/list/row.html
app/soc/templates/soc/project_survey/list/row.html
app/soc/templates/soc/survey/list/results_row.html
app/soc/templates/soc/survey/list/row.html
--- a/app/soc/templates/soc/grading_project_survey/list/row.html	Mon Jul 13 01:15:46 2009 +0200
+++ b/app/soc/templates/soc/grading_project_survey/list/row.html	Mon Jul 13 11:19:55 2009 +0200
@@ -1,8 +1,8 @@
-<tr class="off" onmouseover="this.className='on'" onmouseout="this.className='off'"
- onclick="document.location.href='{{ list.redirect }}'" name="name">
+<tr class="off" onmouseover="this.className='on'; do_redirect=true" onmouseout="this.className='off'"
+ onclick="if (do_redirect) document.location.href='{{ list.redirect }}'" name="name">
   <td align="right">
    <div class="title">
-    <a class="noul"
+    <a class="noul" onclick="do_redirect=false"
      href="{{ list.redirect }}">{{ list.item.scope_path}}/{{ list.item.link_id }}</a>
    </div>
   </td>
--- a/app/soc/templates/soc/project_survey/list/row.html	Mon Jul 13 01:15:46 2009 +0200
+++ b/app/soc/templates/soc/project_survey/list/row.html	Mon Jul 13 11:19:55 2009 +0200
@@ -1,8 +1,8 @@
-<tr class="off" onmouseover="this.className='on'" onmouseout="this.className='off'"
- onclick="document.location.href='{{ list.redirect }}'" name="name">
+<tr class="off" onmouseover="this.className='on'; do_redirect=true" onmouseout="this.className='off'"
+ onclick="if (do_redirect) document.location.href='{{ list.redirect }}'" name="name">
   <td align="right">
    <div class="title">
-    <a class="noul"
+    <a class="noul" onclick="do_redirect=false"
      href="{{ list.redirect }}">{{ list.item.scope_path}}/{{ list.item.link_id }}</a>
    </div>
   </td>
--- a/app/soc/templates/soc/survey/list/results_row.html	Mon Jul 13 01:15:46 2009 +0200
+++ b/app/soc/templates/soc/survey/list/results_row.html	Mon Jul 13 11:19:55 2009 +0200
@@ -1,5 +1,5 @@
-<tr class="off" onmouseover="this.className='on'" onmouseout="this.className='off'"
-onclick="return false; document.location.href='{{ list.redirect }}'" name="name">
+<tr class="off" onmouseover="this.className='on'; do_redirect=true" onmouseout="this.className='off'"
+onclick="return false; if (do_redirect) document.location.href='{{ list.redirect }}'" name="name">
 
   {% for value in list.item.getValues %}
     <td>
@@ -28,7 +28,7 @@
   </td>
 
   <td>
-    <a class="fetch_answers" id="results_for_{{ list.item.user.link_id }}">View</a>
+    <a class="fetch_answers" id="results_for_{{ list.item.user.link_id }}" onclick="do_redirect=false">View</a>
   </td>
 
   {% if grades %}
--- a/app/soc/templates/soc/survey/list/row.html	Mon Jul 13 01:15:46 2009 +0200
+++ b/app/soc/templates/soc/survey/list/row.html	Mon Jul 13 11:19:55 2009 +0200
@@ -1,8 +1,8 @@
-<tr class="off" onmouseover="this.className='on'" onmouseout="this.className='off'"
- onclick="document.location.href='{{ list.redirect }}'" name="name">
+<tr class="off" onmouseover="this.className='on'; do_redirect=true" onmouseout="this.className='off'"
+ onclick="if (do_redirect) document.location.href='{{ list.redirect }}'" name="name">
   <td align="right">
    <div class="title">
-    <a class="noul"
+    <a class="noul" onclick="do_redirect=false"
      href="{{ list.redirect }}">{{ list.item.scope_path}}/{{ list.item.link_id }}</a>
    </div>
   </td>