[FIX] project: Fixed default date value computed at server startup.
lp bug: https://launchpad.net/bugs/624509 fixed bzr revid: uco@tinyerp.com-20101102112909-z03so3ydx0fr1t9d
This commit is contained in:
parent
f7f51a9497
commit
0f4d932dda
|
@ -703,7 +703,7 @@ class project_work(osv.osv):
|
|||
|
||||
_defaults = {
|
||||
'user_id': lambda obj, cr, uid, context: uid,
|
||||
'date': time.strftime('%Y-%m-%d %H:%M:%S')
|
||||
'date': lambda *a: time.strftime('%Y-%m-%d %H:%M:%S')
|
||||
}
|
||||
|
||||
_order = "date desc"
|
||||
|
|
|
@ -138,8 +138,8 @@ class report_account_analytic_planning(osv.osv):
|
|||
'total_free': fields.function(_get_total_free, method=True, string='Total Free'),
|
||||
}
|
||||
_defaults = {
|
||||
'date_from': time.strftime('%Y-%m-01'),
|
||||
'date_to': (datetime.now()+relativedelta(months=1, day=1, days=-1)).strftime('%Y-%m-%d'),
|
||||
'date_from': lambda *a: time.strftime('%Y-%m-01'),
|
||||
'date_to': lambda *a: (datetime.now()+relativedelta(months=1, day=1, days=-1)).strftime('%Y-%m-%d'),
|
||||
'user_id': lambda self, cr, uid, c: uid,
|
||||
'state': 'draft',
|
||||
'business_days': 20,
|
||||
|
|
|
@ -123,7 +123,7 @@ class project_scrum_sprint(osv.osv):
|
|||
}
|
||||
_defaults = {
|
||||
'state': 'draft',
|
||||
'date_start' : time.strftime('%Y-%m-%d'),
|
||||
'date_start' : lambda *a: time.strftime('%Y-%m-%d'),
|
||||
}
|
||||
|
||||
def copy(self, cr, uid, id, default=None, context=None):
|
||||
|
|
Loading…
Reference in New Issue