Merge lp:~mhall119/ubuntu-accomplishments-web/add-south into lp:ubuntu-accomplishments-web
- add-south
- Merge into trunk
Proposed by
Michael Hall
Status: | Merged |
---|---|
Merged at revision: | 228 |
Proposed branch: | lp:~mhall119/ubuntu-accomplishments-web/add-south |
Merge into: | lp:ubuntu-accomplishments-web |
Prerequisite: | lp:~mhall119/ubuntu-accomplishments-web/local-settings |
Diff against target: |
432 lines (+373/-1) 6 files modified
README.md (+2/-1) common/migrations/0001_initial.py (+273/-0) gallery/migrations/0001_initial.py (+20/-0) pip.txt (+1/-0) settings.py (+1/-0) users/migrations/0001_initial.py (+76/-0) |
To merge this branch: | bzr merge lp:~mhall119/ubuntu-accomplishments-web/add-south |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
ubuntu-accomplishments-web-editor-drivers | Pending | ||
Review via email: mp+129994@code.launchpad.net |
Commit message
Description of the change
Adds dependency on South for database migration. Includes initial migration scripts for the existing models.
To post a comment you must log in.
Revision history for this message
Janos Gyerik (janos-gyerik) wrote : | # |
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'README.md' | |||
2 | --- README.md 2012-10-16 21:48:22 +0000 | |||
3 | +++ README.md 2012-10-16 21:48:22 +0000 | |||
4 | @@ -14,11 +14,12 @@ | |||
5 | 14 | 14 | ||
6 | 15 | 3. Install required python modules | 15 | 3. Install required python modules |
7 | 16 | 16 | ||
9 | 17 | sudo apt-get install python-django-openid-auth | 17 | sudo apt-get install python-django-openid-auth python-django-south |
10 | 18 | 18 | ||
11 | 19 | 4. Create database (sqlite3), and admin account | 19 | 4. Create database (sqlite3), and admin account |
12 | 20 | 20 | ||
13 | 21 | ./manage.py syncdb --noinput | 21 | ./manage.py syncdb --noinput |
14 | 22 | ./manage.py migrate --noinput | ||
15 | 22 | 23 | ||
16 | 23 | 5. Import accomplishments into Django's database | 24 | 5. Import accomplishments into Django's database |
17 | 24 | 25 | ||
18 | 25 | 26 | ||
19 | === added directory 'common/migrations' | |||
20 | === added file 'common/migrations/0001_initial.py' | |||
21 | --- common/migrations/0001_initial.py 1970-01-01 00:00:00 +0000 | |||
22 | +++ common/migrations/0001_initial.py 2012-10-16 21:48:22 +0000 | |||
23 | @@ -0,0 +1,273 @@ | |||
24 | 1 | # -*- coding: utf-8 -*- | ||
25 | 2 | import datetime | ||
26 | 3 | from south.db import db | ||
27 | 4 | from south.v2 import SchemaMigration | ||
28 | 5 | from django.db import models | ||
29 | 6 | |||
30 | 7 | |||
31 | 8 | class Migration(SchemaMigration): | ||
32 | 9 | |||
33 | 10 | def forwards(self, orm): | ||
34 | 11 | # Adding model 'Lang' | ||
35 | 12 | db.create_table('common_lang', ( | ||
36 | 13 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
37 | 14 | ('locale_name', self.gf('django.db.models.fields.SlugField')(max_length=7)), | ||
38 | 15 | ('language_code', self.gf('django.db.models.fields.SlugField')(max_length=7)), | ||
39 | 16 | ('display_name', self.gf('django.db.models.fields.CharField')(max_length=50)), | ||
40 | 17 | )) | ||
41 | 18 | db.send_create_signal('common', ['Lang']) | ||
42 | 19 | |||
43 | 20 | # Adding unique constraint on 'Lang', fields ['locale_name', 'language_code'] | ||
44 | 21 | db.create_unique('common_lang', ['locale_name', 'language_code']) | ||
45 | 22 | |||
46 | 23 | # Adding model 'Collection' | ||
47 | 24 | db.create_table('common_collection', ( | ||
48 | 25 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
49 | 26 | ('descriptor', self.gf('django.db.models.fields.CharField')(unique=True, max_length=256)), | ||
50 | 27 | ('label', self.gf('django.db.models.fields.CharField')(max_length=128)), | ||
51 | 28 | )) | ||
52 | 29 | db.send_create_signal('common', ['Collection']) | ||
53 | 30 | |||
54 | 31 | # Adding model 'Category' | ||
55 | 32 | db.create_table('common_category', ( | ||
56 | 33 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
57 | 34 | ('collection', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Collection'])), | ||
58 | 35 | ('label', self.gf('django.db.models.fields.CharField')(max_length=50)), | ||
59 | 36 | )) | ||
60 | 37 | db.send_create_signal('common', ['Category']) | ||
61 | 38 | |||
62 | 39 | # Adding model 'Icon' | ||
63 | 40 | db.create_table('common_icon', ( | ||
64 | 41 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
65 | 42 | ('collection', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Collection'])), | ||
66 | 43 | ('filename', self.gf('django.db.models.fields.CharField')(max_length=100)), | ||
67 | 44 | )) | ||
68 | 45 | db.send_create_signal('common', ['Icon']) | ||
69 | 46 | |||
70 | 47 | # Adding model 'Accomplishment' | ||
71 | 48 | db.create_table('common_accomplishment', ( | ||
72 | 49 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
73 | 50 | ('descriptor', self.gf('django.db.models.fields.CharField')(unique=True, max_length=512)), | ||
74 | 51 | ('collection', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Collection'])), | ||
75 | 52 | ('accomid', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), | ||
76 | 53 | ('needs_information', self.gf('django.db.models.fields.TextField')()), | ||
77 | 54 | ('icon', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Icon'])), | ||
78 | 55 | ('needs_signing', self.gf('django.db.models.fields.BooleanField')(default=False)), | ||
79 | 56 | )) | ||
80 | 57 | db.send_create_signal('common', ['Accomplishment']) | ||
81 | 58 | |||
82 | 59 | # Adding unique constraint on 'Accomplishment', fields ['collection', 'descriptor'] | ||
83 | 60 | db.create_unique('common_accomplishment', ['collection_id', 'descriptor']) | ||
84 | 61 | |||
85 | 62 | # Adding M2M table for field categories on 'Accomplishment' | ||
86 | 63 | db.create_table('common_accomplishment_categories', ( | ||
87 | 64 | ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), | ||
88 | 65 | ('accomplishment', models.ForeignKey(orm['common.accomplishment'], null=False)), | ||
89 | 66 | ('category', models.ForeignKey(orm['common.category'], null=False)) | ||
90 | 67 | )) | ||
91 | 68 | db.create_unique('common_accomplishment_categories', ['accomplishment_id', 'category_id']) | ||
92 | 69 | |||
93 | 70 | # Adding M2M table for field depends on 'Accomplishment' | ||
94 | 71 | db.create_table('common_accomplishment_depends', ( | ||
95 | 72 | ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), | ||
96 | 73 | ('from_accomplishment', models.ForeignKey(orm['common.accomplishment'], null=False)), | ||
97 | 74 | ('to_accomplishment', models.ForeignKey(orm['common.accomplishment'], null=False)) | ||
98 | 75 | )) | ||
99 | 76 | db.create_unique('common_accomplishment_depends', ['from_accomplishment_id', 'to_accomplishment_id']) | ||
100 | 77 | |||
101 | 78 | # Adding model 'AccomplishmentTranslation' | ||
102 | 79 | db.create_table('common_accomplishmenttranslation', ( | ||
103 | 80 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
104 | 81 | ('accomplishment', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Accomplishment'])), | ||
105 | 82 | ('lang', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Lang'])), | ||
106 | 83 | ('title', self.gf('django.db.models.fields.CharField')(max_length=128)), | ||
107 | 84 | ('description', self.gf('django.db.models.fields.CharField')(max_length=512)), | ||
108 | 85 | ('summary', self.gf('django.db.models.fields.TextField')()), | ||
109 | 86 | ('steps', self.gf('django.db.models.fields.TextField')()), | ||
110 | 87 | ('links', self.gf('django.db.models.fields.TextField')(default='', blank=True)), | ||
111 | 88 | ('helpres', self.gf('django.db.models.fields.TextField')(default='', blank=True)), | ||
112 | 89 | ('tips', self.gf('django.db.models.fields.TextField')(default='', blank=True)), | ||
113 | 90 | ('pitfalls', self.gf('django.db.models.fields.TextField')(default='', blank=True)), | ||
114 | 91 | )) | ||
115 | 92 | db.send_create_signal('common', ['AccomplishmentTranslation']) | ||
116 | 93 | |||
117 | 94 | # Adding unique constraint on 'AccomplishmentTranslation', fields ['accomplishment', 'lang'] | ||
118 | 95 | db.create_unique('common_accomplishmenttranslation', ['accomplishment_id', 'lang_id']) | ||
119 | 96 | |||
120 | 97 | # Adding model 'AccomplishmentProposal' | ||
121 | 98 | db.create_table('common_accomplishmentproposal', ( | ||
122 | 99 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
123 | 100 | ('descriptor', self.gf('django.db.models.fields.CharField')(unique=True, max_length=512)), | ||
124 | 101 | ('collection', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Collection'])), | ||
125 | 102 | ('accomid', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), | ||
126 | 103 | ('needs_information', self.gf('django.db.models.fields.TextField')()), | ||
127 | 104 | ('icon', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Icon'])), | ||
128 | 105 | ('needs_signing', self.gf('django.db.models.fields.BooleanField')(default=False)), | ||
129 | 106 | ('accomplishment', self.gf('django.db.models.fields.related.ForeignKey')(related_name='proposals', to=orm['common.Accomplishment'])), | ||
130 | 107 | ('user', self.gf('django.db.models.fields.CharField')(max_length=50)), | ||
131 | 108 | ('rejected_date', self.gf('django.db.models.fields.DateField')(null=True)), | ||
132 | 109 | )) | ||
133 | 110 | db.send_create_signal('common', ['AccomplishmentProposal']) | ||
134 | 111 | |||
135 | 112 | # Adding unique constraint on 'AccomplishmentProposal', fields ['collection', 'descriptor'] | ||
136 | 113 | db.create_unique('common_accomplishmentproposal', ['collection_id', 'descriptor']) | ||
137 | 114 | |||
138 | 115 | # Adding M2M table for field categories on 'AccomplishmentProposal' | ||
139 | 116 | db.create_table('common_accomplishmentproposal_categories', ( | ||
140 | 117 | ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), | ||
141 | 118 | ('accomplishmentproposal', models.ForeignKey(orm['common.accomplishmentproposal'], null=False)), | ||
142 | 119 | ('category', models.ForeignKey(orm['common.category'], null=False)) | ||
143 | 120 | )) | ||
144 | 121 | db.create_unique('common_accomplishmentproposal_categories', ['accomplishmentproposal_id', 'category_id']) | ||
145 | 122 | |||
146 | 123 | # Adding M2M table for field depends on 'AccomplishmentProposal' | ||
147 | 124 | db.create_table('common_accomplishmentproposal_depends', ( | ||
148 | 125 | ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), | ||
149 | 126 | ('accomplishmentproposal', models.ForeignKey(orm['common.accomplishmentproposal'], null=False)), | ||
150 | 127 | ('accomplishment', models.ForeignKey(orm['common.accomplishment'], null=False)) | ||
151 | 128 | )) | ||
152 | 129 | db.create_unique('common_accomplishmentproposal_depends', ['accomplishmentproposal_id', 'accomplishment_id']) | ||
153 | 130 | |||
154 | 131 | # Adding model 'TrophyCache' | ||
155 | 132 | db.create_table('common_trophycache', ( | ||
156 | 133 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
157 | 134 | ('share_dirname', self.gf('django.db.models.fields.CharField')(max_length=256)), | ||
158 | 135 | ('accomplishment', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['common.Accomplishment'])), | ||
159 | 136 | ('date_accomplished', self.gf('django.db.models.fields.DateTimeField')()), | ||
160 | 137 | )) | ||
161 | 138 | db.send_create_signal('common', ['TrophyCache']) | ||
162 | 139 | |||
163 | 140 | # Adding unique constraint on 'TrophyCache', fields ['share_dirname', 'accomplishment'] | ||
164 | 141 | db.create_unique('common_trophycache', ['share_dirname', 'accomplishment_id']) | ||
165 | 142 | |||
166 | 143 | |||
167 | 144 | def backwards(self, orm): | ||
168 | 145 | # Removing unique constraint on 'TrophyCache', fields ['share_dirname', 'accomplishment'] | ||
169 | 146 | db.delete_unique('common_trophycache', ['share_dirname', 'accomplishment_id']) | ||
170 | 147 | |||
171 | 148 | # Removing unique constraint on 'AccomplishmentProposal', fields ['collection', 'descriptor'] | ||
172 | 149 | db.delete_unique('common_accomplishmentproposal', ['collection_id', 'descriptor']) | ||
173 | 150 | |||
174 | 151 | # Removing unique constraint on 'AccomplishmentTranslation', fields ['accomplishment', 'lang'] | ||
175 | 152 | db.delete_unique('common_accomplishmenttranslation', ['accomplishment_id', 'lang_id']) | ||
176 | 153 | |||
177 | 154 | # Removing unique constraint on 'Accomplishment', fields ['collection', 'descriptor'] | ||
178 | 155 | db.delete_unique('common_accomplishment', ['collection_id', 'descriptor']) | ||
179 | 156 | |||
180 | 157 | # Removing unique constraint on 'Lang', fields ['locale_name', 'language_code'] | ||
181 | 158 | db.delete_unique('common_lang', ['locale_name', 'language_code']) | ||
182 | 159 | |||
183 | 160 | # Deleting model 'Lang' | ||
184 | 161 | db.delete_table('common_lang') | ||
185 | 162 | |||
186 | 163 | # Deleting model 'Collection' | ||
187 | 164 | db.delete_table('common_collection') | ||
188 | 165 | |||
189 | 166 | # Deleting model 'Category' | ||
190 | 167 | db.delete_table('common_category') | ||
191 | 168 | |||
192 | 169 | # Deleting model 'Icon' | ||
193 | 170 | db.delete_table('common_icon') | ||
194 | 171 | |||
195 | 172 | # Deleting model 'Accomplishment' | ||
196 | 173 | db.delete_table('common_accomplishment') | ||
197 | 174 | |||
198 | 175 | # Removing M2M table for field categories on 'Accomplishment' | ||
199 | 176 | db.delete_table('common_accomplishment_categories') | ||
200 | 177 | |||
201 | 178 | # Removing M2M table for field depends on 'Accomplishment' | ||
202 | 179 | db.delete_table('common_accomplishment_depends') | ||
203 | 180 | |||
204 | 181 | # Deleting model 'AccomplishmentTranslation' | ||
205 | 182 | db.delete_table('common_accomplishmenttranslation') | ||
206 | 183 | |||
207 | 184 | # Deleting model 'AccomplishmentProposal' | ||
208 | 185 | db.delete_table('common_accomplishmentproposal') | ||
209 | 186 | |||
210 | 187 | # Removing M2M table for field categories on 'AccomplishmentProposal' | ||
211 | 188 | db.delete_table('common_accomplishmentproposal_categories') | ||
212 | 189 | |||
213 | 190 | # Removing M2M table for field depends on 'AccomplishmentProposal' | ||
214 | 191 | db.delete_table('common_accomplishmentproposal_depends') | ||
215 | 192 | |||
216 | 193 | # Deleting model 'TrophyCache' | ||
217 | 194 | db.delete_table('common_trophycache') | ||
218 | 195 | |||
219 | 196 | |||
220 | 197 | models = { | ||
221 | 198 | 'common.accomplishment': { | ||
222 | 199 | 'Meta': {'unique_together': "(('collection', 'descriptor'),)", 'object_name': 'Accomplishment'}, | ||
223 | 200 | 'accomid': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}), | ||
224 | 201 | 'categories': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['common.Category']", 'null': 'True', 'blank': 'True'}), | ||
225 | 202 | 'collection': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Collection']"}), | ||
226 | 203 | 'depends': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['common.Accomplishment']", 'null': 'True', 'blank': 'True'}), | ||
227 | 204 | 'descriptor': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '512'}), | ||
228 | 205 | 'icon': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Icon']"}), | ||
229 | 206 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
230 | 207 | 'needs_information': ('django.db.models.fields.TextField', [], {}), | ||
231 | 208 | 'needs_signing': ('django.db.models.fields.BooleanField', [], {'default': 'False'}) | ||
232 | 209 | }, | ||
233 | 210 | 'common.accomplishmentproposal': { | ||
234 | 211 | 'Meta': {'unique_together': "(('collection', 'descriptor'),)", 'object_name': 'AccomplishmentProposal'}, | ||
235 | 212 | 'accomid': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}), | ||
236 | 213 | 'accomplishment': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'proposals'", 'to': "orm['common.Accomplishment']"}), | ||
237 | 214 | 'categories': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['common.Category']", 'null': 'True', 'blank': 'True'}), | ||
238 | 215 | 'collection': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Collection']"}), | ||
239 | 216 | 'depends': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['common.Accomplishment']", 'null': 'True', 'blank': 'True'}), | ||
240 | 217 | 'descriptor': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '512'}), | ||
241 | 218 | 'icon': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Icon']"}), | ||
242 | 219 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
243 | 220 | 'needs_information': ('django.db.models.fields.TextField', [], {}), | ||
244 | 221 | 'needs_signing': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
245 | 222 | 'rejected_date': ('django.db.models.fields.DateField', [], {'null': 'True'}), | ||
246 | 223 | 'user': ('django.db.models.fields.CharField', [], {'max_length': '50'}) | ||
247 | 224 | }, | ||
248 | 225 | 'common.accomplishmenttranslation': { | ||
249 | 226 | 'Meta': {'unique_together': "(('accomplishment', 'lang'),)", 'object_name': 'AccomplishmentTranslation'}, | ||
250 | 227 | 'accomplishment': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Accomplishment']"}), | ||
251 | 228 | 'description': ('django.db.models.fields.CharField', [], {'max_length': '512'}), | ||
252 | 229 | 'helpres': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}), | ||
253 | 230 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
254 | 231 | 'lang': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Lang']"}), | ||
255 | 232 | 'links': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}), | ||
256 | 233 | 'pitfalls': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}), | ||
257 | 234 | 'steps': ('django.db.models.fields.TextField', [], {}), | ||
258 | 235 | 'summary': ('django.db.models.fields.TextField', [], {}), | ||
259 | 236 | 'tips': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}), | ||
260 | 237 | 'title': ('django.db.models.fields.CharField', [], {'max_length': '128'}) | ||
261 | 238 | }, | ||
262 | 239 | 'common.category': { | ||
263 | 240 | 'Meta': {'ordering': "('label',)", 'object_name': 'Category'}, | ||
264 | 241 | 'collection': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Collection']"}), | ||
265 | 242 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
266 | 243 | 'label': ('django.db.models.fields.CharField', [], {'max_length': '50'}) | ||
267 | 244 | }, | ||
268 | 245 | 'common.collection': { | ||
269 | 246 | 'Meta': {'object_name': 'Collection'}, | ||
270 | 247 | 'descriptor': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '256'}), | ||
271 | 248 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
272 | 249 | 'label': ('django.db.models.fields.CharField', [], {'max_length': '128'}) | ||
273 | 250 | }, | ||
274 | 251 | 'common.icon': { | ||
275 | 252 | 'Meta': {'object_name': 'Icon'}, | ||
276 | 253 | 'collection': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Collection']"}), | ||
277 | 254 | 'filename': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
278 | 255 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}) | ||
279 | 256 | }, | ||
280 | 257 | 'common.lang': { | ||
281 | 258 | 'Meta': {'ordering': "('locale_name',)", 'unique_together': "(('locale_name', 'language_code'),)", 'object_name': 'Lang'}, | ||
282 | 259 | 'display_name': ('django.db.models.fields.CharField', [], {'max_length': '50'}), | ||
283 | 260 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
284 | 261 | 'language_code': ('django.db.models.fields.SlugField', [], {'max_length': '7'}), | ||
285 | 262 | 'locale_name': ('django.db.models.fields.SlugField', [], {'max_length': '7'}) | ||
286 | 263 | }, | ||
287 | 264 | 'common.trophycache': { | ||
288 | 265 | 'Meta': {'unique_together': "(('share_dirname', 'accomplishment'),)", 'object_name': 'TrophyCache'}, | ||
289 | 266 | 'accomplishment': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.Accomplishment']"}), | ||
290 | 267 | 'date_accomplished': ('django.db.models.fields.DateTimeField', [], {}), | ||
291 | 268 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
292 | 269 | 'share_dirname': ('django.db.models.fields.CharField', [], {'max_length': '256'}) | ||
293 | 270 | } | ||
294 | 271 | } | ||
295 | 272 | |||
296 | 273 | complete_apps = ['common'] | ||
297 | 0 | \ No newline at end of file | 274 | \ No newline at end of file |
298 | 1 | 275 | ||
299 | === added file 'common/migrations/__init__.py' | |||
300 | === added directory 'gallery/migrations' | |||
301 | === added file 'gallery/migrations/0001_initial.py' | |||
302 | --- gallery/migrations/0001_initial.py 1970-01-01 00:00:00 +0000 | |||
303 | +++ gallery/migrations/0001_initial.py 2012-10-16 21:48:22 +0000 | |||
304 | @@ -0,0 +1,20 @@ | |||
305 | 1 | # -*- coding: utf-8 -*- | ||
306 | 2 | import datetime | ||
307 | 3 | from south.db import db | ||
308 | 4 | from south.v2 import SchemaMigration | ||
309 | 5 | from django.db import models | ||
310 | 6 | |||
311 | 7 | |||
312 | 8 | class Migration(SchemaMigration): | ||
313 | 9 | |||
314 | 10 | def forwards(self, orm): | ||
315 | 11 | pass | ||
316 | 12 | |||
317 | 13 | def backwards(self, orm): | ||
318 | 14 | pass | ||
319 | 15 | |||
320 | 16 | models = { | ||
321 | 17 | |||
322 | 18 | } | ||
323 | 19 | |||
324 | 20 | complete_apps = ['gallery'] | ||
325 | 0 | \ No newline at end of file | 21 | \ No newline at end of file |
326 | 1 | 22 | ||
327 | === added file 'gallery/migrations/__init__.py' | |||
328 | === modified file 'pip.txt' | |||
329 | --- pip.txt 2012-06-25 05:15:35 +0000 | |||
330 | +++ pip.txt 2012-10-16 21:48:22 +0000 | |||
331 | @@ -5,3 +5,4 @@ | |||
332 | 5 | django_openid_auth>=0.4 | 5 | django_openid_auth>=0.4 |
333 | 6 | pygpgme==0.2 | 6 | pygpgme==0.2 |
334 | 7 | python-openid==2.2.5 | 7 | python-openid==2.2.5 |
335 | 8 | South>=0.7 | ||
336 | 8 | 9 | ||
337 | === modified file 'settings.py' | |||
338 | --- settings.py 2012-10-16 21:48:22 +0000 | |||
339 | +++ settings.py 2012-10-16 21:48:22 +0000 | |||
340 | @@ -145,6 +145,7 @@ | |||
341 | 145 | # Uncomment the next line to enable admin documentation: | 145 | # Uncomment the next line to enable admin documentation: |
342 | 146 | # 'django.contrib.admindocs', | 146 | # 'django.contrib.admindocs', |
343 | 147 | 'django_openid_auth', | 147 | 'django_openid_auth', |
344 | 148 | 'south', | ||
345 | 148 | ) | 149 | ) |
346 | 149 | 150 | ||
347 | 150 | # A sample logging configuration. The only tangible logging | 151 | # A sample logging configuration. The only tangible logging |
348 | 151 | 152 | ||
349 | === added directory 'users/migrations' | |||
350 | === added file 'users/migrations/0001_initial.py' | |||
351 | --- users/migrations/0001_initial.py 1970-01-01 00:00:00 +0000 | |||
352 | +++ users/migrations/0001_initial.py 2012-10-16 21:48:22 +0000 | |||
353 | @@ -0,0 +1,76 @@ | |||
354 | 1 | # -*- coding: utf-8 -*- | ||
355 | 2 | import datetime | ||
356 | 3 | from south.db import db | ||
357 | 4 | from south.v2 import SchemaMigration | ||
358 | 5 | from django.db import models | ||
359 | 6 | |||
360 | 7 | |||
361 | 8 | class Migration(SchemaMigration): | ||
362 | 9 | |||
363 | 10 | def forwards(self, orm): | ||
364 | 11 | # Adding model 'UserProfile' | ||
365 | 12 | db.create_table('users_userprofile', ( | ||
366 | 13 | ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), | ||
367 | 14 | ('user', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['auth.User'], unique=True)), | ||
368 | 15 | ('username', self.gf('django.db.models.fields.SlugField')(unique=True, max_length=50)), | ||
369 | 16 | ('share_id', self.gf('django.db.models.fields.CharField')(max_length=200, blank=True)), | ||
370 | 17 | ('share_name', self.gf('django.db.models.fields.CharField')(max_length=200, blank=True)), | ||
371 | 18 | ('share_dirname', self.gf('django.db.models.fields.CharField')(max_length=200, blank=True)), | ||
372 | 19 | )) | ||
373 | 20 | db.send_create_signal('users', ['UserProfile']) | ||
374 | 21 | |||
375 | 22 | |||
376 | 23 | def backwards(self, orm): | ||
377 | 24 | # Deleting model 'UserProfile' | ||
378 | 25 | db.delete_table('users_userprofile') | ||
379 | 26 | |||
380 | 27 | |||
381 | 28 | models = { | ||
382 | 29 | 'auth.group': { | ||
383 | 30 | 'Meta': {'object_name': 'Group'}, | ||
384 | 31 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
385 | 32 | 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}), | ||
386 | 33 | 'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}) | ||
387 | 34 | }, | ||
388 | 35 | 'auth.permission': { | ||
389 | 36 | 'Meta': {'ordering': "('content_type__app_label', 'content_type__model', 'codename')", 'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'}, | ||
390 | 37 | 'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
391 | 38 | 'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}), | ||
392 | 39 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
393 | 40 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '50'}) | ||
394 | 41 | }, | ||
395 | 42 | 'auth.user': { | ||
396 | 43 | 'Meta': {'object_name': 'User'}, | ||
397 | 44 | 'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}), | ||
398 | 45 | 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}), | ||
399 | 46 | 'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}), | ||
400 | 47 | 'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}), | ||
401 | 48 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
402 | 49 | 'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), | ||
403 | 50 | 'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
404 | 51 | 'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), | ||
405 | 52 | 'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}), | ||
406 | 53 | 'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}), | ||
407 | 54 | 'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}), | ||
408 | 55 | 'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}), | ||
409 | 56 | 'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) | ||
410 | 57 | }, | ||
411 | 58 | 'contenttypes.contenttype': { | ||
412 | 59 | 'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"}, | ||
413 | 60 | 'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
414 | 61 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
415 | 62 | 'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}), | ||
416 | 63 | 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}) | ||
417 | 64 | }, | ||
418 | 65 | 'users.userprofile': { | ||
419 | 66 | 'Meta': {'object_name': 'UserProfile'}, | ||
420 | 67 | 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), | ||
421 | 68 | 'share_dirname': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}), | ||
422 | 69 | 'share_id': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}), | ||
423 | 70 | 'share_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}), | ||
424 | 71 | 'user': ('django.db.models.fields.related.OneToOneField', [], {'to': "orm['auth.User']", 'unique': 'True'}), | ||
425 | 72 | 'username': ('django.db.models.fields.SlugField', [], {'unique': 'True', 'max_length': '50'}) | ||
426 | 73 | } | ||
427 | 74 | } | ||
428 | 75 | |||
429 | 76 | complete_apps = ['users'] | ||
430 | 0 | \ No newline at end of file | 77 | \ No newline at end of file |
431 | 1 | 78 | ||
432 | === added file 'users/migrations/__init__.py' |
Thanks a lot Mike, both very nice branches!