blob: 5a76503b182f44c76519f060362ecaa70018060c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from django.db import models
from django.contrib.auth.models import User
class Paper(models.Model):
"""Data model for storing proceedings paper.
"""
# Title of the paper
title = models.CharField(max_length=200)
# Abstract to be published with the paper
abstract = models.TextField()
# Body text of the paper
body = models.TextField()
# Authors
authors = models.ManyToManyField(User)
class Attachments(models.Model):
"""Stores attachments for papers.
"""
# Attachment for generating paper
attachments = models.FileField(upload_to='attachments/%Y/%m/%d')
# The paper to which this attachment belongs to
paper = models.ForeignKey(Paper)
|