Commit 0415f167 authored by Brescia Amandy's avatar Brescia Amandy

Edited homepage/models.py to add attributes

parent d8cc4431
......@@ -3,17 +3,24 @@ from django.db import models
# Create your models here.
class Artist(models.Model):
artist_name = models.CharField(max_length=255)
monthly_listeners = models.IntegerField()
artist_name = models.CharField(blank=True, max_length=255)
monthly_listeners = models.IntegerField(blank=True)
birth_name = models.CharField(blank=True, max_length=255)
bio = models.TextField(blank=True, max_length=700)
class Album(models.Model):
album_name = models.CharField(max_length=255)
album_name = models.CharField(blank=True, max_length=255)
artist = models.ForeignKey(Artist, on_delete=models.CASCADE)
description = models.TextField()
release_date = models.CharField(max_length=255)
description = models.TextField(blank=True, max_length=700)
release_date = models.CharField(blank=True, max_length=255)
label = models.CharField(blank=True, max_length=255)
song_count = models.IntegerField(blank=True)
class Song(models.Model):
song_title = models.CharField(max_length=255)
song_title = models.CharField(blank=True, max_length=255)
artist = models.ForeignKey(Artist, on_delete=models.CASCADE)
album = models.ForeignKey(Album, on_delete=models.CASCADE)
song_length = models.IntegerField()
\ No newline at end of file
song_length = models.IntegerField(blank=True)
music_video = models.BooleanField(default=False)
lyrics = models.TextField(blank=True)
\ No newline at end of file
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