* [PATCH 1/3] toaster: missing ToasterSetting import
2017-09-04 4:02 [PATCH 0/3] toaster: cummulative 03092017 patch David Reyna
@ 2017-09-04 4:02 ` David Reyna
2017-09-04 4:02 ` [PATCH 2/3] toaster: recipe links broken for default layers David Reyna
2017-09-04 4:02 ` [PATCH 3/3] toaster: edit column list not sorted David Reyna
2 siblings, 0 replies; 4+ messages in thread
From: David Reyna @ 2017-09-04 4:02 UTC (permalink / raw)
To: bitbake-devel
From: David Reyna <David.Reyna@windriver.com>
The file "lsupdates.py" is missing the import of 'ToasterSetting',
and that breaks setting up and updating Toaster and its database.
[YOCTO #12036]
Signed-off-by: David Reyna <David.Reyna@windriver.com>
---
lib/toaster/orm/management/commands/lsupdates.py | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/toaster/orm/management/commands/lsupdates.py b/lib/toaster/orm/management/commands/lsupdates.py
index fac5733..54b4fab 100644
--- a/lib/toaster/orm/management/commands/lsupdates.py
+++ b/lib/toaster/orm/management/commands/lsupdates.py
@@ -24,6 +24,7 @@ from django.core.management.base import BaseCommand
from orm.models import LayerSource, Layer, Release, Layer_Version
from orm.models import LayerVersionDependency, Machine, Recipe
from orm.models import Distro
+from orm.models import ToasterSetting
import os
import sys
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/3] toaster: recipe links broken for default layers
2017-09-04 4:02 [PATCH 0/3] toaster: cummulative 03092017 patch David Reyna
2017-09-04 4:02 ` [PATCH 1/3] toaster: missing ToasterSetting import David Reyna
@ 2017-09-04 4:02 ` David Reyna
2017-09-04 4:02 ` [PATCH 3/3] toaster: edit column list not sorted David Reyna
2 siblings, 0 replies; 4+ messages in thread
From: David Reyna @ 2017-09-04 4:02 UTC (permalink / raw)
To: bitbake-devel
From: David Reyna <David.Reyna@windriver.com>
The default layers are missing the recipe link definitions in
the fixture files, and because they are predefined they do not
get the updated information from the Layer Index.
[YOCTO #12006]
Signed-off-by: David Reyna <David.Reyna@windriver.com>
---
lib/toaster/orm/fixtures/oe-core.xml | 3 +++
lib/toaster/orm/fixtures/poky.xml | 9 +++++++++
lib/toaster/orm/management/commands/lsupdates.py | 2 ++
3 files changed, 14 insertions(+)
diff --git a/lib/toaster/orm/fixtures/oe-core.xml b/lib/toaster/orm/fixtures/oe-core.xml
index e285ec6..66c3595 100644
--- a/lib/toaster/orm/fixtures/oe-core.xml
+++ b/lib/toaster/orm/fixtures/oe-core.xml
@@ -65,6 +65,9 @@
<object model="orm.layer" pk="1">
<field type="CharField" name="name">openembedded-core</field>
<field type="CharField" name="vcs_url">git://git.openembedded.org/openembedded-core</field>
+ <field type="CharField" name="vcs_web_url">http://cgit.openembedded.org/openembedded-core</field>
+ <field type="CharField" name="vcs_web_tree_base_url">http://cgit.openembedded.org/openembedded-core/tree/%path%?h=%branch%</field>
+ <field type="CharField" name="vcs_web_file_base_url">http://cgit.openembedded.org/openembedded-core/tree/%path%?h=%branch%</field>
</object>
<object model="orm.layer_version" pk="1">
<field rel="ManyToOneRel" to="orm.layer" name="layer">1</field>
diff --git a/lib/toaster/orm/fixtures/poky.xml b/lib/toaster/orm/fixtures/poky.xml
index b3f6c96..7827aac 100644
--- a/lib/toaster/orm/fixtures/poky.xml
+++ b/lib/toaster/orm/fixtures/poky.xml
@@ -97,6 +97,9 @@
<field type="CharField" name="name">openembedded-core</field>
<field type="CharField" name="layer_index_url"></field>
<field type="CharField" name="vcs_url">git://git.yoctoproject.org/poky</field>
+ <field type="CharField" name="vcs_web_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky</field>
+ <field type="CharField" name="vcs_web_tree_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
+ <field type="CharField" name="vcs_web_file_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
</object>
<object model="orm.layer_version" pk="1">
<field rel="ManyToOneRel" to="orm.layer" name="layer">1</field>
@@ -125,6 +128,9 @@
<field type="CharField" name="name">meta-poky</field>
<field type="CharField" name="layer_index_url"></field>
<field type="CharField" name="vcs_url">git://git.yoctoproject.org/poky</field>
+ <field type="CharField" name="vcs_web_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky</field>
+ <field type="CharField" name="vcs_web_tree_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
+ <field type="CharField" name="vcs_web_file_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
</object>
<object model="orm.layer_version" pk="4">
<field rel="ManyToOneRel" to="orm.layer" name="layer">2</field>
@@ -153,6 +159,9 @@
<field type="CharField" name="name">meta-yocto-bsp</field>
<field type="CharField" name="layer_index_url"></field>
<field type="CharField" name="vcs_url">git://git.yoctoproject.org/poky</field>
+ <field type="CharField" name="vcs_web_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky</field>
+ <field type="CharField" name="vcs_web_tree_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
+ <field type="CharField" name="vcs_web_file_base_url">http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/%path%?h=%branch%</field>
</object>
<object model="orm.layer_version" pk="7">
<field rel="ManyToOneRel" to="orm.layer" name="layer">3</field>
diff --git a/lib/toaster/orm/management/commands/lsupdates.py b/lib/toaster/orm/management/commands/lsupdates.py
index 54b4fab..efc6b3a 100644
--- a/lib/toaster/orm/management/commands/lsupdates.py
+++ b/lib/toaster/orm/management/commands/lsupdates.py
@@ -166,6 +166,8 @@ class Command(BaseCommand):
l.description = li['description']
if created:
+ # predefined layers in the fixtures (for example poky.xml)
+ # always preempt the Layer Index for these values
l.vcs_url = li['vcs_url']
l.vcs_web_url = li['vcs_web_url']
l.vcs_web_tree_base_url = li['vcs_web_tree_base_url']
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH 3/3] toaster: edit column list not sorted
2017-09-04 4:02 [PATCH 0/3] toaster: cummulative 03092017 patch David Reyna
2017-09-04 4:02 ` [PATCH 1/3] toaster: missing ToasterSetting import David Reyna
2017-09-04 4:02 ` [PATCH 2/3] toaster: recipe links broken for default layers David Reyna
@ 2017-09-04 4:02 ` David Reyna
2 siblings, 0 replies; 4+ messages in thread
From: David Reyna @ 2017-09-04 4:02 UTC (permalink / raw)
To: bitbake-devel
From: David Reyna <David.Reyna@windriver.com>
The list of columns in the many 'Edit Columns' pop-ups became unsorted
with the 'Toaster Table' implementation. These entries need to be
gathered and sorted in the column processing.
[YOCTO #12004]
Signed-off-by: David Reyna <David.Reyna@windriver.com>
---
lib/toaster/toastergui/static/js/table.js | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/lib/toaster/toastergui/static/js/table.js b/lib/toaster/toastergui/static/js/table.js
index 1bbc8d1..abcb5ca 100644
--- a/lib/toaster/toastergui/static/js/table.js
+++ b/lib/toaster/toastergui/static/js/table.js
@@ -202,6 +202,7 @@ function tableInit(ctx){
}
/* Add table header and column toggle menu */
+ var column_edit_entries = [];
for (var i in tableData.columns){
var col = tableData.columns[i];
if (col.displayable === false) {
@@ -293,9 +294,17 @@ function tableInit(ctx){
defaultHiddenCols.push(col.field_name);
}
- editColMenu.append(toggler);
+ /* Gather the Edit Column entries */
+ column_edit_entries.push({'title':col.title,'html':toggler});
+
} /* End for each column */
+ /* Append the sorted Edit Column toggler entries */
+ column_edit_entries.sort(function(a,b) {return (a.title > b.title) ? 1 : ((b.title > a.title) ? -1 : 0);} );
+ for (var col in column_edit_entries){
+ editColMenu.append(column_edit_entries[col].html);
+ }
+
tableChromeDone = true;
}
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread