Python south.db.db.delete_table() Examples

The following are 30 code examples of south.db.db.delete_table(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module south.db.db , or try the search function .
Example #1
Source File: 0009_auto__del_scaglandusedefinition__del_scaglanduse__add_scagdmlandusedef.py    From urbanfootprint with GNU General Public License v3.0 6 votes vote down vote up
def backwards(self, orm):
        # Adding model 'ScagLandUseDefinition'
        db.create_table(u'main_scaglandusedefinition', (
            ('land_use_description', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)),
            ('land_use_type', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)),
            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
            ('land_use', self.gf('django.db.models.fields.IntegerField')()),
        ))
        db.send_create_signal('main', ['ScagLandUseDefinition'])

        # Adding model 'ScagLandUse'
        db.create_table(u'main_scaglanduse', (
            (u'builtform_ptr', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['main.BuiltForm'], unique=True, primary_key=True)),
            ('land_use_definition', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['main.ScagLandUseDefinition'])),
        ))
        db.send_create_signal('main', ['ScagLandUse'])

        # Deleting model 'ScagDmLandUseDefinition'
        db.delete_table(u'main_scagdmlandusedefinition')

        # Deleting model 'ScagDmLandUse'
        db.delete_table(u'main_scagdmlanduse') 
Example #2
Source File: 0009_auto__del_scaglandusedefinition__del_scaglanduse__add_scagdmlandusedef.py    From urbanfootprint with GNU General Public License v3.0 6 votes vote down vote up
def forwards(self, orm):
        # Deleting model 'ScagLandUseDefinition'
        db.delete_table(u'main_scaglandusedefinition')

        # Deleting model 'ScagLandUse'
        db.delete_table(u'main_scaglanduse')

        # Adding model 'ScagDmLandUseDefinition'
        db.create_table(u'main_scagdmlandusedefinition', (
            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
            ('land_use_description', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)),
            ('land_use_type', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)),
            ('land_use', self.gf('django.db.models.fields.IntegerField')()),
        ))
        db.send_create_signal('main', ['ScagDmLandUseDefinition'])

        # Adding model 'ScagDmLandUse'
        db.create_table(u'main_scagdmlanduse', (
            (u'builtform_ptr', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['main.BuiltForm'], unique=True, primary_key=True)),
            ('land_use_definition', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['main.ScagDmLandUseDefinition'])),
        ))
        db.send_create_signal('main', ['ScagDmLandUse']) 
Example #3
Source File: 0001_initial.py    From django-htk with MIT License 6 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Forum'
        db.delete_table('forums_forum')

        # Deleting model 'ForumThread'
        db.delete_table('forums_forumthread')

        # Removing M2M table for field tags on 'ForumThread'
        db.delete_table('forums_forumthread_tags')

        # Deleting model 'ForumMessage'
        db.delete_table('forums_forummessage')

        # Removing M2M table for field tags on 'ForumMessage'
        db.delete_table('forums_forummessage_tags')

        # Deleting model 'ForumTag'
        db.delete_table('forums_forumtag') 
Example #4
Source File: 0001_initial.py    From opensurfaces with MIT License 6 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'PhotoSceneCategory'
        db.delete_table(u'photos_photoscenecategory')

        # Deleting model 'FlickrUser'
        db.delete_table(u'photos_flickruser')

        # Deleting model 'PhotoLightStack'
        db.delete_table(u'photos_photolightstack')

        # Deleting model 'Photo'
        db.delete_table(u'photos_photo')

        # Deleting model 'PhotoSceneQualityLabel'
        db.delete_table(u'photos_photoscenequalitylabel')

        # Deleting model 'PhotoWhitebalanceLabel'
        db.delete_table(u'photos_photowhitebalancelabel') 
Example #5
Source File: 0001_initial.py    From baobab with GNU General Public License v3.0 6 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Service'
        db.delete_table(u'backoffice_service')

        # Deleting model 'Event'
        db.delete_table(u'backoffice_event')

        # Removing M2M table for field services on 'Event'
        db.delete_table('backoffice_event_services')

        # Deleting model 'EventLog'
        db.delete_table(u'backoffice_eventlog')

        # Deleting model 'TimeZoneEnum'
        db.delete_table(u'backoffice_timezoneenum')

        # Deleting model 'TimeZone'
        db.delete_table(u'backoffice_timezone') 
Example #6
Source File: 0001_initial.py    From baobab with GNU General Public License v3.0 6 votes vote down vote up
def backwards(self, orm):
        # Removing unique constraint on 'EventLogData', fields ['eventlog',
        # 'lang']
        db.delete_unique('translate_eventlogdata', ['eventlog_id', 'lang_id'])

        # Removing unique constraint on 'EventData', fields ['event', 'lang']
        db.delete_unique('translate_eventdata', ['event_id', 'lang_id'])

        # Deleting model 'Lang'
        db.delete_table('translate_lang')

        # Deleting model 'EventData'
        db.delete_table('translate_eventdata')

        # Deleting model 'EventLogData'
        db.delete_table('translate_eventlogdata') 
Example #7
Source File: 0001_initial.py    From acacia_main with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Session'
        db.delete_table('user_sessions_session') 
Example #8
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'ShapeRectifiedNormalLabel'
        db.delete_table(u'normals_shaperectifiednormallabel')

        # Deleting model 'ShapeRectifiedNormalQuality'
        db.delete_table(u'normals_shaperectifiednormalquality') 
Example #9
Source File: 0001_initial.py    From Collaboration-System with GNU General Public License v2.0 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Badge'
        db.delete_table('badges_badge')

        # Deleting model 'BadgeToUser'
        db.delete_table('badges_badgetouser') 
Example #10
Source File: 0001_initial.py    From django-connected with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Account'
        db.delete_table(u'connected_accounts_account') 
Example #11
Source File: 0003_auto__add_papercitation.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'PaperCitation'
        db.delete_table(u'common_papercitation') 
Example #12
Source File: 0003_auto__add_htkshorturl__add_htkshorturlaccess.py    From django-htk with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'HTKShortUrl'
        db.delete_table(u'htk_htkshorturl')

        # Deleting model 'HTKShortUrlAccess'
        db.delete_table(u'htk_htkshorturlaccess') 
Example #13
Source File: 0001_initial.py    From django-rest-authemail with GNU General Public License v3.0 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'SignupCode'
        db.delete_table(u'authemail_signupcode')

        # Deleting model 'PasswordResetCode'
        db.delete_table(u'authemail_passwordresetcode') 
Example #14
Source File: 0001_initial.py    From django-rest-authemail with GNU General Public License v3.0 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'MyUser'
        db.delete_table(u'accounts_myuser')

        # Removing M2M table for field groups on 'MyUser'
        db.delete_table(db.shorten_name(u'accounts_myuser_groups'))

        # Removing M2M table for field user_permissions on 'MyUser'
        db.delete_table(db.shorten_name(u'accounts_myuser_user_permissions')) 
Example #15
Source File: 0001_initial.py    From django-invoicing with GNU General Public License v2.0 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Invoice'
        db.delete_table('invoicing_invoices')

        # Deleting model 'Item'
        db.delete_table('invoicing_items') 
Example #16
Source File: 0001_initial.py    From django-htk with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Feedback'
        db.delete_table(u'htk_feedback')

        # Deleting model 'PrelaunchSignup'
        db.delete_table(u'htk_prelaunchsignup') 
Example #17
Source File: 0001_initial.py    From django-admin-tools with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Bookmark'
        db.delete_table('admin_tools_menu_bookmark') 
Example #18
Source File: 0001_initial.py    From scirius with GNU General Public License v3.0 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'SciriusUser'
        db.delete_table(u'accounts_sciriususer') 
Example #19
Source File: 0002_auto__del_cacheddata.py    From opensurfaces with MIT License 5 votes vote down vote up
def forwards(self, orm):
        # Deleting model 'CachedData'
        db.delete_table(u'common_cacheddata') 
Example #20
Source File: 0001_initial.py    From openduty with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'UserNotificationMethod'
        db.delete_table('openduty_usernotificationmethod')

        # Deleting model 'ScheduledNotification'
        db.delete_table('openduty_schedulednotification') 
Example #21
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'License'
        db.delete_table(u'licenses_license') 
Example #22
Source File: 0002_auto__del_materialshapenicenesslabel__del_field_materialshape_nice__de.py    From opensurfaces with MIT License 5 votes vote down vote up
def forwards(self, orm):
        # Deleting model 'MaterialShapeNicenessLabel'
        db.delete_table(u'shapes_materialshapenicenesslabel')

        # Deleting field 'MaterialShape.nice'
        db.delete_column(u'shapes_materialshape', 'nice')

        # Deleting field 'MaterialShape.nice_score'
        db.delete_column(u'shapes_materialshape', 'nice_score') 
Example #23
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'ShapeName'
        db.delete_table(u'shapes_shapename')

        # Deleting model 'ShapeSubstance'
        db.delete_table(u'shapes_shapesubstance')

        # Deleting model 'ShapeSubstanceGroup'
        db.delete_table(u'shapes_shapesubstancegroup')

        # Removing M2M table for field names on 'ShapeSubstanceGroup'
        db.delete_table(db.shorten_name(u'shapes_shapesubstancegroup_names'))

        # Deleting model 'MaterialShape'
        db.delete_table(u'shapes_materialshape')

        # Removing M2M table for field submitted_shapes on 'MaterialShape'
        db.delete_table(db.shorten_name(u'shapes_materialshape_submitted_shapes'))

        # Deleting model 'SubmittedShape'
        db.delete_table(u'shapes_submittedshape')

        # Deleting model 'ShapeSubstanceLabel'
        db.delete_table(u'shapes_shapesubstancelabel')

        # Deleting model 'MaterialShapeNameLabel'
        db.delete_table(u'shapes_materialshapenamelabel')

        # Deleting model 'ShapePlanarityLabel'
        db.delete_table(u'shapes_shapeplanaritylabel')

        # Deleting model 'MaterialShapeQuality'
        db.delete_table(u'shapes_materialshapequality')

        # Deleting model 'MaterialShapeNicenessLabel'
        db.delete_table(u'shapes_materialshapenicenesslabel') 
Example #24
Source File: 0007_auto__add_intrinsicimagesalgorithmbest__add_field_intrinsicimagesalgor.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'IntrinsicImagesAlgorithmBest'
        db.delete_table(u'intrinsic_intrinsicimagesalgorithmbest')

        # Deleting field 'IntrinsicImagesAlgorithm.iiw_mean_error'
        db.delete_column(u'intrinsic_intrinsicimagesalgorithm', 'iiw_mean_error') 
Example #25
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Removing unique constraint on 'IntrinsicImagesDecomposition', fields ['photo', 'algorithm']
        db.delete_unique(u'intrinsic_intrinsicimagesdecomposition', ['photo_id', 'algorithm_id'])

        # Removing unique constraint on 'IntrinsicImagesAlgorithm', fields ['slug', 'parameters']
        db.delete_unique(u'intrinsic_intrinsicimagesalgorithm', ['slug', 'parameters'])

        # Removing unique constraint on 'IntrinsicPointComparison', fields ['point1', 'point2']
        db.delete_unique(u'intrinsic_intrinsicpointcomparison', ['point1_id', 'point2_id'])

        # Deleting model 'IntrinsicPoint'
        db.delete_table(u'intrinsic_intrinsicpoint')

        # Deleting model 'IntrinsicPointOpacityResponse'
        db.delete_table(u'intrinsic_intrinsicpointopacityresponse')

        # Deleting model 'IntrinsicPointComparison'
        db.delete_table(u'intrinsic_intrinsicpointcomparison')

        # Deleting model 'IntrinsicPointComparisonResponse'
        db.delete_table(u'intrinsic_intrinsicpointcomparisonresponse')

        # Deleting model 'IntrinsicImagesAlgorithm'
        db.delete_table(u'intrinsic_intrinsicimagesalgorithm')

        # Deleting model 'IntrinsicImagesDecomposition'
        db.delete_table(u'intrinsic_intrinsicimagesdecomposition') 
Example #26
Source File: 0002_auto__add_intrinsicsyntheticdecomposition.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'IntrinsicSyntheticDecomposition'
        db.delete_table(u'intrinsic_intrinsicsyntheticdecomposition') 
Example #27
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'EnvironmentMap'
        db.delete_table(u'bsdfs_environmentmap')

        # Deleting model 'ShapeBsdfLabel_mf'
        db.delete_table(u'bsdfs_shapebsdflabel_mf')

        # Deleting model 'ShapeBsdfLabel_wd'
        db.delete_table(u'bsdfs_shapebsdflabel_wd')

        # Deleting model 'ShapeBsdfQuality'
        db.delete_table(u'bsdfs_shapebsdfquality') 
Example #28
Source File: 0001_initial.py    From opensurfaces with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'UserProfile'
        db.delete_table(u'accounts_userprofile') 
Example #29
Source File: 0001_initial.py    From djangocms-gmaps with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Map'
        db.delete_table(u'djangocms_gmaps_map')

        # Deleting model 'Location'
        db.delete_table(u'djangocms_gmaps_location') 
Example #30
Source File: 0028_auto__add_organization__add_field_documentsetformentry_organization__a.py    From crowdata with MIT License 5 votes vote down vote up
def backwards(self, orm):
        # Deleting model 'Organization'
        db.delete_table(u'crowdataapp_organization')

        # Removing M2M table for field users on 'Organization'
        db.delete_table(db.shorten_name(u'crowdataapp_organization_users'))

        # Deleting field 'DocumentSetFormEntry.organization'
        db.delete_column(u'crowdataapp_documentsetformentry', 'organization_id')

        # Deleting field 'UserProfile.current_organization'
        db.delete_column(u'crowdataapp_userprofile', 'current_organization_id')