keep a log of changes

This commit is contained in:
j 2012-01-31 22:36:10 +05:30
commit 82c83c1309
12 changed files with 61 additions and 3 deletions

View file

View file

@ -0,0 +1,13 @@
# -*- coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
from __future__ import division, with_statement
from django.db import models
from ox.django import fields
class Changelog(models.Model):
created = models.DateTimeField(auto_now_add=True)
type = models.CharField(max_length=255, db_index=True)
value = fields.DictField(default={})
def __unicode__(self):
return u'%s %s' %(self.type, self.created)

View file

@ -0,0 +1,16 @@
"""
This file demonstrates writing tests using the unittest module. These will pass
when you run "manage.py test".
Replace this with more appropriate tests for your application.
"""
from django.test import TestCase
class SimpleTest(TestCase):
def test_basic_addition(self):
"""
Tests that 1 + 1 always equals 2.
"""
self.assertEqual(1 + 1, 2)

View file

@ -0,0 +1 @@
# Create your views here.