Created migrations for Post and Reply models. Renamed post_title field to post in Reply model.

parent 9ec90070
No preview for this file type
# Generated by Django 3.2.12 on 2022-04-07 02:35
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('homepage', '0001_initial'),
('forum', '0001_initial'),
]
operations = [
migrations.AddField(
model_name='post',
name='author',
field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='homepage.widgetuser'),
),
migrations.CreateModel(
name='Reply',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('reply_body', models.CharField(max_length=250)),
('pub_date', models.DateTimeField(verbose_name='date published')),
('author', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='homepage.widgetuser')),
],
),
]
# Generated by Django 3.2.12 on 2022-04-07 02:48
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('forum', '0002_auto_20220407_1035'),
]
operations = [
migrations.AddField(
model_name='reply',
name='post_title',
field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='forum.post'),
),
]
# Generated by Django 3.2.12 on 2022-04-07 05:49
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('forum', '0003_reply_post_title'),
]
operations = [
migrations.RenameField(
model_name='reply',
old_name='post_title',
new_name='post',
),
]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment