aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2014-03-09 18:59:33 +0000
committerPaul Eggleton <paul.eggleton@linux.intel.com>2014-03-09 19:17:49 +0000
commit6d0b9d40aa0cc25159a8ab8a717e69b15cf9661c (patch)
tree1e1f906b5be59f725eee6e6c30a5652f0e4ac309 /templates
parent7f990bc0854c1a6073ae166c8448672080f82cbd (diff)
downloadopenembedded-core-contrib-6d0b9d40aa0cc25159a8ab8a717e69b15cf9661c.tar.gz
duplicates: add ability to select layers
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'templates')
-rw-r--r--templates/layerindex/duplicates.html56
1 files changed, 55 insertions, 1 deletions
diff --git a/templates/layerindex/duplicates.html b/templates/layerindex/duplicates.html
index 23472537e2..116aab9df6 100644
--- a/templates/layerindex/duplicates.html
+++ b/templates/layerindex/duplicates.html
@@ -6,7 +6,7 @@
layerindex-web - duplicates page template
- Copyright (C) 2013 Intel Corporation
+ Copyright (C) 2013-2014 Intel Corporation
Licensed under the MIT license, see COPYING.MIT for details
{% endcomment %}
@@ -39,6 +39,47 @@
</a></li>
{% endfor %}
</ul>
+
+ <div id="layerDialog" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="layerDialogLabel" aria-hidden="true">
+ <div class="modal-header">
+ <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
+ <h3 id="layerDialogLabel">Select layers to include</h3>
+ </div>
+ <form action="" method="get">
+ <div class="modal-body">
+ <div class="scrolling">
+ <table><tbody>
+ {% for layerbranch in layers %}
+ <tr>
+ <td class="checkboxtd"><input
+ type="checkbox"
+ class="filterlayercheckbox"
+ name="l"
+ value="{{ layerbranch.layer.id }}" id="id_layer_{{layerbranch.layer.id}}"
+ {% if showlayers and layerbranch.layer.id in showlayers %}
+ checked
+ {% endif %}
+ />
+ </td>
+ <td><label for="id_layer_{{layerbranch.layer.id}}">{{ layerbranch.layer.name }}</label></td>
+ </tr>
+ {% endfor %}
+ </tbody></table>
+ </div>
+ <div class="buttonblock">
+ <button type="button" class="btn" id="id_select_all">Select all</button>
+ <button type="button" class="btn buttonblock-btn" id="id_select_none">Select none</button>
+ </div>
+ </div>
+ <div class="modal-footer">
+ <input type="submit" value="Filter" class='btn btn-primary' />
+ <button class="btn" id="id_cancel" data-dismiss="modal" aria-hidden="true">Cancel</button>
+ </div>
+ </form>
+ </div>
+
+ <a href="#layerDialog" role="button" class="btn nav-spacer" data-toggle="modal">Filter layers {% if showlayers %}<span class="badge badge-success">{{ showlayers|length }}</span>{% endif %}</a>
+
</div>
<h2>Duplicate recipes</h2>
@@ -113,5 +154,18 @@
if( ! firstfield.val() )
firstfield.focus()
});
+ $('#id_select_all').click(function (e) {
+ $('.filterlayercheckbox').attr('checked', true);
+ });
+ $('#id_select_none').click(function (e) {
+ $('.filterlayercheckbox').attr('checked', false);
+ });
+ $('#id_cancel').click(function (e) {
+ $('.filterlayercheckbox').attr('checked', false);
+ showlayers = {{ showlayers }}
+ for(i in showlayers) {
+ $('#id_layer_' + showlayers[i]).attr('checked', true);
+ }
+ });
</script>
{% endblock %}