You did not fully implement the patch posted! The "relativedelta" part has to be changed, too. Otherwise, I get the following error:
File "/home/thomdrei/workspace/addons/account_payment_discount_extension/account_payment_discount.py", line 53, in action_date_assign
self.write(cr, uid, [inv.id], {'next_payment_date':(DateTime.strptime(inv.date_invoice, '%Y-%m-%d') + relativedelta(days=delay)).strftime('%Y-%m-%d')})
File "/usr/lib/pymodules/python2.6/dateutil/relativedelta.py", line 247, in __radd__
raise TypeError, "unsupported type for add operation"
TypeError: unsupported type for add operation
It has to be "DateTime.RelativeDateTime(days=delay)).strftime('%Y-%m-%d')"
You did not fully implement the patch posted! The "relativedelta" part has to be changed, too. Otherwise, I get the following error: thomdrei/ workspace/ addons/ account_ payment_ discount_ extension/ account_ payment_ discount. py", line 53, in action_date_assign payment_ date':( DateTime. strptime( inv.date_ invoice, '%Y-%m-%d') + relativedelta( days=delay) ).strftime( '%Y-%m- %d')}) pymodules/ python2. 6/dateutil/ relativedelta. py", line 247, in __radd__ RelativeDateTim e(days= delay)) .strftime( '%Y-%m- %d')"
File "/home/
self.write(cr, uid, [inv.id], {'next_
File "/usr/lib/
raise TypeError, "unsupported type for add operation"
TypeError: unsupported type for add operation
It has to be "DateTime.