2008-08-10 01:19:23 +08:00
|
|
|
"""
|
|
|
|
Tests for forcing insert and update queries (instead of Django's normal
|
|
|
|
automatic behaviour).
|
|
|
|
"""
|
2011-07-13 17:35:51 +08:00
|
|
|
from django.db import models
|
2008-08-10 01:19:23 +08:00
|
|
|
|
2011-10-14 02:04:12 +08:00
|
|
|
|
2008-08-10 01:19:23 +08:00
|
|
|
class Counter(models.Model):
|
|
|
|
name = models.CharField(max_length = 10)
|
|
|
|
value = models.IntegerField()
|
|
|
|
|
|
|
|
class WithCustomPK(models.Model):
|
|
|
|
name = models.IntegerField(primary_key=True)
|
|
|
|
value = models.IntegerField()
|