diff options
author | coderick14 | 2017-05-17 15:40:18 +0530 |
---|---|---|
committer | coderick14 | 2017-05-17 15:41:00 +0530 |
commit | a1e0a5502f04da68b6a9ca8508dda3f9d7e1d055 (patch) | |
tree | 20181e6b1936f50ad48d8e35720d64a37566f558 /sbhs_server/tables/migrations/0006_load_sample_users_data.py | |
parent | 6f4a84c1e58ff4d54aab94cbee26e995328b05b8 (diff) | |
download | SBHS-2018-Rpi-a1e0a5502f04da68b6a9ca8508dda3f9d7e1d055.tar.gz SBHS-2018-Rpi-a1e0a5502f04da68b6a9ca8508dda3f9d7e1d055.tar.bz2 SBHS-2018-Rpi-a1e0a5502f04da68b6a9ca8508dda3f9d7e1d055.zip |
Upgrade to Django 1.11
- Database integration yet to be tested
Diffstat (limited to 'sbhs_server/tables/migrations/0006_load_sample_users_data.py')
-rw-r--r-- | sbhs_server/tables/migrations/0006_load_sample_users_data.py | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/sbhs_server/tables/migrations/0006_load_sample_users_data.py b/sbhs_server/tables/migrations/0006_load_sample_users_data.py deleted file mode 100644 index 5f287ac..0000000 --- a/sbhs_server/tables/migrations/0006_load_sample_users_data.py +++ /dev/null @@ -1,84 +0,0 @@ -# -*- coding: utf-8 -*- -from south.utils import datetime_utils as datetime -from south.db import db -from south.v2 import SchemaMigration -from django.db import models -from sbhs_server.tables.models import Account - -class Migration(SchemaMigration): - - def forwards(self, orm): - for i in xrange(1, 41): - account = Account( - name="Sample User %d" % i, - username="suser%d" % i, - email="suser%d@os-hardware.in" % i, - board_id=i, - is_active=1 - ) - account.set_password("suser%d%d" % (i, 4229)) - account.save() - - def backwards(self, orm): - for i in xrange(1, 41): - Account.objects.filter(username="suser%d" % i).delete() - - models = { - u'tables.account': { - 'Meta': {'object_name': 'Account'}, - 'board': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['tables.Board']"}), - 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), - 'email': ('django.db.models.fields.EmailField', [], {'unique': 'True', 'max_length': '255'}), - u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), - 'is_admin': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), - 'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}), - 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}), - 'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}), - 'trashed_at': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), - 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}), - 'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '127'}) - }, - u'tables.board': { - 'Meta': {'object_name': 'Board'}, - 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), - u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'mid': ('django.db.models.fields.IntegerField', [], {'unique': 'True'}), - 'online': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), - 'trashed_at': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), - 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}) - }, - u'tables.booking': { - 'Meta': {'object_name': 'Booking'}, - 'account': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['tables.Account']"}), - 'booking_date': ('django.db.models.fields.DateTimeField', [], {}), - 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), - u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'slot': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['tables.Slot']"}), - 'trashed_at': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), - 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}) - }, - u'tables.experiment': { - 'Meta': {'object_name': 'Experiment'}, - 'booking': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['tables.Booking']"}), - 'checksum': ('django.db.models.fields.CharField', [], {'default': "'NONE'", 'max_length': '255'}), - 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), - u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'log': ('django.db.models.fields.CharField', [], {'max_length': '255'}), - 'trashed_at': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), - 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}) - }, - u'tables.slot': { - 'Meta': {'object_name': 'Slot'}, - 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), - 'end_hour': ('django.db.models.fields.IntegerField', [], {}), - 'end_minute': ('django.db.models.fields.IntegerField', [], {}), - u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'start_hour': ('django.db.models.fields.IntegerField', [], {}), - 'start_minute': ('django.db.models.fields.IntegerField', [], {}), - 'trashed_at': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), - 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}) - } - } - - complete_apps = ['tables']
\ No newline at end of file |