models have been created.

parent c63428ed
from django.db import models from django.db import models
# Create your models here. # Create your models here.
class Course(models.Model):
code = models.CharField(max_length=10)
title = models.CharField(max_length=100)
section = models.CharField(max_length=3)
class Assignment(models.Model):
name = models.CharField(max_length=100)
description = models.TextField()
course = models.ForeignKey(
Course,
on_delete=models.PROTECT,
)
perfect_score = models.IntegerField()
passing_score = models.IntegerField(0.60*perfect_score)
\ 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