date widget not working properly

Bug #987745 reported by Sanjay Gohel (Open ERP)
28
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Odoo Web (MOVED TO GITHUB)
Invalid
Medium
OpenERP R&D Web Team

Bug Description

hello,

 When I change any date the format of date will be change and when saved record following traceback throws.

2012-04-24 10:06:54,385 12120 ERROR None openerp.sql_db: bad query: update sale_order set "date_order"=E'Fri Apr 27 2012 00:00:00 GMT+0530 (IST)',write_uid=1,write_date=(now() at time zone 'UTC') where id IN (8)
Traceback (most recent call last):
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/sql_db.py", line 212, in execute
    res = self._obj.execute(query, params)
DataError: time zone "gmt+0530" not recognized
LINE 1: update sale_order set "date_order"=E'Fri Apr 27 2012 00:00:0...
                                           ^

2012-04-24 10:06:54,386 12120 ERROR None openerp.osv.osv: Uncaught exception
Traceback (most recent call last):
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/osv/osv.py", line 121, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/osv/osv.py", line 176, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/osv/osv.py", line 164, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/sgo/workplace/rdtools/addons/trunk-contract-apa-imp-sgo/sale/sale.py", line 383, in write
    return super(sale_order, self).write(cr, uid, ids, vals, context=context)
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/addons/base/ir/ir_needaction.py", line 163, in write
    write_res = super(ir_needaction_mixin, self).write(cr, uid, ids, values, context=context)
  File "/home/sgo/workplace/rdtools/addons/trunk-contract-apa-imp-sgo/mail/mail_thread.py", line 91, in write
    write_res = super(mail_thread, self).write(cr, uid, ids, vals, context=context);
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/osv/orm.py", line 3920, in write
    'where id IN %s', upd1 + [sub_ids])
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/sql_db.py", line 152, in wrapper
    return f(self, *args, **kwargs)
  File "/home/sgo/workplace/rdtools/server/trunk/openerp/sql_db.py", line 212, in execute
    res = self._obj.execute(query, params)
DataError: time zone "gmt+0530" not recognized
LINE 1: update sale_order set "date_order"=E'Fri Apr 27 2012 00:00:0...
                                           ^

2012-04-24 10:06:54,389 12120 ERROR None openerp.netsvc: time zone "gmt+0530" not recognized
LINE 1: update sale_order set "date_order"=E'Fri Apr 27 2012 00:00:0...

Thank you.

Related branches

Revision history for this message
Vishal Parmar(Open ERP) (vpa-openerp) wrote :

Hello,

I have faced the same problem and It's a generalized issue.

Thanks.

Changed in openerp-web:
assignee: nobody → OpenERP R&D Web Team (openerp-dev-web)
importance: Undecided → Medium
status: New → Confirmed
affects: openerp-web → openobject-server
Changed in openobject-server:
assignee: OpenERP R&D Web Team (openerp-dev-web) → OpenERP's Framework R&D (openerp-dev-framework)
Revision history for this message
Jigar A. (ifixthat) wrote :

Hello
      We have traced the issue and the issue ha to be fixed from client side as the datetime format return to serer is not in UTC format . So I am transferring bug to web project. Let me know If I am missing anything.
Thank You.

affects: openobject-server → openerp-web
Changed in openerp-web:
assignee: OpenERP's Framework R&D (openerp-dev-framework) → OpenERP R&D Web Team (openerp-dev-web)
Revision history for this message
Cristian Salamea (ovnicraft) wrote :

I check at revno 2314 and i cant reproduce the bug.

Can you detail the steps to reproduce it.

Regards,

Revision history for this message
Farid Ghanchi (gfarid) wrote :
Changed in openerp-web:
status: Confirmed → Fix Committed
Revision history for this message
Jiten (OpenERP) (jiten-openerp) wrote :

- The fixed code which is describe in comment #4, It is not perfect solution. It need some other changes and according that Now it is fixed with latest trunk code.

Revision history for this message
Nicolas Vanhoren (OpenERP) (niv-openerp) wrote :

This bug does not seem to reproduce any more. Since the branch of Farid is not a proper fix either, I just close this bug.

Changed in openerp-web:
status: Fix Committed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.