diff --git a/addons/account/account_move_line.py b/addons/account/account_move_line.py
index 7f86f86420d..0dacc365fcc 100644
--- a/addons/account/account_move_line.py
+++ b/addons/account/account_move_line.py
@@ -936,6 +936,8 @@ class account_move_line(osv.osv):
del vals['account_tax_id']
if not is_new_move and 'date' in vals:
+ if context and ('__last_update' in context):
+ del context['__last_update']
self.pool.get('account.move').write(cr, uid, [move_id], {'date':vals['date']}, context=context)
if check:
tmp = self.pool.get('account.move').validate(cr, uid, [vals['move_id']], context)
diff --git a/addons/account/demo/account_minimal.xml b/addons/account/demo/account_minimal.xml
index a8c8b75b88c..8ab449af66a 100644
--- a/addons/account/demo/account_minimal.xml
+++ b/addons/account/demo/account_minimal.xml
@@ -167,8 +167,8 @@ your own chart of account.
sale
-
-
+
+
@@ -178,8 +178,8 @@ your own chart of account.
True
-
-
+
+
@@ -189,8 +189,8 @@ your own chart of account.
purchase
-
-
+
+
@@ -200,8 +200,8 @@ your own chart of account.
True
-
-
+
+
diff --git a/addons/hr_attendance/report/bymonth.py b/addons/hr_attendance/report/bymonth.py
index bce9bd4d3ce..d0715b4b66d 100644
--- a/addons/hr_attendance/report/bymonth.py
+++ b/addons/hr_attendance/report/bymonth.py
@@ -65,7 +65,7 @@ class report_custom(report_rml):
where att.name between %s and %s and emp.id = %s
order by att.name
'''
- cr.execute(sql, (today, tomor, employee_id))
+ cr.execute(sql, (today.strftime('%Y-%m-%d %H:%M:%S'), tomor.strftime('%Y-%m-%d %H:%M:%S'), employee_id))
attendences = cr.dictfetchall()
wh = 0
# Fake sign ins/outs at week ends, to take attendances across week ends into account
diff --git a/addons/hr_attendance/report/timesheet.py b/addons/hr_attendance/report/timesheet.py
index a3a370bcb99..feec7743370 100644
--- a/addons/hr_attendance/report/timesheet.py
+++ b/addons/hr_attendance/report/timesheet.py
@@ -46,13 +46,9 @@ class report_custom(report_rml):
service = netsvc.LocalService('object_proxy')
start_date = DateTime.strptime(datas['form']['init_date'], '%Y-%m-%d')
- print "XXX start_date %s" % start_date
end_date = DateTime.strptime(datas['form']['end_date'], '%Y-%m-%d')
- print "XXX end_date %s" % end_date
first_monday = start_date - DateTime.RelativeDateTime(days=start_date.day_of_week)
- print "XXX first_monday %s" % first_monday
last_monday = end_date + DateTime.RelativeDateTime(days=7 - end_date.day_of_week)
- print "XXX last_monday %s" % last_monday
if last_monday < first_monday:
first_monday, last_monday = last_monday, first_monday
@@ -60,7 +56,6 @@ class report_custom(report_rml):
user_xml = []
for employee_id in ids:
- print "XXX employee_id %s" % employee_id
emp = service.execute(cr.dbname, uid, 'hr.employee', 'read', [employee_id], ['id', 'name'])[0]
monday, n_monday = first_monday, first_monday + one_week
stop, week_xml = False, []
@@ -80,10 +75,8 @@ class report_custom(report_rml):
order by att.name
'''
for idx in range(7):
- print sql % (monday, monday + DateTime.RelativeDateTime(days=idx+1), employee_id)
- cr.execute(sql, (monday, monday + DateTime.RelativeDateTime(days=idx+1), employee_id))
+ cr.execute(sql, (monday.strftime('%Y-%m-%d %H:%M:%S'), (monday + DateTime.RelativeDateTime(days=idx+1)).strftime('%Y-%m-%d %H:%M:%S'), employee_id))
attendances = cr.dictfetchall()
- print "attendances %s" %attendances
week_wh = {}
# Fake sign ins/outs at week ends, to take attendances across week ends into account
# XXX this is wrong for the first sign-in ever and the last sign out to this date
@@ -109,7 +102,6 @@ class report_custom(report_rml):
week_repr.append('%sh%02d' % to_hour(reduce(lambda x,y:x+y, week_wh.values(), 0)))
week_repr.append('')
week_repr.append('')
- print "XXX week_repr %s" % week_repr
if len(week_repr) > 21: # 21 = minimal length of week_repr
week_xml.append('\n'.join(week_repr))
@@ -121,7 +113,6 @@ class report_custom(report_rml):
%s
''' % '\n'.join(user_xml)
- print "XXX xml %s" % xml
return self.post_process_xml_data(cr, uid, xml, context)
report_custom('report.hr.timesheet.allweeks', 'hr.employee', '', 'addons/hr_attendance/report/timesheet.xsl')
diff --git a/addons/hr_attendance/wizard/print_bymonth.py b/addons/hr_attendance/wizard/print_bymonth.py
index 0261d94f594..4e28055bcdc 100644
--- a/addons/hr_attendance/wizard/print_bymonth.py
+++ b/addons/hr_attendance/wizard/print_bymonth.py
@@ -31,15 +31,26 @@ _date_form = '''
'''
_date_fields = {
- 'month' : {'string' : 'Month', 'type' : 'selection', 'selection' : [(1, 'January'), (2, 'February'), (3, 'March'), (4, 'April'), (5, 'May'), (6, 'June'), (7, 'July'), (8, 'August'), (9, 'September'), (10, 'October'), (11, 'November'), (12, 'December')], 'required':True },
- 'year' : {'string' : 'Year', 'type' : 'integer', 'required':True, 'default' : lambda *a: time.gmtime()[0]},
+ 'month' : {
+ 'string' : 'Month',
+ 'type' : 'selection',
+ 'selection' : [(1, 'January'), (2, 'February'), (3, 'March'), (4, 'April'), (5, 'May'), (6, 'June'), (7, 'July'), (8, 'August'), (9, 'September'), (10, 'October'), (11, 'November'), (12, 'December')],
+ 'required':True,
+ 'default' : lambda * a: time.gmtime()[1]
+ },
+ 'year' : {
+ 'string' : 'Year',
+ 'type' : 'integer',
+ 'required':True,
+ 'default' : lambda * a: time.gmtime()[0]
+ },
}
class wiz_bymonth(wizard.interface):
states = {
'init': {
'actions': [],
- 'result': {'type': 'form', 'arch':_date_form, 'fields':_date_fields, 'state':[('print','Print Timesheet'),('end','Cancel')]}
+ 'result': {'type': 'form', 'arch':_date_form, 'fields':_date_fields, 'state':[('print', 'Print Timesheet'), ('end', 'Cancel')]}
},
'print': {
'actions': [],
diff --git a/addons/l10n_be/account_pcmn_belgium.xml b/addons/l10n_be/account_pcmn_belgium.xml
index b5d183565c9..d3ec2a73f69 100644
--- a/addons/l10n_be/account_pcmn_belgium.xml
+++ b/addons/l10n_be/account_pcmn_belgium.xml
@@ -6466,7 +6466,7 @@
45
- Operations avec TVA due par le concotractant
+ Operations avec TVA due par le cocontractant