diff options
author | Alexandru DAMIAN <alexandru.damian@intel.com> | 2014-06-30 18:33:04 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-07-23 20:06:58 +0100 |
commit | 6e71c276b582135228419d95174b7e7784d496b2 (patch) | |
tree | b9facea21ed3a3af49c80c01275ee1d0b64f8075 /bitbake/lib/toaster/orm/migrations | |
parent | 8a3789a7b11565aa2ceae0b79f93edb0d353173b (diff) | |
download | poky-6e71c276b582135228419d95174b7e7784d496b2.tar.gz |
bitbake: toaster: add project main edit page
This is the first commit on the project main edit page.
At this point we have:
* the default settings for a newly created project
* the ability to add targets
* the ability to trigger a build command, and have
the build executed
Project layers now have an optional field, allowing for
removal. Default meta, meta-yocto and meta-yocto-bsp
layers cannot be optional.
We add XHR calls for interactivity in the main page.
(Bitbake rev: 4e438854120cbd10319df1b571ec93e334002325)
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/orm/migrations')
-rw-r--r-- | bitbake/lib/toaster/orm/migrations/0012_auto__add_field_projectlayer_optional__add_field_projecttarget_task.py | 252 |
1 files changed, 252 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/orm/migrations/0012_auto__add_field_projectlayer_optional__add_field_projecttarget_task.py b/bitbake/lib/toaster/orm/migrations/0012_auto__add_field_projectlayer_optional__add_field_projecttarget_task.py new file mode 100644 index 0000000000..9e483f5dac --- /dev/null +++ b/bitbake/lib/toaster/orm/migrations/0012_auto__add_field_projectlayer_optional__add_field_projecttarget_task.py | |||
@@ -0,0 +1,252 @@ | |||
1 | # -*- coding: utf-8 -*- | ||
2 | from south.utils import datetime_utils as datetime | ||
3 | from south.db import db | ||
4 | from south.v2 import SchemaMigration | ||
5 | from django.db import models | ||
6 | |||
7 | |||
8 | class Migration(SchemaMigration): | ||
9 | |||
10 | def forwards(self, orm): | ||
11 | # Adding field 'ProjectLayer.optional' | ||
12 | db.add_column(u'orm_projectlayer', 'optional', | ||
13 | self.gf('django.db.models.fields.BooleanField')(default=True), | ||
14 | keep_default=False) | ||
15 | |||
16 | # Adding field 'ProjectTarget.task' | ||
17 | db.add_column(u'orm_projecttarget', 'task', | ||
18 | self.gf('django.db.models.fields.CharField')(max_length=100, null=True), | ||
19 | keep_default=False) | ||
20 | |||
21 | |||
22 | def backwards(self, orm): | ||
23 | # Deleting field 'ProjectLayer.optional' | ||
24 | db.delete_column(u'orm_projectlayer', 'optional') | ||
25 | |||
26 | # Deleting field 'ProjectTarget.task' | ||
27 | db.delete_column(u'orm_projecttarget', 'task') | ||
28 | |||
29 | |||
30 | models = { | ||
31 | u'orm.build': { | ||
32 | 'Meta': {'object_name': 'Build'}, | ||
33 | 'bitbake_version': ('django.db.models.fields.CharField', [], {'max_length': '50'}), | ||
34 | 'build_name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
35 | 'completed_on': ('django.db.models.fields.DateTimeField', [], {}), | ||
36 | 'cooker_log_path': ('django.db.models.fields.CharField', [], {'max_length': '500'}), | ||
37 | 'distro': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
38 | 'distro_version': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
39 | 'errors_no': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
40 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
41 | 'machine': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
42 | 'outcome': ('django.db.models.fields.IntegerField', [], {'default': '2'}), | ||
43 | 'project': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Project']", 'null': 'True'}), | ||
44 | 'started_on': ('django.db.models.fields.DateTimeField', [], {}), | ||
45 | 'timespent': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
46 | 'warnings_no': ('django.db.models.fields.IntegerField', [], {'default': '0'}) | ||
47 | }, | ||
48 | u'orm.helptext': { | ||
49 | 'Meta': {'object_name': 'HelpText'}, | ||
50 | 'area': ('django.db.models.fields.IntegerField', [], {}), | ||
51 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'helptext_build'", 'to': u"orm['orm.Build']"}), | ||
52 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
53 | 'key': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
54 | 'text': ('django.db.models.fields.TextField', [], {}) | ||
55 | }, | ||
56 | u'orm.layer': { | ||
57 | 'Meta': {'object_name': 'Layer'}, | ||
58 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
59 | 'layer_index_url': ('django.db.models.fields.URLField', [], {'max_length': '200'}), | ||
60 | 'local_path': ('django.db.models.fields.FilePathField', [], {'max_length': '255'}), | ||
61 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}) | ||
62 | }, | ||
63 | u'orm.layer_version': { | ||
64 | 'Meta': {'object_name': 'Layer_Version'}, | ||
65 | 'branch': ('django.db.models.fields.CharField', [], {'max_length': '50'}), | ||
66 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'layer_version_build'", 'to': u"orm['orm.Build']"}), | ||
67 | 'commit': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
68 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
69 | 'layer': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'layer_version_layer'", 'to': u"orm['orm.Layer']"}), | ||
70 | 'priority': ('django.db.models.fields.IntegerField', [], {}) | ||
71 | }, | ||
72 | u'orm.logmessage': { | ||
73 | 'Meta': {'object_name': 'LogMessage'}, | ||
74 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Build']"}), | ||
75 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
76 | 'level': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
77 | 'lineno': ('django.db.models.fields.IntegerField', [], {'null': 'True'}), | ||
78 | 'message': ('django.db.models.fields.CharField', [], {'max_length': '240'}), | ||
79 | 'pathname': ('django.db.models.fields.FilePathField', [], {'max_length': '255', 'blank': 'True'}), | ||
80 | 'task': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Task']", 'null': 'True', 'blank': 'True'}) | ||
81 | }, | ||
82 | u'orm.package': { | ||
83 | 'Meta': {'object_name': 'Package'}, | ||
84 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Build']"}), | ||
85 | 'description': ('django.db.models.fields.TextField', [], {'blank': 'True'}), | ||
86 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
87 | 'installed_name': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '100'}), | ||
88 | 'installed_size': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
89 | 'license': ('django.db.models.fields.CharField', [], {'max_length': '80', 'blank': 'True'}), | ||
90 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
91 | 'recipe': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Recipe']", 'null': 'True'}), | ||
92 | 'revision': ('django.db.models.fields.CharField', [], {'max_length': '32', 'blank': 'True'}), | ||
93 | 'section': ('django.db.models.fields.CharField', [], {'max_length': '80', 'blank': 'True'}), | ||
94 | 'size': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
95 | 'summary': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}), | ||
96 | 'version': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}) | ||
97 | }, | ||
98 | u'orm.package_dependency': { | ||
99 | 'Meta': {'object_name': 'Package_Dependency'}, | ||
100 | 'dep_type': ('django.db.models.fields.IntegerField', [], {}), | ||
101 | 'depends_on': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'package_dependencies_target'", 'to': u"orm['orm.Package']"}), | ||
102 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
103 | 'package': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'package_dependencies_source'", 'to': u"orm['orm.Package']"}), | ||
104 | 'target': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Target']", 'null': 'True'}) | ||
105 | }, | ||
106 | u'orm.package_file': { | ||
107 | 'Meta': {'object_name': 'Package_File'}, | ||
108 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
109 | 'package': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'buildfilelist_package'", 'to': u"orm['orm.Package']"}), | ||
110 | 'path': ('django.db.models.fields.FilePathField', [], {'max_length': '255', 'blank': 'True'}), | ||
111 | 'size': ('django.db.models.fields.IntegerField', [], {}) | ||
112 | }, | ||
113 | u'orm.project': { | ||
114 | 'Meta': {'object_name': 'Project'}, | ||
115 | 'branch': ('django.db.models.fields.CharField', [], {'max_length': '50'}), | ||
116 | 'created': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), | ||
117 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
118 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
119 | 'short_description': ('django.db.models.fields.CharField', [], {'max_length': '50', 'blank': 'True'}), | ||
120 | 'updated': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}), | ||
121 | 'user_id': ('django.db.models.fields.IntegerField', [], {'null': 'True'}) | ||
122 | }, | ||
123 | u'orm.projectlayer': { | ||
124 | 'Meta': {'object_name': 'ProjectLayer'}, | ||
125 | 'commit': ('django.db.models.fields.CharField', [], {'max_length': '254'}), | ||
126 | 'dirpath': ('django.db.models.fields.CharField', [], {'max_length': '254'}), | ||
127 | 'giturl': ('django.db.models.fields.CharField', [], {'max_length': '254'}), | ||
128 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
129 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
130 | 'optional': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), | ||
131 | 'project': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Project']"}) | ||
132 | }, | ||
133 | u'orm.projecttarget': { | ||
134 | 'Meta': {'object_name': 'ProjectTarget'}, | ||
135 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
136 | 'project': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Project']"}), | ||
137 | 'target': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
138 | 'task': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'}) | ||
139 | }, | ||
140 | u'orm.projectvariable': { | ||
141 | 'Meta': {'object_name': 'ProjectVariable'}, | ||
142 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
143 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
144 | 'project': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Project']"}), | ||
145 | 'value': ('django.db.models.fields.TextField', [], {'blank': 'True'}) | ||
146 | }, | ||
147 | u'orm.recipe': { | ||
148 | 'Meta': {'object_name': 'Recipe'}, | ||
149 | 'bugtracker': ('django.db.models.fields.URLField', [], {'max_length': '200', 'blank': 'True'}), | ||
150 | 'description': ('django.db.models.fields.TextField', [], {'blank': 'True'}), | ||
151 | 'file_path': ('django.db.models.fields.FilePathField', [], {'max_length': '255'}), | ||
152 | 'homepage': ('django.db.models.fields.URLField', [], {'max_length': '200', 'blank': 'True'}), | ||
153 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
154 | 'layer_version': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'recipe_layer_version'", 'to': u"orm['orm.Layer_Version']"}), | ||
155 | 'license': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}), | ||
156 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}), | ||
157 | 'section': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}), | ||
158 | 'summary': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}), | ||
159 | 'version': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}) | ||
160 | }, | ||
161 | u'orm.recipe_dependency': { | ||
162 | 'Meta': {'object_name': 'Recipe_Dependency'}, | ||
163 | 'dep_type': ('django.db.models.fields.IntegerField', [], {}), | ||
164 | 'depends_on': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'r_dependencies_depends'", 'to': u"orm['orm.Recipe']"}), | ||
165 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
166 | 'recipe': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'r_dependencies_recipe'", 'to': u"orm['orm.Recipe']"}) | ||
167 | }, | ||
168 | u'orm.target': { | ||
169 | 'Meta': {'object_name': 'Target'}, | ||
170 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Build']"}), | ||
171 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
172 | 'image_size': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
173 | 'is_image': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
174 | 'license_manifest_path': ('django.db.models.fields.CharField', [], {'max_length': '500', 'null': 'True'}), | ||
175 | 'target': ('django.db.models.fields.CharField', [], {'max_length': '100'}) | ||
176 | }, | ||
177 | u'orm.target_file': { | ||
178 | 'Meta': {'object_name': 'Target_File'}, | ||
179 | 'directory': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'directory_set'", 'null': 'True', 'to': u"orm['orm.Target_File']"}), | ||
180 | 'group': ('django.db.models.fields.CharField', [], {'max_length': '128'}), | ||
181 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
182 | 'inodetype': ('django.db.models.fields.IntegerField', [], {}), | ||
183 | 'owner': ('django.db.models.fields.CharField', [], {'max_length': '128'}), | ||
184 | 'path': ('django.db.models.fields.FilePathField', [], {'max_length': '100'}), | ||
185 | 'permission': ('django.db.models.fields.CharField', [], {'max_length': '16'}), | ||
186 | 'size': ('django.db.models.fields.IntegerField', [], {}), | ||
187 | 'sym_target': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'symlink_set'", 'null': 'True', 'to': u"orm['orm.Target_File']"}), | ||
188 | 'target': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Target']"}) | ||
189 | }, | ||
190 | u'orm.target_image_file': { | ||
191 | 'Meta': {'object_name': 'Target_Image_File'}, | ||
192 | 'file_name': ('django.db.models.fields.FilePathField', [], {'max_length': '254'}), | ||
193 | 'file_size': ('django.db.models.fields.IntegerField', [], {}), | ||
194 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
195 | 'target': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Target']"}) | ||
196 | }, | ||
197 | u'orm.target_installed_package': { | ||
198 | 'Meta': {'object_name': 'Target_Installed_Package'}, | ||
199 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
200 | 'package': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'buildtargetlist_package'", 'to': u"orm['orm.Package']"}), | ||
201 | 'target': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['orm.Target']"}) | ||
202 | }, | ||
203 | u'orm.task': { | ||
204 | 'Meta': {'ordering': "('order', 'recipe')", 'unique_together': "(('build', 'recipe', 'task_name'),)", 'object_name': 'Task'}, | ||
205 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'task_build'", 'to': u"orm['orm.Build']"}), | ||
206 | 'cpu_usage': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '6', 'decimal_places': '2'}), | ||
207 | 'disk_io': ('django.db.models.fields.IntegerField', [], {'null': 'True'}), | ||
208 | 'elapsed_time': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '6', 'decimal_places': '2'}), | ||
209 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
210 | 'line_number': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
211 | 'logfile': ('django.db.models.fields.FilePathField', [], {'max_length': '255', 'blank': 'True'}), | ||
212 | 'message': ('django.db.models.fields.CharField', [], {'max_length': '240'}), | ||
213 | 'order': ('django.db.models.fields.IntegerField', [], {'null': 'True'}), | ||
214 | 'outcome': ('django.db.models.fields.IntegerField', [], {'default': '-1'}), | ||
215 | 'path_to_sstate_obj': ('django.db.models.fields.FilePathField', [], {'max_length': '500', 'blank': 'True'}), | ||
216 | 'recipe': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'build_recipe'", 'to': u"orm['orm.Recipe']"}), | ||
217 | 'script_type': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
218 | 'source_url': ('django.db.models.fields.FilePathField', [], {'max_length': '255', 'blank': 'True'}), | ||
219 | 'sstate_checksum': ('django.db.models.fields.CharField', [], {'max_length': '100', 'blank': 'True'}), | ||
220 | 'sstate_result': ('django.db.models.fields.IntegerField', [], {'default': '0'}), | ||
221 | 'task_executed': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
222 | 'task_name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
223 | 'work_directory': ('django.db.models.fields.FilePathField', [], {'max_length': '255', 'blank': 'True'}) | ||
224 | }, | ||
225 | u'orm.task_dependency': { | ||
226 | 'Meta': {'object_name': 'Task_Dependency'}, | ||
227 | 'depends_on': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'task_dependencies_depends'", 'to': u"orm['orm.Task']"}), | ||
228 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
229 | 'task': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'task_dependencies_task'", 'to': u"orm['orm.Task']"}) | ||
230 | }, | ||
231 | u'orm.variable': { | ||
232 | 'Meta': {'object_name': 'Variable'}, | ||
233 | 'build': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'variable_build'", 'to': u"orm['orm.Build']"}), | ||
234 | 'changed': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
235 | 'description': ('django.db.models.fields.TextField', [], {'blank': 'True'}), | ||
236 | 'human_readable_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}), | ||
237 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
238 | 'variable_name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
239 | 'variable_value': ('django.db.models.fields.TextField', [], {'blank': 'True'}) | ||
240 | }, | ||
241 | u'orm.variablehistory': { | ||
242 | 'Meta': {'object_name': 'VariableHistory'}, | ||
243 | 'file_name': ('django.db.models.fields.FilePathField', [], {'max_length': '255'}), | ||
244 | u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
245 | 'line_number': ('django.db.models.fields.IntegerField', [], {'null': 'True'}), | ||
246 | 'operation': ('django.db.models.fields.CharField', [], {'max_length': '64'}), | ||
247 | 'value': ('django.db.models.fields.TextField', [], {'blank': 'True'}), | ||
248 | 'variable': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'vhistory'", 'to': u"orm['orm.Variable']"}) | ||
249 | } | ||
250 | } | ||
251 | |||
252 | complete_apps = ['orm'] \ No newline at end of file | ||