diff options
author | Michael Wood <michael.g.wood@intel.com> | 2015-10-13 09:58:49 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-10-13 15:35:37 +0300 |
commit | c7cb8255d0ab1fd7715e878c1c83ef0cd920387e (patch) | |
tree | 990b7b92a61bbc6422aba6557a3870df569bf5b6 | |
parent | 3c72c7634ab69a5eb18aa20a5c6d16a3e2666f62 (diff) | |
download | bitbake-c7cb8255d0ab1fd7715e878c1c83ef0cd920387e.tar.gz |
toaster: Fix missing tooltips from layers on project configuration page
Re-enable the layer tooltips on the project configuration page.
This adds the required fields to the API used for the layer dependencies
to be able to show the metadata needed.
Also fixes link hrefs which were missing in the add layers confirmation
dialog (bug 8251).
[YOCTO #8295]
[YOCTO #8251]
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>
-rw-r--r-- | lib/toaster/toastergui/static/js/projectpage.js | 5 | ||||
-rwxr-xr-x | lib/toaster/toastergui/views.py | 16 |
2 files changed, 11 insertions, 10 deletions
diff --git a/lib/toaster/toastergui/static/js/projectpage.js b/lib/toaster/toastergui/static/js/projectpage.js index d36704751..30989a016 100644 --- a/lib/toaster/toastergui/static/js/projectpage.js +++ b/lib/toaster/toastergui/static/js/projectpage.js @@ -146,10 +146,7 @@ function projectPageInit(ctx) { link.attr("href", layerObj.layerdetailurl); link.text(layerObj.name); - /* YOCTO #8024 - link.tooltip({title: layerObj.giturl + " | "+ layerObj.branch.name, placement: "right"}); - branch name not accessible sometimes it is revision instead - */ + link.tooltip({title: layerObj.vcs_url + " | "+ layerObj.vcs_reference, placement: "right"}); var trashItem = projectLayer.children("span"); trashItem.click(function (e) { diff --git a/lib/toaster/toastergui/views.py b/lib/toaster/toastergui/views.py index 468cce311..c4264a11a 100755 --- a/lib/toaster/toastergui/views.py +++ b/lib/toaster/toastergui/views.py @@ -2768,12 +2768,16 @@ if True: project = Project.objects.get(pk=pid) layer_version = Layer_Version.objects.get(pk=layerid) - context = { 'project' : project, - 'layerversion' : layer_version, - 'layerdeps' : {"list": [{"id": dep.id, "name": dep.layer.name} \ - for dep in layer_version.get_alldeps(project.id)]}, - 'projectlayers': map(lambda prjlayer: prjlayer.layercommit.id, ProjectLayer.objects.filter(project=project)) - } + context = {'project' : project, + 'layerversion' : layer_version, + 'layerdeps' : {"list": [{"id": dep.id, + "name": dep.layer.name, + "layerdetailurl": reverse('layerdetails', args=(pid, dep.pk)), + "vcs_url": dep.layer.vcs_url, + "vcs_reference": dep.get_vcs_reference()} \ + for dep in layer_version.get_alldeps(project.id)]}, + 'projectlayers': map(lambda prjlayer: prjlayer.layercommit.id, ProjectLayer.objects.filter(project=project)) + } return context |