diff options
author | Alexandru DAMIAN <alexandru.damian@intel.com> | 2013-12-18 19:50:45 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-01-10 15:20:24 +0000 |
commit | 47621ecb24eedd803f17a551230a524193089c9a (patch) | |
tree | d972454f7ea2dfaf2c4da519d4f36d00c5a37044 /bitbake/lib/toaster/bldviewer/views.py | |
parent | 8172f24b62ed65cb7267b13b01024c1b1e891119 (diff) | |
download | poky-47621ecb24eedd803f17a551230a524193089c9a.tar.gz |
bitbake: toaster: clone Simple UI as base for Toaster GUI
This patch clones the Simple UI to provide the base code for
the development of the Toaster GUI. The clone takes the place
of the application that was reserved for Javascript MVC code.
The templates used for Simple UI are renamed to start with
an "simple_" to prevent name resolution conflict with the
Toaster GUI templates.
Minor changes are made to the settings.py and urls.py in the
toaster main section to account for the newly enabled application.
(Bitbake rev: e2fde84f16da017ba0d71aef6a1fa8e2b9255db4)
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/bldviewer/views.py')
-rw-r--r-- | bitbake/lib/toaster/bldviewer/views.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/bitbake/lib/toaster/bldviewer/views.py b/bitbake/lib/toaster/bldviewer/views.py index 7cb9b42379..22b42d39ce 100644 --- a/bitbake/lib/toaster/bldviewer/views.py +++ b/bitbake/lib/toaster/bldviewer/views.py | |||
@@ -50,7 +50,7 @@ def _build_page_range(paginator, index = 1): | |||
50 | 50 | ||
51 | @cache_control(no_store=True) | 51 | @cache_control(no_store=True) |
52 | def build(request): | 52 | def build(request): |
53 | template = 'build.html' | 53 | template = 'simple_build.html' |
54 | logs = LogMessage.objects.all() | 54 | logs = LogMessage.objects.all() |
55 | 55 | ||
56 | build_info = _build_page_range(Paginator(Build.objects.order_by("-id"), 10),request.GET.get('page', 1)) | 56 | build_info = _build_page_range(Paginator(Build.objects.order_by("-id"), 10),request.GET.get('page', 1)) |
@@ -82,7 +82,7 @@ def _find_task_provider(task): | |||
82 | return None | 82 | return None |
83 | 83 | ||
84 | def task(request, build_id): | 84 | def task(request, build_id): |
85 | template = 'task.html' | 85 | template = 'simple_task.html' |
86 | 86 | ||
87 | tasks = _build_page_range(Paginator(Task.objects.filter(build=build_id), 100),request.GET.get('page', 1)) | 87 | tasks = _build_page_range(Paginator(Task.objects.filter(build=build_id), 100),request.GET.get('page', 1)) |
88 | 88 | ||
@@ -95,31 +95,31 @@ def task(request, build_id): | |||
95 | return render(request, template, context) | 95 | return render(request, template, context) |
96 | 96 | ||
97 | def configuration(request, build_id): | 97 | def configuration(request, build_id): |
98 | template = 'configuration.html' | 98 | template = 'simple_configuration.html' |
99 | variables = _build_page_range(Paginator(Variable.objects.filter(build=build_id), 50), request.GET.get('page', 1)) | 99 | variables = _build_page_range(Paginator(Variable.objects.filter(build=build_id), 50), request.GET.get('page', 1)) |
100 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : variables} | 100 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : variables} |
101 | return render(request, template, context) | 101 | return render(request, template, context) |
102 | 102 | ||
103 | def bpackage(request, build_id): | 103 | def bpackage(request, build_id): |
104 | template = 'bpackage.html' | 104 | template = 'simple_bpackage.html' |
105 | packages = Package.objects.filter(build = build_id) | 105 | packages = Package.objects.filter(build = build_id) |
106 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : packages} | 106 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : packages} |
107 | return render(request, template, context) | 107 | return render(request, template, context) |
108 | 108 | ||
109 | def bfile(request, build_id, package_id): | 109 | def bfile(request, build_id, package_id): |
110 | template = 'bfile.html' | 110 | template = 'simple_bfile.html' |
111 | files = Package_File.objects.filter(package = package_id) | 111 | files = Package_File.objects.filter(package = package_id) |
112 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : files} | 112 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : files} |
113 | return render(request, template, context) | 113 | return render(request, template, context) |
114 | 114 | ||
115 | def tpackage(request, build_id, target_id): | 115 | def tpackage(request, build_id, target_id): |
116 | template = 'package.html' | 116 | template = 'simple_package.html' |
117 | packages = map(lambda x: x.package, list(Target_Installed_Package.objects.filter(target=target_id))) | 117 | packages = map(lambda x: x.package, list(Target_Installed_Package.objects.filter(target=target_id))) |
118 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : packages} | 118 | context = {'build': Build.objects.filter(pk=build_id)[0], 'objects' : packages} |
119 | return render(request, template, context) | 119 | return render(request, template, context) |
120 | 120 | ||
121 | def layer(request): | 121 | def layer(request): |
122 | template = 'layer.html' | 122 | template = 'simple_layer.html' |
123 | layer_info = Layer.objects.all() | 123 | layer_info = Layer.objects.all() |
124 | 124 | ||
125 | for li in layer_info: | 125 | for li in layer_info: |
@@ -133,7 +133,7 @@ def layer(request): | |||
133 | 133 | ||
134 | 134 | ||
135 | def layer_versions_recipes(request, layerversion_id): | 135 | def layer_versions_recipes(request, layerversion_id): |
136 | template = 'recipe.html' | 136 | template = 'simple_recipe.html' |
137 | recipes = Recipe.objects.filter(layer_version__id = layerversion_id) | 137 | recipes = Recipe.objects.filter(layer_version__id = layerversion_id) |
138 | 138 | ||
139 | context = {'objects': recipes, | 139 | context = {'objects': recipes, |