Thanks foy your replies.
The class Fondo has in truth lots of Textfield to be displayed as CharField
(I am using django.forms to implement a search mask); the one posted was
only an excerpt.
I solved this way:
class FondoForm(forms.ModelForm):
def __init__(self, *args, **kwargs):
super(FondoForm,
You can try this:
class Fondo(models.Model):
denominazione = models.CharField(max_length=200)
storia= models.TextField(blank=True)
class FondoForm(forms.ModelForm):
storia = forms.CharField(widget=forms.Textarea)
class Meta:
model = Fondo
I am not sure if this works.
On Jan 26, 11:45 am, Massimiliano della Rovere
wrote:
> I use django 1.1.1 and I defined:
>
> class Fondo(models.Model):
> denominazione = models.CharField(max_length=200)
> storia = models.TextField(blank=True)
>
> class FondoForm(forms.ModelForm):
>
I use django 1.1.1 and I defined:
class Fondo(models.Model):
denominazione = models.CharField(max_length=200)
storia= models.TextField(blank=True)
class FondoForm(forms.ModelForm):
class Meta:
model = Fondo
widgets = {'storia': forms.TextInput}
but the 'storia' field is still shown
4 matches
Mail list logo