diff options
Diffstat (limited to 'ishtar_common/migrations/0001_initial.py')
-rw-r--r-- | ishtar_common/migrations/0001_initial.py | 649 |
1 files changed, 565 insertions, 84 deletions
diff --git a/ishtar_common/migrations/0001_initial.py b/ishtar_common/migrations/0001_initial.py index fc22881bc..5cb79d04f 100644 --- a/ishtar_common/migrations/0001_initial.py +++ b/ishtar_common/migrations/0001_initial.py @@ -8,28 +8,49 @@ from django.db import models class Migration(SchemaMigration): def forwards(self, orm): - # Adding model 'Wizard' - db.create_table('ishtar_common_wizard', ( + # Adding model 'ItemKey' + db.create_table('ishtar_common_itemkey', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), - ('url_name', self.gf('django.db.models.fields.CharField')(unique=True, max_length=128)), + ('key', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('content_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['contenttypes.ContentType'])), + ('object_id', self.gf('django.db.models.fields.PositiveIntegerField')()), + ('importer', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Import'], null=True, blank=True)), )) - db.send_create_signal('ishtar_common', ['Wizard']) + db.send_create_signal('ishtar_common', ['ItemKey']) - # Adding model 'WizardStep' - db.create_table('ishtar_common_wizardstep', ( + # Adding model 'GlobalVar' + db.create_table('ishtar_common_globalvar', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), - ('order', self.gf('django.db.models.fields.IntegerField')()), - ('wizard', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Wizard'])), - ('url_name', self.gf('django.db.models.fields.CharField')(max_length=128)), - ('name', self.gf('django.db.models.fields.CharField')(max_length=128)), + ('slug', self.gf('django.db.models.fields.SlugField')(unique=True, max_length=50)), + ('description', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('value', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), )) - db.send_create_signal('ishtar_common', ['WizardStep']) + db.send_create_signal('ishtar_common', ['GlobalVar']) + + # Adding model 'DocumentTemplate' + db.create_table('ishtar_common_documenttemplate', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('template', self.gf('django.db.models.fields.files.FileField')(max_length=100)), + ('associated_object_name', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), + )) + db.send_create_signal('ishtar_common', ['DocumentTemplate']) + + # Adding model 'State' + db.create_table('ishtar_common_state', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('label', self.gf('django.db.models.fields.CharField')(max_length=30)), + ('number', self.gf('django.db.models.fields.CharField')(unique=True, max_length=3)), + )) + db.send_create_signal('ishtar_common', ['State']) # Adding model 'Department' db.create_table('ishtar_common_department', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('label', self.gf('django.db.models.fields.CharField')(max_length=30)), ('number', self.gf('django.db.models.fields.CharField')(unique=True, max_length=3)), + ('state', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.State'], null=True, blank=True)), )) db.send_create_signal('ishtar_common', ['Department']) @@ -37,24 +58,159 @@ class Migration(SchemaMigration): db.create_table('ishtar_common_organizationtype', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), - ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=30)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), - ('available', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), )) db.send_create_signal('ishtar_common', ['OrganizationType']) + # Adding model 'ImporterType' + db.create_table('ishtar_common_importertype', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)), + ('slug', self.gf('django.db.models.fields.SlugField')(max_length=100, unique=True, null=True, blank=True)), + ('description', self.gf('django.db.models.fields.CharField')(max_length=500, null=True, blank=True)), + ('associated_models', self.gf('django.db.models.fields.CharField')(max_length=200)), + ('is_template', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('unicity_keys', self.gf('django.db.models.fields.CharField')(max_length=500, null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['ImporterType']) + + # Adding M2M table for field users on 'ImporterType' + db.create_table('ishtar_common_importertype_users', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('importertype', models.ForeignKey(orm['ishtar_common.importertype'], null=False)), + ('ishtaruser', models.ForeignKey(orm['ishtar_common.ishtaruser'], null=False)) + )) + db.create_unique('ishtar_common_importertype_users', ['importertype_id', 'ishtaruser_id']) + + # Adding model 'ImporterDefault' + db.create_table('ishtar_common_importerdefault', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('importer_type', self.gf('django.db.models.fields.related.ForeignKey')(related_name='defaults', to=orm['ishtar_common.ImporterType'])), + ('target', self.gf('django.db.models.fields.CharField')(max_length=500)), + )) + db.send_create_signal('ishtar_common', ['ImporterDefault']) + + # Adding model 'ImporterDefaultValues' + db.create_table('ishtar_common_importerdefaultvalues', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('default_target', self.gf('django.db.models.fields.related.ForeignKey')(related_name='default_values', to=orm['ishtar_common.ImporterDefault'])), + ('target', self.gf('django.db.models.fields.CharField')(max_length=500)), + ('value', self.gf('django.db.models.fields.CharField')(max_length=500)), + )) + db.send_create_signal('ishtar_common', ['ImporterDefaultValues']) + + # Adding model 'ImporterColumn' + db.create_table('ishtar_common_importercolumn', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('importer_type', self.gf('django.db.models.fields.related.ForeignKey')(related_name='columns', to=orm['ishtar_common.ImporterType'])), + ('col_number', self.gf('django.db.models.fields.IntegerField')(default=1)), + ('description', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('regexp_pre_filter', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Regexp'], null=True, blank=True)), + ('required', self.gf('django.db.models.fields.BooleanField')(default=False)), + )) + db.send_create_signal('ishtar_common', ['ImporterColumn']) + + # Adding unique constraint on 'ImporterColumn', fields ['importer_type', 'col_number'] + db.create_unique('ishtar_common_importercolumn', ['importer_type_id', 'col_number']) + + # Adding model 'ImporterDuplicateField' + db.create_table('ishtar_common_importerduplicatefield', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('column', self.gf('django.db.models.fields.related.ForeignKey')(related_name='duplicate_fields', to=orm['ishtar_common.ImporterColumn'])), + ('field_name', self.gf('django.db.models.fields.CharField')(max_length=200, null=True, blank=True)), + ('force_new', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('concat', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('concat_str', self.gf('django.db.models.fields.CharField')(max_length=5, null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['ImporterDuplicateField']) + + # Adding model 'Regexp' + db.create_table('ishtar_common_regexp', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('description', self.gf('django.db.models.fields.CharField')(max_length=500, null=True, blank=True)), + ('regexp', self.gf('django.db.models.fields.CharField')(max_length=500)), + )) + db.send_create_signal('ishtar_common', ['Regexp']) + + # Adding model 'ImportTarget' + db.create_table('ishtar_common_importtarget', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('column', self.gf('django.db.models.fields.related.ForeignKey')(related_name='targets', to=orm['ishtar_common.ImporterColumn'])), + ('target', self.gf('django.db.models.fields.CharField')(max_length=500)), + ('regexp_filter', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Regexp'], null=True, blank=True)), + ('formater_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.FormaterType'])), + ('force_new', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('concat', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('concat_str', self.gf('django.db.models.fields.CharField')(max_length=5, null=True, blank=True)), + ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['ImportTarget']) + + # Adding model 'TargetKey' + db.create_table('ishtar_common_targetkey', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('target', self.gf('django.db.models.fields.related.ForeignKey')(related_name='keys', to=orm['ishtar_common.ImportTarget'])), + ('key', self.gf('django.db.models.fields.TextField')()), + ('value', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('is_set', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('associated_import', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Import'], null=True, blank=True)), + ('associated_user', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.IshtarUser'], null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['TargetKey']) + + # Adding unique constraint on 'TargetKey', fields ['target', 'key', 'associated_user', 'associated_import'] + db.create_unique('ishtar_common_targetkey', ['target_id', 'key', 'associated_user_id', 'associated_import_id']) + + # Adding model 'FormaterType' + db.create_table('ishtar_common_formatertype', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('formater_type', self.gf('django.db.models.fields.CharField')(max_length=20)), + ('options', self.gf('django.db.models.fields.CharField')(max_length=500, null=True, blank=True)), + ('many_split', self.gf('django.db.models.fields.CharField')(max_length=10, null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['FormaterType']) + + # Adding unique constraint on 'FormaterType', fields ['formater_type', 'options', 'many_split'] + db.create_unique('ishtar_common_formatertype', ['formater_type', 'options', 'many_split']) + + # Adding model 'Import' + db.create_table('ishtar_common_import', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('user', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.IshtarUser'])), + ('importer_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.ImporterType'])), + ('imported_file', self.gf('django.db.models.fields.files.FileField')(max_length=100)), + ('imported_images', self.gf('django.db.models.fields.files.FileField')(max_length=100, null=True, blank=True)), + ('encoding', self.gf('django.db.models.fields.CharField')(default='utf-8', max_length=15)), + ('skip_lines', self.gf('django.db.models.fields.IntegerField')(default=1)), + ('error_file', self.gf('django.db.models.fields.files.FileField')(max_length=100, null=True, blank=True)), + ('result_file', self.gf('django.db.models.fields.files.FileField')(max_length=100, null=True, blank=True)), + ('match_file', self.gf('django.db.models.fields.files.FileField')(max_length=100, null=True, blank=True)), + ('state', self.gf('django.db.models.fields.CharField')(default='C', max_length=2)), + ('conservative_import', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('creation_date', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True, null=True, blank=True)), + ('end_date', self.gf('django.db.models.fields.DateTimeField')(null=True, blank=True)), + ('seconds_remaining', self.gf('django.db.models.fields.IntegerField')(null=True, blank=True)), + )) + db.send_create_signal('ishtar_common', ['Import']) + # Adding model 'HistoricalOrganization' db.create_table('ishtar_common_historicalorganization', ( ('id', self.gf('django.db.models.fields.IntegerField')(db_index=True, blank=True)), ('history_modifier_id', self.gf('django.db.models.fields.IntegerField')(db_index=True, null=True, blank=True)), + ('history_creator_id', self.gf('django.db.models.fields.IntegerField')(db_index=True, null=True, blank=True)), ('address', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('address_complement', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('postal_code', self.gf('django.db.models.fields.CharField')(max_length=10, null=True, blank=True)), - ('town', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), + ('town', self.gf('django.db.models.fields.CharField')(max_length=70, null=True, blank=True)), ('country', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), ('phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), ('mobile_phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), - ('name', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('email', self.gf('django.db.models.fields.EmailField')(max_length=75, null=True, blank=True)), + ('merge_key', self.gf('django.db.models.fields.CharField')(max_length=300, null=True, blank=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=300)), ('organization_type_id', self.gf('django.db.models.fields.IntegerField')(db_index=True, null=True, blank=True)), ('history_id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('history_date', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True, blank=True)), @@ -66,61 +222,122 @@ class Migration(SchemaMigration): # Adding model 'Organization' db.create_table('ishtar_common_organization', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), - ('history_modifier', self.gf('django.db.models.fields.related.ForeignKey')(related_name='+', to=orm['auth.User'])), + ('history_modifier', self.gf('django.db.models.fields.related.ForeignKey')(blank=True, related_name='+', null=True, on_delete=models.SET_NULL, to=orm['auth.User'])), + ('history_creator', self.gf('django.db.models.fields.related.ForeignKey')(blank=True, related_name='+', null=True, on_delete=models.SET_NULL, to=orm['auth.User'])), ('address', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('address_complement', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('postal_code', self.gf('django.db.models.fields.CharField')(max_length=10, null=True, blank=True)), - ('town', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), + ('town', self.gf('django.db.models.fields.CharField')(max_length=70, null=True, blank=True)), ('country', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), ('phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), ('mobile_phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), - ('name', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('email', self.gf('django.db.models.fields.EmailField')(max_length=75, null=True, blank=True)), + ('merge_key', self.gf('django.db.models.fields.CharField')(max_length=300, null=True, blank=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=300)), ('organization_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.OrganizationType'])), )) db.send_create_signal('ishtar_common', ['Organization']) + # Adding M2M table for field imports on 'Organization' + db.create_table('ishtar_common_organization_imports', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('organization', models.ForeignKey(orm['ishtar_common.organization'], null=False)), + ('import', models.ForeignKey(orm['ishtar_common.import'], null=False)) + )) + db.create_unique('ishtar_common_organization_imports', ['organization_id', 'import_id']) + + # Adding M2M table for field merge_candidate on 'Organization' + db.create_table('ishtar_common_organization_merge_candidate', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('from_organization', models.ForeignKey(orm['ishtar_common.organization'], null=False)), + ('to_organization', models.ForeignKey(orm['ishtar_common.organization'], null=False)) + )) + db.create_unique('ishtar_common_organization_merge_candidate', ['from_organization_id', 'to_organization_id']) + + # Adding M2M table for field merge_exclusion on 'Organization' + db.create_table('ishtar_common_organization_merge_exclusion', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('from_organization', models.ForeignKey(orm['ishtar_common.organization'], null=False)), + ('to_organization', models.ForeignKey(orm['ishtar_common.organization'], null=False)) + )) + db.create_unique('ishtar_common_organization_merge_exclusion', ['from_organization_id', 'to_organization_id']) + # Adding model 'PersonType' db.create_table('ishtar_common_persontype', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), - ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=30)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), - ('available', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), )) db.send_create_signal('ishtar_common', ['PersonType']) - # Adding M2M table for field rights on 'PersonType' - db.create_table('ishtar_common_persontype_rights', ( + # Adding M2M table for field groups on 'PersonType' + db.create_table('ishtar_common_persontype_groups', ( ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), ('persontype', models.ForeignKey(orm['ishtar_common.persontype'], null=False)), - ('wizardstep', models.ForeignKey(orm['ishtar_common.wizardstep'], null=False)) + ('group', models.ForeignKey(orm['auth.group'], null=False)) )) - db.create_unique('ishtar_common_persontype_rights', ['persontype_id', 'wizardstep_id']) + db.create_unique('ishtar_common_persontype_groups', ['persontype_id', 'group_id']) # Adding model 'Person' db.create_table('ishtar_common_person', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), - ('history_modifier', self.gf('django.db.models.fields.related.ForeignKey')(related_name='+', to=orm['auth.User'])), + ('history_modifier', self.gf('django.db.models.fields.related.ForeignKey')(blank=True, related_name='+', null=True, on_delete=models.SET_NULL, to=orm['auth.User'])), + ('history_creator', self.gf('django.db.models.fields.related.ForeignKey')(blank=True, related_name='+', null=True, on_delete=models.SET_NULL, to=orm['auth.User'])), ('address', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('address_complement', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), ('postal_code', self.gf('django.db.models.fields.CharField')(max_length=10, null=True, blank=True)), - ('town', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), + ('town', self.gf('django.db.models.fields.CharField')(max_length=70, null=True, blank=True)), ('country', self.gf('django.db.models.fields.CharField')(max_length=30, null=True, blank=True)), ('phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), ('mobile_phone', self.gf('django.db.models.fields.CharField')(max_length=18, null=True, blank=True)), - ('title', self.gf('django.db.models.fields.CharField')(max_length=2)), - ('surname', self.gf('django.db.models.fields.CharField')(max_length=20)), - ('name', self.gf('django.db.models.fields.CharField')(max_length=30)), - ('email', self.gf('django.db.models.fields.CharField')(max_length=40, null=True, blank=True)), - ('person_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.PersonType'])), - ('attached_to', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Organization'], null=True, blank=True)), + ('email', self.gf('django.db.models.fields.EmailField')(max_length=75, null=True, blank=True)), + ('merge_key', self.gf('django.db.models.fields.CharField')(max_length=300, null=True, blank=True)), + ('title', self.gf('django.db.models.fields.CharField')(max_length=100, null=True, blank=True)), + ('surname', self.gf('django.db.models.fields.CharField')(max_length=50, null=True, blank=True)), + ('name', self.gf('django.db.models.fields.CharField')(max_length=200, null=True, blank=True)), + ('raw_name', self.gf('django.db.models.fields.CharField')(max_length=300, null=True, blank=True)), + ('attached_to', self.gf('django.db.models.fields.related.ForeignKey')(blank=True, related_name='members', null=True, on_delete=models.SET_NULL, to=orm['ishtar_common.Organization'])), )) db.send_create_signal('ishtar_common', ['Person']) + # Adding M2M table for field imports on 'Person' + db.create_table('ishtar_common_person_imports', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('person', models.ForeignKey(orm['ishtar_common.person'], null=False)), + ('import', models.ForeignKey(orm['ishtar_common.import'], null=False)) + )) + db.create_unique('ishtar_common_person_imports', ['person_id', 'import_id']) + + # Adding M2M table for field merge_candidate on 'Person' + db.create_table('ishtar_common_person_merge_candidate', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('from_person', models.ForeignKey(orm['ishtar_common.person'], null=False)), + ('to_person', models.ForeignKey(orm['ishtar_common.person'], null=False)) + )) + db.create_unique('ishtar_common_person_merge_candidate', ['from_person_id', 'to_person_id']) + + # Adding M2M table for field merge_exclusion on 'Person' + db.create_table('ishtar_common_person_merge_exclusion', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('from_person', models.ForeignKey(orm['ishtar_common.person'], null=False)), + ('to_person', models.ForeignKey(orm['ishtar_common.person'], null=False)) + )) + db.create_unique('ishtar_common_person_merge_exclusion', ['from_person_id', 'to_person_id']) + + # Adding M2M table for field person_types on 'Person' + db.create_table('ishtar_common_person_person_types', ( + ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)), + ('person', models.ForeignKey(orm['ishtar_common.person'], null=False)), + ('persontype', models.ForeignKey(orm['ishtar_common.persontype'], null=False)) + )) + db.create_unique('ishtar_common_person_person_types', ['person_id', 'persontype_id']) + # Adding model 'IshtarUser' db.create_table('ishtar_common_ishtaruser', ( ('user_ptr', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['auth.User'], unique=True, primary_key=True)), - ('person', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Person'], unique=True)), + ('person', self.gf('django.db.models.fields.related.ForeignKey')(related_name='ishtaruser', unique=True, to=orm['ishtar_common.Person'])), )) db.send_create_signal('ishtar_common', ['IshtarUser']) @@ -128,16 +345,16 @@ class Migration(SchemaMigration): db.create_table('ishtar_common_authortype', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), - ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=30)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), - ('available', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), )) db.send_create_signal('ishtar_common', ['AuthorType']) # Adding model 'Author' db.create_table('ishtar_common_author', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), - ('person', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.Person'])), + ('person', self.gf('django.db.models.fields.related.ForeignKey')(related_name='author', to=orm['ishtar_common.Person'])), ('author_type', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ishtar_common.AuthorType'])), )) db.send_create_signal('ishtar_common', ['Author']) @@ -146,12 +363,32 @@ class Migration(SchemaMigration): db.create_table('ishtar_common_sourcetype', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), - ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=30)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), - ('available', self.gf('django.db.models.fields.BooleanField')(default=False)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), )) db.send_create_signal('ishtar_common', ['SourceType']) + # Adding model 'SupportType' + db.create_table('ishtar_common_supporttype', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), + ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), + )) + db.send_create_signal('ishtar_common', ['SupportType']) + + # Adding model 'Format' + db.create_table('ishtar_common_format', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), + ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), + )) + db.send_create_signal('ishtar_common', ['Format']) + # Adding model 'Arrondissement' db.create_table('ishtar_common_arrondissement', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), @@ -180,13 +417,40 @@ class Migration(SchemaMigration): )) db.send_create_signal('ishtar_common', ['Town']) + # Adding model 'OperationType' + db.create_table('ishtar_common_operationtype', ( + ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), + ('label', self.gf('django.db.models.fields.CharField')(max_length=100)), + ('txt_idx', self.gf('django.db.models.fields.CharField')(unique=True, max_length=100)), + ('comment', self.gf('django.db.models.fields.TextField')(null=True, blank=True)), + ('available', self.gf('django.db.models.fields.BooleanField')(default=True)), + ('order', self.gf('django.db.models.fields.IntegerField')(default=1)), + ('preventive', self.gf('django.db.models.fields.BooleanField')(default=True)), + )) + db.send_create_signal('ishtar_common', ['OperationType']) + def backwards(self, orm): - # Deleting model 'Wizard' - db.delete_table('ishtar_common_wizard') + # Removing unique constraint on 'FormaterType', fields ['formater_type', 'options', 'many_split'] + db.delete_unique('ishtar_common_formatertype', ['formater_type', 'options', 'many_split']) + + # Removing unique constraint on 'TargetKey', fields ['target', 'key', 'associated_user', 'associated_import'] + db.delete_unique('ishtar_common_targetkey', ['target_id', 'key', 'associated_user_id', 'associated_import_id']) + + # Removing unique constraint on 'ImporterColumn', fields ['importer_type', 'col_number'] + db.delete_unique('ishtar_common_importercolumn', ['importer_type_id', 'col_number']) - # Deleting model 'WizardStep' - db.delete_table('ishtar_common_wizardstep') + # Deleting model 'ItemKey' + db.delete_table('ishtar_common_itemkey') + + # Deleting model 'GlobalVar' + db.delete_table('ishtar_common_globalvar') + + # Deleting model 'DocumentTemplate' + db.delete_table('ishtar_common_documenttemplate') + + # Deleting model 'State' + db.delete_table('ishtar_common_state') # Deleting model 'Department' db.delete_table('ishtar_common_department') @@ -194,21 +458,75 @@ class Migration(SchemaMigration): # Deleting model 'OrganizationType' db.delete_table('ishtar_common_organizationtype') + # Deleting model 'ImporterType' + db.delete_table('ishtar_common_importertype') + + # Removing M2M table for field users on 'ImporterType' + db.delete_table('ishtar_common_importertype_users') + + # Deleting model 'ImporterDefault' + db.delete_table('ishtar_common_importerdefault') + + # Deleting model 'ImporterDefaultValues' + db.delete_table('ishtar_common_importerdefaultvalues') + + # Deleting model 'ImporterColumn' + db.delete_table('ishtar_common_importercolumn') + + # Deleting model 'ImporterDuplicateField' + db.delete_table('ishtar_common_importerduplicatefield') + + # Deleting model 'Regexp' + db.delete_table('ishtar_common_regexp') + + # Deleting model 'ImportTarget' + db.delete_table('ishtar_common_importtarget') + + # Deleting model 'TargetKey' + db.delete_table('ishtar_common_targetkey') + + # Deleting model 'FormaterType' + db.delete_table('ishtar_common_formatertype') + + # Deleting model 'Import' + db.delete_table('ishtar_common_import') + # Deleting model 'HistoricalOrganization' db.delete_table('ishtar_common_historicalorganization') # Deleting model 'Organization' db.delete_table('ishtar_common_organization') + # Removing M2M table for field imports on 'Organization' + db.delete_table('ishtar_common_organization_imports') + + # Removing M2M table for field merge_candidate on 'Organization' + db.delete_table('ishtar_common_organization_merge_candidate') + + # Removing M2M table for field merge_exclusion on 'Organization' + db.delete_table('ishtar_common_organization_merge_exclusion') + # Deleting model 'PersonType' db.delete_table('ishtar_common_persontype') - # Removing M2M table for field rights on 'PersonType' - db.delete_table('ishtar_common_persontype_rights') + # Removing M2M table for field groups on 'PersonType' + db.delete_table('ishtar_common_persontype_groups') # Deleting model 'Person' db.delete_table('ishtar_common_person') + # Removing M2M table for field imports on 'Person' + db.delete_table('ishtar_common_person_imports') + + # Removing M2M table for field merge_candidate on 'Person' + db.delete_table('ishtar_common_person_merge_candidate') + + # Removing M2M table for field merge_exclusion on 'Person' + db.delete_table('ishtar_common_person_merge_exclusion') + + # Removing M2M table for field person_types on 'Person' + db.delete_table('ishtar_common_person_person_types') + # Deleting model 'IshtarUser' db.delete_table('ishtar_common_ishtaruser') @@ -221,6 +539,12 @@ class Migration(SchemaMigration): # Deleting model 'SourceType' db.delete_table('ishtar_common_sourcetype') + # Deleting model 'SupportType' + db.delete_table('ishtar_common_supporttype') + + # Deleting model 'Format' + db.delete_table('ishtar_common_format') + # Deleting model 'Arrondissement' db.delete_table('ishtar_common_arrondissement') @@ -230,6 +554,9 @@ class Migration(SchemaMigration): # Deleting model 'Town' db.delete_table('ishtar_common_town') + # Deleting model 'OperationType' + db.delete_table('ishtar_common_operationtype') + models = { 'auth.group': { @@ -278,15 +605,15 @@ class Migration(SchemaMigration): 'Meta': {'object_name': 'Author'}, 'author_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.AuthorType']"}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'person': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Person']"}) + 'person': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'author'", 'to': "orm['ishtar_common.Person']"}) }, 'ishtar_common.authortype': { 'Meta': {'object_name': 'AuthorType'}, - 'available': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), - 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) }, 'ishtar_common.canton': { 'Meta': {'object_name': 'Canton'}, @@ -298,87 +625,254 @@ class Migration(SchemaMigration): 'Meta': {'ordering': "['number']", 'object_name': 'Department'}, 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'label': ('django.db.models.fields.CharField', [], {'max_length': '30'}), - 'number': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '3'}) + 'number': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '3'}), + 'state': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.State']", 'null': 'True', 'blank': 'True'}) + }, + 'ishtar_common.documenttemplate': { + 'Meta': {'ordering': "['associated_object_name', 'name']", 'object_name': 'DocumentTemplate'}, + 'associated_object_name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'template': ('django.db.models.fields.files.FileField', [], {'max_length': '100'}) + }, + 'ishtar_common.format': { + 'Meta': {'object_name': 'Format'}, + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), + 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) + }, + 'ishtar_common.formatertype': { + 'Meta': {'ordering': "('formater_type', 'options')", 'unique_together': "(('formater_type', 'options', 'many_split'),)", 'object_name': 'FormaterType'}, + 'formater_type': ('django.db.models.fields.CharField', [], {'max_length': '20'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'many_split': ('django.db.models.fields.CharField', [], {'max_length': '10', 'null': 'True', 'blank': 'True'}), + 'options': ('django.db.models.fields.CharField', [], {'max_length': '500', 'null': 'True', 'blank': 'True'}) + }, + 'ishtar_common.globalvar': { + 'Meta': {'ordering': "['slug']", 'object_name': 'GlobalVar'}, + 'description': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'slug': ('django.db.models.fields.SlugField', [], {'unique': 'True', 'max_length': '50'}), + 'value': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}) }, 'ishtar_common.historicalorganization': { 'Meta': {'ordering': "('-history_date', '-history_id')", 'object_name': 'HistoricalOrganization'}, 'address': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'address_complement': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'country': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}), + 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'null': 'True', 'blank': 'True'}), + 'history_creator_id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True', 'null': 'True', 'blank': 'True'}), 'history_date': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), 'history_id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'history_modifier_id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True', 'null': 'True', 'blank': 'True'}), 'history_type': ('django.db.models.fields.CharField', [], {'max_length': '1'}), 'history_user': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['auth.User']", 'null': 'True'}), 'id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True', 'blank': 'True'}), + 'merge_key': ('django.db.models.fields.CharField', [], {'max_length': '300', 'null': 'True', 'blank': 'True'}), 'mobile_phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), - 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '300'}), 'organization_type_id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True', 'null': 'True', 'blank': 'True'}), 'phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), 'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '10', 'null': 'True', 'blank': 'True'}), - 'town': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}) + 'town': ('django.db.models.fields.CharField', [], {'max_length': '70', 'null': 'True', 'blank': 'True'}) + }, + 'ishtar_common.import': { + 'Meta': {'object_name': 'Import'}, + 'conservative_import': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'creation_date': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'null': 'True', 'blank': 'True'}), + 'encoding': ('django.db.models.fields.CharField', [], {'default': "'utf-8'", 'max_length': '15'}), + 'end_date': ('django.db.models.fields.DateTimeField', [], {'null': 'True', 'blank': 'True'}), + 'error_file': ('django.db.models.fields.files.FileField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'imported_file': ('django.db.models.fields.files.FileField', [], {'max_length': '100'}), + 'imported_images': ('django.db.models.fields.files.FileField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'importer_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.ImporterType']"}), + 'match_file': ('django.db.models.fields.files.FileField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'result_file': ('django.db.models.fields.files.FileField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'seconds_remaining': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}), + 'skip_lines': ('django.db.models.fields.IntegerField', [], {'default': '1'}), + 'state': ('django.db.models.fields.CharField', [], {'default': "'C'", 'max_length': '2'}), + 'user': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.IshtarUser']"}) + }, + 'ishtar_common.importercolumn': { + 'Meta': {'ordering': "('importer_type', 'col_number')", 'unique_together': "(('importer_type', 'col_number'),)", 'object_name': 'ImporterColumn'}, + 'col_number': ('django.db.models.fields.IntegerField', [], {'default': '1'}), + 'description': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'importer_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'columns'", 'to': "orm['ishtar_common.ImporterType']"}), + 'regexp_pre_filter': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Regexp']", 'null': 'True', 'blank': 'True'}), + 'required': ('django.db.models.fields.BooleanField', [], {'default': 'False'}) + }, + 'ishtar_common.importerdefault': { + 'Meta': {'object_name': 'ImporterDefault'}, + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'importer_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'defaults'", 'to': "orm['ishtar_common.ImporterType']"}), + 'target': ('django.db.models.fields.CharField', [], {'max_length': '500'}) + }, + 'ishtar_common.importerdefaultvalues': { + 'Meta': {'object_name': 'ImporterDefaultValues'}, + 'default_target': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'default_values'", 'to': "orm['ishtar_common.ImporterDefault']"}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'target': ('django.db.models.fields.CharField', [], {'max_length': '500'}), + 'value': ('django.db.models.fields.CharField', [], {'max_length': '500'}) + }, + 'ishtar_common.importerduplicatefield': { + 'Meta': {'object_name': 'ImporterDuplicateField'}, + 'column': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'duplicate_fields'", 'to': "orm['ishtar_common.ImporterColumn']"}), + 'concat': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'concat_str': ('django.db.models.fields.CharField', [], {'max_length': '5', 'null': 'True', 'blank': 'True'}), + 'field_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'null': 'True', 'blank': 'True'}), + 'force_new': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}) + }, + 'ishtar_common.importertype': { + 'Meta': {'object_name': 'ImporterType'}, + 'associated_models': ('django.db.models.fields.CharField', [], {'max_length': '200'}), + 'description': ('django.db.models.fields.CharField', [], {'max_length': '500', 'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'is_template': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'slug': ('django.db.models.fields.SlugField', [], {'max_length': '100', 'unique': 'True', 'null': 'True', 'blank': 'True'}), + 'unicity_keys': ('django.db.models.fields.CharField', [], {'max_length': '500', 'null': 'True', 'blank': 'True'}), + 'users': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['ishtar_common.IshtarUser']", 'null': 'True', 'blank': 'True'}) + }, + 'ishtar_common.importtarget': { + 'Meta': {'object_name': 'ImportTarget'}, + 'column': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'targets'", 'to': "orm['ishtar_common.ImporterColumn']"}), + 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'concat': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'concat_str': ('django.db.models.fields.CharField', [], {'max_length': '5', 'null': 'True', 'blank': 'True'}), + 'force_new': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'formater_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.FormaterType']"}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'regexp_filter': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Regexp']", 'null': 'True', 'blank': 'True'}), + 'target': ('django.db.models.fields.CharField', [], {'max_length': '500'}) }, 'ishtar_common.ishtaruser': { 'Meta': {'object_name': 'IshtarUser', '_ormbases': ['auth.User']}, - 'person': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Person']", 'unique': 'True'}), + 'person': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ishtaruser'", 'unique': 'True', 'to': "orm['ishtar_common.Person']"}), 'user_ptr': ('django.db.models.fields.related.OneToOneField', [], {'to': "orm['auth.User']", 'unique': 'True', 'primary_key': 'True'}) }, + 'ishtar_common.itemkey': { + 'Meta': {'object_name': 'ItemKey'}, + 'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'importer': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Import']", 'null': 'True', 'blank': 'True'}), + 'key': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'object_id': ('django.db.models.fields.PositiveIntegerField', [], {}) + }, + 'ishtar_common.operationtype': { + 'Meta': {'ordering': "['-preventive', 'order', 'label']", 'object_name': 'OperationType'}, + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), + 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'order': ('django.db.models.fields.IntegerField', [], {'default': '1'}), + 'preventive': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) + }, 'ishtar_common.organization': { 'Meta': {'object_name': 'Organization'}, 'address': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'address_complement': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'country': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}), - 'history_modifier': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'+'", 'to': "orm['auth.User']"}), + 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'null': 'True', 'blank': 'True'}), + 'history_creator': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'+'", 'null': 'True', 'on_delete': 'models.SET_NULL', 'to': "orm['auth.User']"}), + 'history_modifier': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'+'", 'null': 'True', 'on_delete': 'models.SET_NULL', 'to': "orm['auth.User']"}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'imports': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'imported_ishtar_common_organization'", 'null': 'True', 'symmetrical': 'False', 'to': "orm['ishtar_common.Import']"}), + 'merge_candidate': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'merge_candidate_rel_+'", 'null': 'True', 'to': "orm['ishtar_common.Organization']"}), + 'merge_exclusion': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'merge_exclusion_rel_+'", 'null': 'True', 'to': "orm['ishtar_common.Organization']"}), + 'merge_key': ('django.db.models.fields.CharField', [], {'max_length': '300', 'null': 'True', 'blank': 'True'}), 'mobile_phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), - 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '300'}), 'organization_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.OrganizationType']"}), 'phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), 'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '10', 'null': 'True', 'blank': 'True'}), - 'town': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}) + 'town': ('django.db.models.fields.CharField', [], {'max_length': '70', 'null': 'True', 'blank': 'True'}) }, 'ishtar_common.organizationtype': { - 'Meta': {'object_name': 'OrganizationType'}, - 'available': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'Meta': {'ordering': "('label',)", 'object_name': 'OrganizationType'}, + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), - 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) }, 'ishtar_common.person': { 'Meta': {'object_name': 'Person'}, 'address': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'address_complement': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), - 'attached_to': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Organization']", 'null': 'True', 'blank': 'True'}), + 'attached_to': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'members'", 'null': 'True', 'on_delete': 'models.SET_NULL', 'to': "orm['ishtar_common.Organization']"}), 'country': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}), - 'email': ('django.db.models.fields.CharField', [], {'max_length': '40', 'null': 'True', 'blank': 'True'}), - 'history_modifier': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'+'", 'to': "orm['auth.User']"}), + 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'null': 'True', 'blank': 'True'}), + 'history_creator': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'+'", 'null': 'True', 'on_delete': 'models.SET_NULL', 'to': "orm['auth.User']"}), + 'history_modifier': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'+'", 'null': 'True', 'on_delete': 'models.SET_NULL', 'to': "orm['auth.User']"}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'imports': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'imported_ishtar_common_person'", 'null': 'True', 'symmetrical': 'False', 'to': "orm['ishtar_common.Import']"}), + 'merge_candidate': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'merge_candidate_rel_+'", 'null': 'True', 'to': "orm['ishtar_common.Person']"}), + 'merge_exclusion': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'merge_exclusion_rel_+'", 'null': 'True', 'to': "orm['ishtar_common.Person']"}), + 'merge_key': ('django.db.models.fields.CharField', [], {'max_length': '300', 'null': 'True', 'blank': 'True'}), 'mobile_phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), - 'name': ('django.db.models.fields.CharField', [], {'max_length': '30'}), - 'person_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.PersonType']"}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'null': 'True', 'blank': 'True'}), + 'person_types': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['ishtar_common.PersonType']", 'symmetrical': 'False'}), 'phone': ('django.db.models.fields.CharField', [], {'max_length': '18', 'null': 'True', 'blank': 'True'}), 'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '10', 'null': 'True', 'blank': 'True'}), - 'surname': ('django.db.models.fields.CharField', [], {'max_length': '20'}), - 'title': ('django.db.models.fields.CharField', [], {'max_length': '2'}), - 'town': ('django.db.models.fields.CharField', [], {'max_length': '30', 'null': 'True', 'blank': 'True'}) + 'raw_name': ('django.db.models.fields.CharField', [], {'max_length': '300', 'null': 'True', 'blank': 'True'}), + 'surname': ('django.db.models.fields.CharField', [], {'max_length': '50', 'null': 'True', 'blank': 'True'}), + 'title': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True', 'blank': 'True'}), + 'town': ('django.db.models.fields.CharField', [], {'max_length': '70', 'null': 'True', 'blank': 'True'}) }, 'ishtar_common.persontype': { - 'Meta': {'object_name': 'PersonType'}, - 'available': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'Meta': {'ordering': "('label',)", 'object_name': 'PersonType'}, + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['auth.Group']", 'null': 'True', 'blank': 'True'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), - 'rights': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['ishtar_common.WizardStep']", 'symmetrical': 'False'}), - 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) + }, + 'ishtar_common.regexp': { + 'Meta': {'object_name': 'Regexp'}, + 'description': ('django.db.models.fields.CharField', [], {'max_length': '500', 'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'regexp': ('django.db.models.fields.CharField', [], {'max_length': '500'}) }, 'ishtar_common.sourcetype': { 'Meta': {'object_name': 'SourceType'}, - 'available': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), + 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) + }, + 'ishtar_common.state': { + 'Meta': {'ordering': "['number']", 'object_name': 'State'}, + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'label': ('django.db.models.fields.CharField', [], {'max_length': '30'}), + 'number': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '3'}) + }, + 'ishtar_common.supporttype': { + 'Meta': {'object_name': 'SupportType'}, + 'available': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), 'comment': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), - 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) + 'txt_idx': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '100'}) + }, + 'ishtar_common.targetkey': { + 'Meta': {'unique_together': "(('target', 'key', 'associated_user', 'associated_import'),)", 'object_name': 'TargetKey'}, + 'associated_import': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Import']", 'null': 'True', 'blank': 'True'}), + 'associated_user': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.IshtarUser']", 'null': 'True', 'blank': 'True'}), + 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), + 'is_set': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), + 'key': ('django.db.models.fields.TextField', [], {}), + 'target': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'keys'", 'to': "orm['ishtar_common.ImportTarget']"}), + 'value': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}) }, 'ishtar_common.town': { 'Meta': {'ordering': "['numero_insee']", 'object_name': 'Town'}, @@ -389,19 +883,6 @@ class Migration(SchemaMigration): 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}), 'numero_insee': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '6'}), 'surface': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}) - }, - 'ishtar_common.wizard': { - 'Meta': {'ordering': "['url_name']", 'object_name': 'Wizard'}, - 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'url_name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '128'}) - }, - 'ishtar_common.wizardstep': { - 'Meta': {'ordering': "['wizard', 'order']", 'object_name': 'WizardStep'}, - 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), - 'name': ('django.db.models.fields.CharField', [], {'max_length': '128'}), - 'order': ('django.db.models.fields.IntegerField', [], {}), - 'url_name': ('django.db.models.fields.CharField', [], {'max_length': '128'}), - 'wizard': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['ishtar_common.Wizard']"}) } } |