mirror of
https://git.yoctoproject.org/poky
synced 2026-04-18 21:32:12 +02:00
bitbake: toastergui: code formatting and clean-up
Minor fixes to code formatting and small improvements from code review. (Bitbake rev: 2c97f3a5c6ae37de910deb90390c5b856a600c5f) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
c4b50111e9
commit
798e8b8d03
@@ -477,15 +477,9 @@ class Build(models.Model):
|
||||
targets in this build
|
||||
"""
|
||||
targets = self.target_set.all()
|
||||
target_labels = []
|
||||
target_label = None
|
||||
|
||||
for target in targets:
|
||||
target_label = target.target
|
||||
if target.task:
|
||||
target_label = target_label + ':' + target.task
|
||||
target_labels.append(target_label)
|
||||
|
||||
target_labels = [target.target +
|
||||
(':' + target.task if target.task else '')
|
||||
for target in targets]
|
||||
target_labels.sort()
|
||||
|
||||
return target_labels
|
||||
|
||||
@@ -688,7 +688,9 @@ class ProjectsTable(ToasterTable):
|
||||
|
||||
self.queryset = queryset
|
||||
|
||||
# columns: last activity on (updated) - DEFAULT, project (name), release, machine, number of builds, last build outcome, recipe (name), errors, warnings, image files
|
||||
# columns: last activity on (updated) - DEFAULT, project (name), release,
|
||||
# machine, number of builds, last build outcome, recipe (name), errors,
|
||||
# warnings, image files
|
||||
def setup_columns(self, *args, **kwargs):
|
||||
name_template = '''
|
||||
{% load project_url_tag %}
|
||||
|
||||
@@ -462,7 +462,7 @@ def builddashboard( request, build_id ):
|
||||
for t in tgts:
|
||||
elem = { }
|
||||
elem[ 'target' ] = t
|
||||
if ( t.is_image ):
|
||||
if t.is_image:
|
||||
hasImages = True
|
||||
npkg = 0
|
||||
pkgsz = 0
|
||||
@@ -481,8 +481,7 @@ def builddashboard( request, build_id ):
|
||||
ndx = 0;
|
||||
f = i.file_name[ ndx + 1: ]
|
||||
imageFiles.append({ 'id': i.id, 'path': f, 'size' : i.file_size })
|
||||
if ( t.is_image and
|
||||
(( len( imageFiles ) <= 0 ) or ( len( t.license_manifest_path ) <= 0 ))):
|
||||
if t.is_image and (len(imageFiles) <= 0 or len(t.license_manifest_path) <= 0):
|
||||
targetHasNoImages = True
|
||||
elem[ 'imageFiles' ] = imageFiles
|
||||
elem[ 'targetHasNoImages' ] = targetHasNoImages
|
||||
|
||||
Reference in New Issue
Block a user