← Back to team overview

openerp-expert-framework team mailing list archive

Re: Time format without second

 

On 12/28/2011 04:15 PM, Quentin THEURET wrote:
Hello Framework experts,

I want to discuss with you about an issue on OpenERP time format.

You change the time format in the language, to don't see the seconds in
datetime fields.
In database, seconds are saved, but not displayed on clients, it's ok.

But, when you enter values in a datetime search field, you can't enter
second, so for example, when you search Tasks with End Date between
15/05/2011 15:24 to 15/05/2011 15:25, the created SQL query change the
datetime values from 15/05/2011 15:24:00 to 15/05/2011 15:25:00, which
doesn't displayed Tasks with an end date equal to 15/05/2011 15:25:20.

I need your advise about this issue because in my mind, when I enter
15:25, this include all Tasks with an End Date till 15:25:59 which
should be displayed.

What do you think about that ?

Best wishes.

I think No ?

becuase 15:25:29 means you need task before the 15:26:00 (as you can see 15:25:01 means the 26th minute has started) which seems not correct becuase the domain it will form will be like this get all task whose end date is >= 15/05/2011 15:24:00 and <=15/05/2011 15:25:00 for your case I think you need to search end_date>=15/05/2011 15:24:00 and <=15/05/2011 15:26:00.

if we replace the 00 from the "from" and "to" to 00 and 59 sec then the results will be always fetched 1 min ahead. i.e if the user ask for 24th minute then he will receive the results if any available for the 24th to 25th minute also.

what do you think ?

--
Regards,
Naresh Soni
O.P.W Team Leader,
TinyERP Pvt. Ltd.
16&  17 IT Tower - I
Infocity Gandhinagar,
Gujarat, 382009, India

Cell:8866370537,
Web:http://openerp.com,
email:nch@xxxxxxxxxxx







References