diff options
5 files changed, 8 insertions, 4 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/base.html b/bitbake/lib/toaster/toastergui/templates/base.html index 62cc7ad..a781224 100644 --- a/bitbake/lib/toaster/toastergui/templates/base.html +++ b/bitbake/lib/toaster/toastergui/templates/base.html @@ -34,7 +34,7 @@ var ctx = {}; ctx.xhrDataTypeaheadUrl = "{% url 'xhr_datatypeahead' %}"; ctx.projectBuildUrl = "{% url 'xhr_build' %}"; - ctx.projectPageUrl = "{% url 'project' %}"; + ctx.projectPageUrl = "{% url 'base_project' %}"; ctx.projectInfoUrl = "{% url 'xhr_projectinfo' %}"; ctx.numProjects = {{projects|length}}; {% if project %} diff --git a/bitbake/lib/toaster/toastergui/templates/importlayer.html b/bitbake/lib/toaster/toastergui/templates/importlayer.html index 19d2fc4..6b2111a 100644 --- a/bitbake/lib/toaster/toastergui/templates/importlayer.html +++ b/bitbake/lib/toaster/toastergui/templates/importlayer.html @@ -14,7 +14,7 @@ $(document).ready(function (){ var ctx = { xhrDataTypeaheadUrl : "{% url 'xhr_datatypeahead' %}", - layerDetailsUrl : "{% url 'layerdetails' %}", + layerDetailsUrl : "{% url 'base_layerdetails' %}", xhrImportLayerUrl : "{% url 'xhr_importlayer' %}", xhrEditProjectUrl : "{% url 'xhr_projectedit' project.id %}", projectPageUrl : "{% url 'project' project.id %}", diff --git a/bitbake/lib/toaster/toastergui/templates/layerdetails.html b/bitbake/lib/toaster/toastergui/templates/layerdetails.html index c3a50df..67033b1 100644 --- a/bitbake/lib/toaster/toastergui/templates/layerdetails.html +++ b/bitbake/lib/toaster/toastergui/templates/layerdetails.html @@ -17,7 +17,7 @@ $(document).ready(function (){ var ctx = { projectBuildUrl : "{% url 'xhr_build' %}", - layerDetailsUrl : "{% url 'layerdetails' %}", + layerDetailsUrl : "{% url 'base_layerdetails' %}", projectPageUrl : "{% url 'project' project.id %}", xhrEditProjectUrl : "{% url 'xhr_projectedit' project.id %}", xhrDataTypeaheadUrl : "{% url 'xhr_datatypeahead' %}", diff --git a/bitbake/lib/toaster/toastergui/templates/project.html b/bitbake/lib/toaster/toastergui/templates/project.html index a8cb917..58b524e 100644 --- a/bitbake/lib/toaster/toastergui/templates/project.html +++ b/bitbake/lib/toaster/toastergui/templates/project.html @@ -426,7 +426,7 @@ angular.element(document).ready(function() { scope.urls.layers = "{% url 'layers' %}"; scope.urls.targets = "{% url 'targets' %}"; scope.urls.importlayer = "{% url 'importlayer'%}"; - scope.urls.layer = "{% url 'layerdetails' %}"; + scope.urls.layer = "{% url 'base_layerdetails' %}"; scope.project = {{prj|json}}; scope.builds = {{builds|json}}; scope.layers = {{layers|json}}; diff --git a/bitbake/lib/toaster/toastergui/urls.py b/bitbake/lib/toaster/toastergui/urls.py index 64f7902..8a7fef1 100644 --- a/bitbake/lib/toaster/toastergui/urls.py +++ b/bitbake/lib/toaster/toastergui/urls.py @@ -19,6 +19,8 @@ from django.conf.urls import patterns, include, url from django.views.generic import RedirectView +from django.http import HttpResponseBadRequest + urlpatterns = patterns('toastergui.views', # landing page url(r'^landing/$', 'landing', name='landing'), @@ -78,11 +80,13 @@ urlpatterns = patterns('toastergui.views', url(r'^layers/$', 'layers', name='layers'), url(r'^layer/(?P<layerid>\d+)/$', 'layerdetails', name='layerdetails'), + url(r'^layer/$', lambda x: HttpResponseBadRequest(), name='base_layerdetails'), url(r'^targets/$', 'targets', name='all-targets'), url(r'^machines/$', 'machines', name='machines'), url(r'^projects/$', 'projects', name='all-projects'), + url(r'^project/$', lambda x: HttpResponseBadRequest(), name='base_project'), url(r'^project/(?P<pid>\d+)/$', 'project', name='project'), url(r'^project/(?P<pid>\d+)/configuration$', 'projectconf', name='projectconf'), url(r'^project/(?P<pid>\d+)/builds$', 'projectbuilds', name='projectbuilds'), |