On Tue, Jul 15, 2008 at 7:25 AM, Tim Sawyer <[EMAIL PROTECTED]> wrote:
> In my form I have:
>
> datetime =
> forms.DateField(widget=forms.TextInput({'class' :
> 'date-pick'}),label="Available
> date")
>
> yet it's a DateTimeField in the model.
Why not use a DateTimeField in your form and change
On Tuesday 15 Jul 2008, Arien wrote:
> On Tue, Jul 15, 2008 at 4:57 AM, Tim Sawyer <[EMAIL PROTECTED]>
wrote:
> > In my code, I did this:
> >
> > self.datetime = pForm.cleaned_data['datetime']
> >
> > the datetime parameter passed from the form only contained the date, with
> > no time, so I assu
On Tue, Jul 15, 2008 at 4:57 AM, Tim Sawyer <[EMAIL PROTECTED]> wrote:
> In my code, I did this:
>
> self.datetime = pForm.cleaned_data['datetime']
>
> the datetime parameter passed from the form only contained the date, with no
> time, so I assume the value in datetime then was only a date.
This
On Monday 14 Jul 2008, Rajesh Dhawan wrote:
> On Jul 14, 5:40 pm, Tim Sawyer <[EMAIL PROTECTED]> wrote:
> > On Monday 14 Jul 2008, Rajesh Dhawan wrote:
> > > The replace method here returns a new instance of a datetime object --
> > > it's not an in-place replace. This should work:
> > >
> > > sel
On Jul 14, 5:40 pm, Tim Sawyer <[EMAIL PROTECTED]> wrote:
> On Monday 14 Jul 2008, Rajesh Dhawan wrote:
>
> > The replace method here returns a new instance of a datetime object --
> > it's not an in-place replace. This should work:
>
> > self.datetime = self.datetime.replace(hour=23, minute=59)
On Monday 14 Jul 2008, Rajesh Dhawan wrote:
> The replace method here returns a new instance of a datetime object --
> it's not an in-place replace. This should work:
>
> self.datetime = self.datetime.replace(hour=23, minute=59)
Hmm, that seemed to make sense to me too, though with my Java backgr
Hi Tim,
> I have an object with a model.DateTimeField on it. For various reasons, I
> need to set the time portion of this field to 23:59 when I populate it from a
> form.
>
> datetime = models.DateTimeField()
>
> How can I do this? I've tried
>
> self.datetime = pForm.cleaned_d
7 matches
Mail list logo