More progress.
parent
4075f775e7
commit
67fb714ddb
@ -0,0 +1,29 @@
|
||||
# Generated by Django 3.0.3 on 2020-02-20 11:23
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('django_etesync', '0004_auto_20200220_1029'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitemchunk',
|
||||
name='items',
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='collectionitem',
|
||||
name='chunks',
|
||||
field=models.ManyToManyField(related_name='items', to='django_etesync.CollectionItemChunk'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='collectionitemchunk',
|
||||
name='collection',
|
||||
field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='chunks', to='django_etesync.Collection'),
|
||||
preserve_default=False,
|
||||
),
|
||||
]
|
@ -0,0 +1,49 @@
|
||||
# Generated by Django 3.0.3 on 2020-02-20 11:37
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('django_etesync', '0005_auto_20200220_1123'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitem',
|
||||
name='chunks',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitem',
|
||||
name='current',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitem',
|
||||
name='encryptionKey',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitem',
|
||||
name='hmac',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitem',
|
||||
name='version',
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='CollectionItemSnapshot',
|
||||
fields=[
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('version', models.PositiveSmallIntegerField()),
|
||||
('encryptionKey', models.BinaryField(editable=True)),
|
||||
('hmac', models.CharField(max_length=50)),
|
||||
('current', models.BooleanField(db_index=True, default=True)),
|
||||
('chunks', models.ManyToManyField(related_name='items', to='django_etesync.CollectionItemChunk')),
|
||||
('item', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='snapshots', to='django_etesync.CollectionItem')),
|
||||
],
|
||||
options={
|
||||
'unique_together': {('item', 'current')},
|
||||
},
|
||||
),
|
||||
]
|
@ -0,0 +1,28 @@
|
||||
# Generated by Django 3.0.3 on 2020-02-20 11:44
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('django_etesync', '0006_auto_20200220_1137'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='collectionitemchunk',
|
||||
name='item',
|
||||
field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='chunks', to='django_etesync.CollectionItem'),
|
||||
preserve_default=False,
|
||||
),
|
||||
migrations.AlterUniqueTogether(
|
||||
name='collectionitemchunk',
|
||||
unique_together={('item', 'order')},
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='collectionitemchunk',
|
||||
name='collection',
|
||||
),
|
||||
]
|
Loading…
Reference in New Issue