Morning all

I've been meaning to post this to the list for a while, and I think my 
code is now ready to be shown. I've been working on a small bug tracker 
type project for myself - as I have 3 Django projects on the go at the 
moment. Anyway, I wanted a way to track changes made to bugs/tickets so 
I made this automatic history decorator. It works by logging revisions 
of fields on a model, so you can specific which fields should have a 
history, etc.

I haven't included rollback support yet, but if people are interested, I 
will happily look into offering it (shouldn't be hard!) Without furthor 
ado, here is the website, with a mini example application too:

http://acid2.user.openhosting.com/history/

The way that my auto history module works is through decorating the 
save() method of a model. Everytime you save a model, it looks up the 
model in the database first. Then, each field is compared and log 
entries are made. You can then retrieve a list of these changes through 
the models provided (see the example in the zip).

This was mainly an experiment to learn introspection and metaprogramming 
type stuff in Python, but if anyone has any ideas on what could improve 
this, I'd love to hear them.

Thanks, hope someone finds it useful!

--
Oliver Charles

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to