当前位置: 首页>>代码示例>>Python>>正文


Python db.delete_column方法代码示例

本文整理汇总了Python中south.db.db.delete_column方法的典型用法代码示例。如果您正苦于以下问题:Python db.delete_column方法的具体用法?Python db.delete_column怎么用?Python db.delete_column使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在south.db.db的用法示例。


在下文中一共展示了db.delete_column方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
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') 
开发者ID:crowdata,项目名称:crowdata,代码行数:14,代码来源:0028_auto__add_organization__add_field_documentsetformentry_organization__a.py

示例2: forwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def forwards(self, orm):
        # Adding field 'Document.verified'
        db.add_column(u'crowdataapp_document', 'verified',
                      self.gf('django.db.models.fields.BooleanField')(default=False),
                      keep_default=False)

        # Deleting field 'DocumentSetFieldEntry.valid'
        db.delete_column(u'crowdataapp_documentsetfieldentry', 'valid')

        # Adding field 'DocumentSetFieldEntry.verified'
        db.add_column(u'crowdataapp_documentsetfieldentry', 'verified',
                      self.gf('django.db.models.fields.BooleanField')(default=False),
                      keep_default=False) 
开发者ID:crowdata,项目名称:crowdata,代码行数:15,代码来源:0017_auto__add_field_document_verified__del_field_documentsetfieldentry_val.py

示例3: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'Document.verified'
        db.delete_column(u'crowdataapp_document', 'verified')

        # Adding field 'DocumentSetFieldEntry.valid'
        db.add_column(u'crowdataapp_documentsetfieldentry', 'valid',
                      self.gf('django.db.models.fields.BooleanField')(default=False),
                      keep_default=False)

        # Deleting field 'DocumentSetFieldEntry.verified'
        db.delete_column(u'crowdataapp_documentsetfieldentry', 'verified') 
开发者ID:crowdata,项目名称:crowdata,代码行数:13,代码来源:0017_auto__add_field_document_verified__del_field_documentsetfieldentry_val.py

示例4: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'DocumentSet.tosum_field'
        db.delete_column(u'crowdataapp_documentset', 'tosum_field_id') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0027_auto__add_field_documentset_tosum_field.py

示例5: forwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def forwards(self, orm):
        # Deleting field 'Document.stored_validity_rate'
        db.delete_column(u'crowdataapp_document', 'stored_validity_rate')

        # Adding field 'Document.entries_threshold_override'
        db.add_column(u'crowdataapp_document', 'entries_threshold_override',
                      self.gf('django.db.models.fields.IntegerField')(null=True),
                      keep_default=False) 
开发者ID:crowdata,项目名称:crowdata,代码行数:10,代码来源:0015_auto__del_field_document_stored_validity_rate__add_field_document_entr.py

示例6: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'Organization.slug'
        db.delete_column(u'crowdataapp_organization', 'slug') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0030_auto__add_field_organization_slug.py

示例7: forwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def forwards(self, orm):
        # Deleting field 'DocumentSetRankingDefinition.field'
        db.delete_column(u'crowdataapp_documentsetrankingdefinition', 'field_id')

        # Adding field 'DocumentSetRankingDefinition.label_field'
        db.add_column(u'crowdataapp_documentsetrankingdefinition', 'label_field',
                      self.gf('django.db.models.fields.related.ForeignKey')(default=1, related_name='label_fields', to=orm['crowdataapp.DocumentSetFormField']),
                      keep_default=False)

        # Adding field 'DocumentSetRankingDefinition.magnitude_field'
        db.add_column(u'crowdataapp_documentsetrankingdefinition', 'magnitude_field',
                      self.gf('django.db.models.fields.related.ForeignKey')(default=1, related_name='magnitude_fields', to=orm['crowdataapp.DocumentSetFormField']),
                      keep_default=False) 
开发者ID:crowdata,项目名称:crowdata,代码行数:15,代码来源:0012_auto__del_field_documentsetrankingdefinition_field__add_field_document.py

示例8: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Adding field 'DocumentSetRankingDefinition.field'
        db.add_column(u'crowdataapp_documentsetrankingdefinition', 'field',
                      self.gf('django.db.models.fields.related.ForeignKey')(default=1, related_name='fields', to=orm['crowdataapp.DocumentSetFormField']),
                      keep_default=False)

        # Deleting field 'DocumentSetRankingDefinition.label_field'
        db.delete_column(u'crowdataapp_documentsetrankingdefinition', 'label_field_id')

        # Deleting field 'DocumentSetRankingDefinition.magnitude_field'
        db.delete_column(u'crowdataapp_documentsetrankingdefinition', 'magnitude_field_id') 
开发者ID:crowdata,项目名称:crowdata,代码行数:13,代码来源:0012_auto__del_field_documentsetrankingdefinition_field__add_field_document.py

示例9: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'DocumentSetRankingDefinition.amount_rows_on_home'
        db.delete_column(u'crowdataapp_documentsetrankingdefinition', 'amount_rows_on_home') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0021_auto__add_field_documentsetrankingdefinition_amount_rows_on_home__add_.py

示例10: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting model 'CanonicalFieldEntryLabel'
        db.delete_table(u'crowdataapp_canonicalfieldentrylabel')

        # Deleting field 'DocumentSetFieldEntry.canonical_label'
        db.delete_column(u'crowdataapp_documentsetfieldentry', 'canonical_label_id') 
开发者ID:crowdata,项目名称:crowdata,代码行数:8,代码来源:0022_auto__add_canonicalfieldentrylabel__add_field_documentsetfieldentry_ca.py

示例11: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'DocumentSet.head_html'
        db.delete_column(u'crowdataapp_documentset', 'head_html') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0005_auto__add_field_documentset_head_html.py

示例12: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'DocumentSet.header_image'
        db.delete_column(u'crowdataapp_documentset', 'header_image') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0020_auto__add_field_documentset_header_image.py

示例13: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Adding model 'DocumentUserFormEntry'
        db.create_table(u'crowdataapp_documentuserformentry', (
            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
            ('user', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['auth.User'], null=True)),
            ('document', self.gf('django.db.models.fields.related.ForeignKey')(related_name='entries', to=orm['crowdataapp.Document'])),
            ('form_entry', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['forms.FormEntry'])),
        ))
        db.send_create_signal(u'crowdataapp', ['DocumentUserFormEntry'])

        # Deleting field 'DocumentSetFormEntry.document'
        db.delete_column(u'crowdataapp_documentsetformentry', 'document_id')

        # Deleting field 'DocumentSetFormEntry.user'
        db.delete_column(u'crowdataapp_documentsetformentry', 'user_id') 
开发者ID:crowdata,项目名称:crowdata,代码行数:17,代码来源:0003_auto__del_documentuserformentry__add_field_documentsetformentry_docume.py

示例14: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'DocumentSetFieldEntry.created_at'
        db.delete_column(u'crowdataapp_documentsetfieldentry', 'created_at')

        # Deleting field 'DocumentSetFieldEntry.updated_at'
        db.delete_column(u'crowdataapp_documentsetfieldentry', 'updated_at') 
开发者ID:crowdata,项目名称:crowdata,代码行数:8,代码来源:0024_auto__add_field_documentsetfieldentry_created_at__add_field_documentse.py

示例15: backwards

# 需要导入模块: from south.db import db [as 别名]
# 或者: from south.db.db import delete_column [as 别名]
def backwards(self, orm):
        # Deleting field 'CanonicalFieldEntryLabel.document_set'
        db.delete_column(u'crowdataapp_canonicalfieldentrylabel', 'document_set_id') 
开发者ID:crowdata,项目名称:crowdata,代码行数:5,代码来源:0023_auto__add_field_canonicalfieldentrylabel_document_set.py


注:本文中的south.db.db.delete_column方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。