views:

668

answers:

1

Hi,

Im new in using Django, and i want to know if there is some way to have a multiple date selection from a calendar,

i have multiple days :

for example a day is :

[ 28 july 2009 8:30 - 28 july 17h00 ]

Is there any way to do this with Django Forms

Thanks a lot

kimo

A: 

I don't believe this is supported out of the box, but should be doable through a custom widget and some associated media. See the source for the datetime widget and its associated media for the current implementation. You should be able to base your solution off that one. By combining two dates into a single widget/field, you can create a date range. Also see the source for the MultiValueField and its widget, respectively.

Cide
thank you ! I will try.with forms.DateField(widget=DateTimeWidget()) im able to select one.Is is possible to use a MultipleChoiceField() with this
Cide
But a SplitDateTimeField : Date is separated from the Time, we can add manually date and time in the correct format.I think with a ManytoMany Field it will but possible to select multiple date, we have just to create from the admin interface the dates before.Thank you for your replies :-)