Python south.db.db.delete_unique() Examples
The following are 30
code examples of south.db.db.delete_unique().
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: 0001_initial.py From baobab with GNU General Public License v3.0 | 6 votes |
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 #2
Source File: 0076_auto__add_unique_category_name.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Category', fields ['name'] db.delete_unique('canvas_category', ['name'])
Example #3
Source File: 0001_initial.py From django-dashboard-app with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'DashboardWidgetSettings', fields ['widget_name', 'setting_name'] db.delete_unique(u'dashboard_app_dashboardwidgetsettings', ['widget_name', 'setting_name']) # Deleting model 'DashboardWidgetLastUpdate' db.delete_table(u'dashboard_app_dashboardwidgetlastupdate') # Deleting model 'DashboardWidgetSettings' db.delete_table(u'dashboard_app_dashboardwidgetsettings')
Example #4
Source File: 0002_auto__add_field_userinfo_global_unique_id.py From builder with GNU Affero General Public License v3.0 | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'UserInfo', fields ['global_unique_id'] db.delete_unique(u'main_userinfo', ['global_unique_id']) # Deleting field 'UserInfo.global_unique_id' db.delete_column(u'main_userinfo', 'global_unique_id')
Example #5
Source File: 0002_auto__add_field_userinfo_global_unique_id.py From builder with GNU Affero General Public License v3.0 | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'UserInfo', fields ['global_unique_id'] db.delete_unique(u'main_userinfo', ['global_unique_id']) # Deleting field 'UserInfo.global_unique_id' db.delete_column(u'main_userinfo', 'global_unique_id')
Example #6
Source File: 0002_auto__del_unique_transaction_hash.py From ripple_api with BSD 3-Clause "New" or "Revised" License | 5 votes |
def forwards(self, orm): # Removing unique constraint on 'Transaction', fields ['hash'] db.delete_unique('ripple_api_transaction', ['hash'])
Example #7
Source File: 0066_auto__chg_field_bestof_comment__add_unique_bestof_comment.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'BestOf', fields ['comment'] db.delete_unique('canvas_bestof', ['comment_id']) # Changing field 'BestOf.comment' db.alter_column('canvas_bestof', 'comment_id', self.gf('django.db.models.fields.related.ForeignKey')(null=True, to=orm['canvas.Comment']))
Example #8
Source File: 0077_auto__add_field_bestof_category__del_unique_bestof.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def forwards(self, orm): # Removing unique constraint on 'BestOf', fields ['comment'] db.delete_unique('canvas_bestof', ['comment_id']) # Adding field 'BestOf.category' db.add_column('canvas_bestof', 'category', self.gf('django.db.models.fields.related.ForeignKey')(default=None, related_name='best_of', null=True, blank=True, to=orm['canvas.Category']), keep_default=False)
Example #9
Source File: 0140_auto__add_unique_welcomeemailrecipient_recipient.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'WelcomeEmailRecipient', fields ['recipient'] db.delete_unique('canvas_welcomeemailrecipient', ['recipient_id'])
Example #10
Source File: 0001_initial.py From django-userena-ce with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MessageContact', fields ['um_from_user', 'um_to_user'] db.delete_unique( "umessages_messagecontact", ["um_from_user_id", "um_to_user_id"] ) # Deleting model 'MessageContact' db.delete_table("umessages_messagecontact") # Deleting model 'MessageRecipient' db.delete_table("umessages_messagerecipient") # Deleting model 'Message' db.delete_table("umessages_message")
Example #11
Source File: 0130_auto__add_unique_apiauthtoken_app_user.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'APIAuthToken', fields ['app', 'user'] db.delete_unique('canvas_apiauthtoken', ['app_id', 'user_id'])
Example #12
Source File: 0004_auto__add_unique_emailconfirmation_user.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'EmailConfirmation', fields ['user'] db.delete_unique('user_settings_emailconfirmation', ['user_id'])
Example #13
Source File: 0003_auto__add_unique_emailconfirmation_confirmation_key.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'EmailConfirmation', fields ['confirmation_key'] db.delete_unique('user_settings_emailconfirmation', ['confirmation_key'])
Example #14
Source File: 0005_auto__add_unique_activity_key_activity_type.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Activity', fields ['key', 'activity_type'] db.delete_unique('activity_activity', ['key', 'activity_type'])
Example #15
Source File: 0002_auto__add_unstar__add_unique_unstar_comment_user.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Unstar', fields ['comment', 'user'] db.delete_unique('stars_unstar', ['comment_id', 'user_id']) # Deleting model 'Unstar' db.delete_table('stars_unstar')
Example #16
Source File: 0003_auto__add_unique_playback_comment_viewer.py From canvas with BSD 3-Clause "New" or "Revised" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Playback', fields ['comment', 'viewer'] db.delete_unique('playback_playback', ['comment_id', 'viewer_id'])
Example #17
Source File: 0001_initial.py From django-email-confirm-la with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'EmailConfirmation', fields ['content_type', 'object_id', 'email_field_name'] db.delete_unique('email_confirm_la_emailconfirmation', ['content_type_id', 'object_id', 'email_field_name']) # Deleting model 'EmailConfirmation' db.delete_table('email_confirm_la_emailconfirmation')
Example #18
Source File: 0023_auto__add_unique_surveytype_slug.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'SurveyType', fields ['slug'] db.delete_unique('odk_logger_surveytype', ['slug'])
Example #19
Source File: 0007_auto__add_unique_mysecondmodel_name.py From django_migration_testcase with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MySecondModel', fields ['name'] db.delete_unique('test_app_mysecondmodel', ['name'])
Example #20
Source File: 0007_auto__add_unique_mysecondmodel_name.py From django_migration_testcase with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MySecondModel', fields ['name'] db.delete_unique('test_app_mysecondmodel', ['name'])
Example #21
Source File: 0007_auto__add_unique_mysecondmodel_name.py From django_migration_testcase with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MySecondModel', fields ['name'] db.delete_unique('test_app_mysecondmodel', ['name'])
Example #22
Source File: 0007_auto__add_unique_mysecondmodel_name.py From django_migration_testcase with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MySecondModel', fields ['name'] db.delete_unique('test_app_mysecondmodel', ['name'])
Example #23
Source File: 0012_auto__add_unique_metadata_xform_data_type_data_value.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MetaData', fields ['xform', 'data_type', 'data_value'] db.delete_unique(u'main_metadata', ['xform_id', 'data_type', 'data_value'])
Example #24
Source File: 0003_auto__add_projectxform__add_unique_projectxform_xform_project.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'ProjectXForm', fields ['xform', 'project'] db.delete_unique('api_projectxform', ['xform_id', 'project_id']) # Deleting model 'ProjectXForm' db.delete_table('api_projectxform')
Example #25
Source File: 0002_auto__add_project__add_unique_project_name_organization.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Project', fields ['name', 'organization'] db.delete_unique('api_project', ['name', 'organization_id']) # Deleting model 'Project' db.delete_table('api_project') # Removing M2M table for field projects on 'Team' db.delete_table('api_team_projects')
Example #26
Source File: 0026_auto__chg_field_xform_sms_id_string__add_unique_xform_sms_id_string_us.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'XForm', fields ['sms_id_string', 'user'] db.delete_unique('odk_logger_xform', ['sms_id_string', 'user_id']) # Changing field 'XForm.sms_id_string' db.alter_column('odk_logger_xform', 'sms_id_string', self.gf('django.db.models.fields.SlugField')(max_length=50, null=True))
Example #27
Source File: 0007_auto__add_unique_mysecondmodel_name.py From django_migration_testcase with MIT License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'MySecondModel', fields ['name'] db.delete_unique('test_app_mysecondmodel', ['name'])
Example #28
Source File: 0002_auto__del_unique_xform_id_string__add_unique_xform_id_string_user.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'XForm', fields ['id_string', 'user'] db.delete_unique('odk_logger_xform', ['id_string', 'user_id']) # Adding unique constraint on 'XForm', fields ['id_string'] db.create_unique('odk_logger_xform', ['id_string'])
Example #29
Source File: 0002_auto__add_unique_restservice_service_url_name_xform.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'RestService', fields ['service_url', 'name', 'xform'] db.delete_unique('restservice_restservice', ['service_url', 'name', 'xform_id'])
Example #30
Source File: 0013_auto__add_unique_export_filename_xform.py From kobo-predict with BSD 2-Clause "Simplified" License | 5 votes |
def backwards(self, orm): # Removing unique constraint on 'Export', fields ['filename', 'xform'] db.delete_unique('odk_viewer_export', ['filename', 'xform_id'])