summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/views.py
diff options
context:
space:
mode:
authorElliot Smith <elliot.smith@intel.com>2015-12-09 19:56:29 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-12-14 23:13:06 +0000
commit7a0c45e478fac9de2bae63544f7e98187ceb59a7 (patch)
tree0552588396da878af3f3a0487e3f267fd5ca6268 /bitbake/lib/toaster/toastergui/views.py
parent9de8dfa11a9d0008fd43bd38f81ab3d65b998033 (diff)
downloadpoky-7a0c45e478fac9de2bae63544f7e98187ceb59a7.tar.gz
bitbake: toaster: Create default project with get_or_create* method
Rather than maintain data as part of the migrations (as was done for the default project previously), create the default (cli builds) project on demand as a by-product of getting it from the database. [YOCTO #8364] (Bitbake rev: 5fd8e90ab9b81d1bd0d301bc1c91228ecbbea74b) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/views.py')
-rwxr-xr-xbitbake/lib/toaster/toastergui/views.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/toastergui/views.py b/bitbake/lib/toaster/toastergui/views.py
index 243bb09d62..16f27b8022 100755
--- a/bitbake/lib/toaster/toastergui/views.py
+++ b/bitbake/lib/toaster/toastergui/views.py
@@ -73,7 +73,7 @@ class MimeTypeFinder(object):
73def landing(request): 73def landing(request):
74 # in build mode, we redirect to the command-line builds page 74 # in build mode, we redirect to the command-line builds page
75 # if there are any builds for the default (cli builds) project 75 # if there are any builds for the default (cli builds) project
76 default_project = Project.objects.get_default_project() 76 default_project = Project.objects.get_or_create_default_project()
77 default_project_builds = Build.objects.filter(project = default_project) 77 default_project_builds = Build.objects.filter(project = default_project)
78 78
79 # we only redirect to projects page if there is a user-generated project 79 # we only redirect to projects page if there is a user-generated project