Re: adding a summary field to a model

2010-08-19 Thread widoyo
Commessa) >     ore=models.IntegerField() > ... > > I want to add a column to Commessa containg the result of: > > quota_oraria * sum(ore) > Widoyo -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this gr

Re: Need some help with URL layout

2010-08-21 Thread widoyo
It could be better if you omit '_ALL' at URL So: /ranking/de/ # for Germany ranking Nation wide /ranking/ # for all country can put summary of ranking for such URL, instead of list of all ranking nation or all country. Widoyo On Aug 21, 7:35 am, Uwe Schuerkamp wrote: > ranking/de

Re: Enter a field in the database after encryption

2010-08-21 Thread widoyo
refer to this docs: http://docs.djangoproject.com/en/1.2/ref/contrib/admin/#modeladmin-methods Use def save_model(self, ...): mymodel.password = # put your md5 encrypted here ... mymodel.save() Widoyo On Aug 21, 11:05 pm, Amitanshu wrote: > Actually I missed something in my p

Re: mutually referential models

2010-08-21 Thread widoyo
ManyToManyField(ComputerInterface) > interfaces = models.ManyToManyField('ComputerInterface') Widoyo > class ComputerInterface(Node): >     ipAddr = models.IPAddressField(null=True) >     mbitsPerSec = models.IntegerField(null=True) ... -- You received this message because yo

Re: how to prepopulate admin form with default data?

2010-08-21 Thread widoyo
Hello Gondor, If you mean 'admin model' is http://localhost:8000/admin/ (Django Admin page) your problem solution is mentioned in this docs: http://docs.djangoproject.com/en/1.2/ref/contrib/admin/#modeladmin-methods Widoyo On Aug 21, 2:57 pm, gondor wrote: > class Notes

Re: Forms: set required value at runtime

2010-10-23 Thread widoyo
On Oct 24, 3:28 am, bobo wrote: > I'd like to do, if I uncheck the 'same' field, then the required for > the post_address change to True. > I tried width the overall clean method, but when I raise > forms.ValidationError, I can't raise the error for the post_address > field. > > Can I change the r

Re: Subdomain/Accounts

2010-12-23 Thread widoyo
May be this link will help you: http://www.rossp.org/blog/2007/apr/28/using-subdomains-django/ Widoyo On Dec 23, 11:29 am, Parra wrote: > Can someone give me some tips on where to get started with this ?? > -- You received this message because you are subscribed to the Google Groups &