Commit 2b804b8b authored by Raul Jarod Conanan's avatar Raul Jarod Conanan

Merge branch 'Assignments' into 'dev'

Assignments

See merge request !11
parents 21c92230 60d561f1
from django.contrib import admin
from .models import Assignment, Course
class AssignmentAdmin(admin.ModelAdmin):
model = Assignment
class CourseAdmin(admin.ModelAdmin):
model = Course
admin.site.register(Assignment, AssignmentAdmin)
admin.site.register(Course, CourseAdmin)
\ No newline at end of file
admin.site.register(Course, CourseAdmin)
from django.db import models
class Course(models.Model):
code = models.CharField(max_length=10, blank=True, null=True)
title = models.CharField(max_length=255, blank=True, null=True)
section = models.CharField(max_length=3, blank=True, null=True)
class Assignment(models.Model):
name = models.CharField(max_length=255, blank=True, null=True)
description = models.TextField(blank=True, null=True)
......
from django.shortcuts import render
from django.http import HttpResponse
from .models import Assignment, Course
import os
from .models import Assignment
def index(request):
......
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