Commit f191f624 authored by Jan Ericsson Ong Ang's avatar Jan Ericsson Ong Ang

Jan

Created and migrated models & edited the extra song_title into song_length
parent b49bec71
No preview for this file type
# Generated by Django 4.1.6 on 2023-02-21 15:12
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('homepage', '0001_initial'),
]
operations = [
migrations.CreateModel(
name='Artist',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('artist_name', models.CharField(max_length=50)),
('monthly_listeners', models.IntegerField(default=0)),
('birth_name', models.CharField(default='', max_length=50)),
('bio', models.CharField(default='', max_length=700)),
],
),
migrations.DeleteModel(
name='IndexCard',
),
migrations.AddField(
model_name='album',
name='label',
field=models.CharField(default='', max_length=50),
),
migrations.AddField(
model_name='album',
name='song_count',
field=models.CharField(default='', max_length=50),
),
migrations.AddField(
model_name='song',
name='lyrics',
field=models.TextField(default=''),
),
migrations.AddField(
model_name='song',
name='music_video',
field=models.BooleanField(default=False),
),
migrations.AlterField(
model_name='album',
name='release_date',
field=models.DateField(verbose_name='date released'),
),
migrations.AlterField(
model_name='song',
name='song_length',
field=models.IntegerField(default=0),
),
]
......@@ -16,7 +16,7 @@ class Album(models.Model):
album_name = models.CharField(max_length=50)
artist = models.CharField(max_length=50)
description = models.CharField(max_length=500)
release_date = models.DateTimeField("date released")
release_date = models.DateField("date released")
label = models.CharField(max_length=50, default="")
song_count = models.CharField(max_length=50, default="")
......@@ -28,7 +28,7 @@ class Song(models.Model):
song_title = models.CharField(max_length=50)
artist = models.CharField(max_length=50)
album = models.CharField(max_length=50)
song_title = models.IntegerField(default=0)
song_length = models.IntegerField(default=0)
music_video = models.BooleanField(default=False)
lyrics = models.TextField(default="")
......
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