diff options
author | Michael Wood <michael.g.wood@intel.com> | 2016-07-06 18:22:38 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-07-08 09:57:29 +0100 |
commit | 8813726f1d5ea1d78fced7fe52abdf826e529e62 (patch) | |
tree | 073689032966641d0f12415002572de1f1d08e72 /bitbake/lib/toaster/toastergui/templates | |
parent | e1ba2fd331b7f937b8ddf3e83389df5caf33d9e8 (diff) | |
download | poky-8813726f1d5ea1d78fced7fe52abdf826e529e62.tar.gz |
bitbake: toaster: add Layer delete front end feature to layerdetails
Add the front end feature to delete a layer from the layer details page.
[YOCO #9184]
(Bitbake rev: 91815229f60eb9deba7d299f05c69b52ff1df59c)
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Signed-off-by: Elliot Smith <elliot.smith@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates')
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/layerdetails.html | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/layerdetails.html b/bitbake/lib/toaster/toastergui/templates/layerdetails.html index 143ec25dd7..4b51d1a39c 100644 --- a/bitbake/lib/toaster/toastergui/templates/layerdetails.html +++ b/bitbake/lib/toaster/toastergui/templates/layerdetails.html | |||
@@ -6,6 +6,20 @@ | |||
6 | {% block title %} {{layerversion.layer.name}} - {{project.name}} - Toaster {% endblock %} | 6 | {% block title %} {{layerversion.layer.name}} - {{project.name}} - Toaster {% endblock %} |
7 | {% block pagecontent %} | 7 | {% block pagecontent %} |
8 | 8 | ||
9 | <div id="delete-layer-modal" class="modal fade" tabindex="-1" role="dialog"> | ||
10 | <div class="modal-dialog" role="document"> | ||
11 | <div class="modal-content"> | ||
12 | <div class="modal-body"> | ||
13 | Are you sure you want to delete the <strong>{{layerversion.layer.name}}</strong> layer? | ||
14 | </div> | ||
15 | <div class="modal-footer"> | ||
16 | <button type="button" id="layer-delete-confirmed" class="btn btn-primary">Delete</button> | ||
17 | <button type="button" class="btn btn-default btn-link" data-dismiss="modal">Cancel</button> | ||
18 | </div> | ||
19 | </div> | ||
20 | </div> | ||
21 | </div> | ||
22 | |||
9 | <div class="row"> | 23 | <div class="row"> |
10 | <div class="col-md-12"> | 24 | <div class="col-md-12"> |
11 | <ul class="breadcrumb"> | 25 | <ul class="breadcrumb"> |
@@ -44,7 +58,7 @@ | |||
44 | 58 | ||
45 | $(document).ready(function(){ | 59 | $(document).ready(function(){ |
46 | var ctx = { | 60 | var ctx = { |
47 | xhrUpdateLayerUrl : "{% url 'xhr_layer' layerversion.pk %}", | 61 | xhrUpdateLayerUrl : "{% url 'xhr_layer' project.id layerversion.pk %}", |
48 | layerVersion : { | 62 | layerVersion : { |
49 | name : "{{layerversion.layer.name}}", | 63 | name : "{{layerversion.layer.name}}", |
50 | id : {{layerversion.id}}, | 64 | id : {{layerversion.id}}, |
@@ -271,6 +285,10 @@ | |||
271 | </dd> | 285 | </dd> |
272 | {% endif %} | 286 | {% endif %} |
273 | </dl> | 287 | </dl> |
288 | {% if layerversion.layer_source_id and layerversion.layer_source.sourcetype == layerversion.layer_source.TYPE_IMPORTED %} | ||
289 | <i class="icon-trash text-danger"></i> | ||
290 | <a href="#delete-layer-modal" role="button" class="text-danger" data-toggle="modal" data-target="#delete-layer-modal">Delete {{layerversion.layer.name}}</a> | ||
291 | {% endif %} | ||
274 | </div> | 292 | </div> |
275 | </div> | 293 | </div> |
276 | </div> | 294 | </div> |