mirror of
https://github.com/Hopiu/xapian-haystack.git
synced 2026-05-05 22:14:48 +00:00
36 lines
998 B
Python
36 lines
998 B
Python
from django.db import models
|
|
|
|
from ..core.models import MockTag, AnotherMockModel, MockModel, AFourthMockModel
|
|
|
|
|
|
class Document(models.Model):
|
|
type_name = models.CharField(max_length=50)
|
|
number = models.IntegerField()
|
|
name = models.CharField(max_length=200)
|
|
|
|
date = models.DateField()
|
|
|
|
summary = models.TextField()
|
|
text = models.TextField()
|
|
|
|
|
|
class BlogEntry(models.Model):
|
|
"""
|
|
Same as tests.core.MockModel with a few extra fields for testing various
|
|
sorting and ordering criteria.
|
|
"""
|
|
datetime = models.DateTimeField()
|
|
date = models.DateField()
|
|
|
|
tags = models.ManyToManyField(MockTag)
|
|
|
|
author = models.CharField(max_length=255)
|
|
text = models.TextField()
|
|
funny_text = models.TextField()
|
|
non_ascii = models.TextField()
|
|
url = models.URLField()
|
|
|
|
boolean = models.BooleanField()
|
|
number = models.IntegerField()
|
|
float_number = models.FloatField()
|
|
decimal_number = models.DecimalField(max_digits=4, decimal_places=2)
|