mirror of
https://git.yoctoproject.org/poky
synced 2026-09-20 03:49:32 +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 in this build
|
||||||
"""
|
"""
|
||||||
targets = self.target_set.all()
|
targets = self.target_set.all()
|
||||||
target_labels = []
|
target_labels = [target.target +
|
||||||
target_label = None
|
(':' + target.task if target.task else '')
|
||||||
|
for target in targets]
|
||||||
for target in targets:
|
|
||||||
target_label = target.target
|
|
||||||
if target.task:
|
|
||||||
target_label = target_label + ':' + target.task
|
|
||||||
target_labels.append(target_label)
|
|
||||||
|
|
||||||
target_labels.sort()
|
target_labels.sort()
|
||||||
|
|
||||||
return target_labels
|
return target_labels
|
||||||
|
|||||||
@@ -688,7 +688,9 @@ class ProjectsTable(ToasterTable):
|
|||||||
|
|
||||||
self.queryset = queryset
|
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):
|
def setup_columns(self, *args, **kwargs):
|
||||||
name_template = '''
|
name_template = '''
|
||||||
{% load project_url_tag %}
|
{% load project_url_tag %}
|
||||||
|
|||||||
@@ -462,7 +462,7 @@ def builddashboard( request, build_id ):
|
|||||||
for t in tgts:
|
for t in tgts:
|
||||||
elem = { }
|
elem = { }
|
||||||
elem[ 'target' ] = t
|
elem[ 'target' ] = t
|
||||||
if ( t.is_image ):
|
if t.is_image:
|
||||||
hasImages = True
|
hasImages = True
|
||||||
npkg = 0
|
npkg = 0
|
||||||
pkgsz = 0
|
pkgsz = 0
|
||||||
@@ -481,8 +481,7 @@ def builddashboard( request, build_id ):
|
|||||||
ndx = 0;
|
ndx = 0;
|
||||||
f = i.file_name[ ndx + 1: ]
|
f = i.file_name[ ndx + 1: ]
|
||||||
imageFiles.append({ 'id': i.id, 'path': f, 'size' : i.file_size })
|
imageFiles.append({ 'id': i.id, 'path': f, 'size' : i.file_size })
|
||||||
if ( t.is_image and
|
if t.is_image and (len(imageFiles) <= 0 or len(t.license_manifest_path) <= 0):
|
||||||
(( len( imageFiles ) <= 0 ) or ( len( t.license_manifest_path ) <= 0 ))):
|
|
||||||
targetHasNoImages = True
|
targetHasNoImages = True
|
||||||
elem[ 'imageFiles' ] = imageFiles
|
elem[ 'imageFiles' ] = imageFiles
|
||||||
elem[ 'targetHasNoImages' ] = targetHasNoImages
|
elem[ 'targetHasNoImages' ] = targetHasNoImages
|
||||||
|
|||||||
Reference in New Issue
Block a user