[oe-commits] [bitbake] 11/14: toaster: typeaheads Layers add url to layer REST API to the layer
git at git.openembedded.org
git at git.openembedded.org
Mon Dec 12 20:46:05 UTC 2016
rpurdie pushed a commit to branch master
in repository bitbake.
commit d195f24a1b30ae8698bff5e87308347b9596a2e2
Author: Michael Wood <michael.g.wood at intel.com>
AuthorDate: Fri Dec 9 16:52:52 2016 +0000
toaster: typeaheads Layers add url to layer REST API to the layer
Add the url to the Layer typeahead so that this can be used later on by
the front end code to look up layer details.
Signed-off-by: Michael Wood <michael.g.wood at intel.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
lib/toaster/toastergui/typeaheads.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/toaster/toastergui/typeaheads.py b/lib/toaster/toastergui/typeaheads.py
index 5316000..58c650f 100644
--- a/lib/toaster/toastergui/typeaheads.py
+++ b/lib/toaster/toastergui/typeaheads.py
@@ -23,6 +23,7 @@ from orm.models import Project
from django.core.urlresolvers import reverse
from django.core.cache import cache
+
class LayersTypeAhead(ToasterTypeAhead):
""" Typeahead for layers available and not added in the current project's
configuration """
@@ -55,6 +56,8 @@ class LayersTypeAhead(ToasterTypeAhead):
'id': layer_version.pk,
'name': layer_version.layer.name,
'layerdetailurl': layer_version.get_detailspage_url(prj.pk),
+ 'xhrLayerUrl': reverse('xhr_layer',
+ args=(prj.pk, layer_version.pk)),
'vcs_url': layer_version.layer.vcs_url,
'vcs_reference': vcs_reference,
'detail': detail,
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list