File: models.py

package info (click to toggle)
python-django-channels 4.3.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,040 kB
  • sloc: python: 3,109; makefile: 155; javascript: 60; sh: 8
file content (10 lines) | stat: -rw-r--r-- 242 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
from django.db import models


class Message(models.Model):
    title = models.CharField(max_length=255)
    message = models.TextField()
    created = models.DateTimeField(auto_now_add=True)

    def __str__(self):
        return self.title