[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9801 revid:mat@openerp.com-20140131160304-22mokur2uuo1cw4r
bzr revid: dle@openerp.com-20140131162637-046v995ozpy22qjj
This commit is contained in:
commit
3e4d932c58
|
@ -1605,7 +1605,11 @@ class account_bank_statement(osv.osv):
|
||||||
bank_st_line_obj = self.pool.get('account.bank.statement.line')
|
bank_st_line_obj = self.pool.get('account.bank.statement.line')
|
||||||
st_line = bank_st_line_obj.browse(cr, uid, st_line_id, context=context)
|
st_line = bank_st_line_obj.browse(cr, uid, st_line_id, context=context)
|
||||||
if st_line.voucher_id:
|
if st_line.voucher_id:
|
||||||
voucher_obj.write(cr, uid, [st_line.voucher_id.id], {'number': next_number}, context=context)
|
voucher_obj.write(cr, uid, [st_line.voucher_id.id],
|
||||||
|
{'number': next_number,
|
||||||
|
'date': st_line.date,
|
||||||
|
'period_id': st_line.statement_id.period_id.id},
|
||||||
|
context=context)
|
||||||
if st_line.voucher_id.state == 'cancel':
|
if st_line.voucher_id.state == 'cancel':
|
||||||
voucher_obj.action_cancel_draft(cr, uid, [st_line.voucher_id.id], context=context)
|
voucher_obj.action_cancel_draft(cr, uid, [st_line.voucher_id.id], context=context)
|
||||||
voucher_obj.signal_proforma_voucher(cr, uid, [st_line.voucher_id.id])
|
voucher_obj.signal_proforma_voucher(cr, uid, [st_line.voucher_id.id])
|
||||||
|
|
|
@ -94,7 +94,7 @@ class account_statement_from_invoice_lines(osv.osv_memory):
|
||||||
'account_id': result['value'].get('account_id', statement.journal_id.default_credit_account_id.id),
|
'account_id': result['value'].get('account_id', statement.journal_id.default_credit_account_id.id),
|
||||||
'company_id': statement.company_id.id,
|
'company_id': statement.company_id.id,
|
||||||
'currency_id': statement.currency.id,
|
'currency_id': statement.currency.id,
|
||||||
'date': line.date,
|
'date': statement.date,
|
||||||
'amount': sign*amount,
|
'amount': sign*amount,
|
||||||
'payment_rate': result['value']['payment_rate'],
|
'payment_rate': result['value']['payment_rate'],
|
||||||
'payment_rate_currency_id': result['value']['payment_rate_currency_id'],
|
'payment_rate_currency_id': result['value']['payment_rate_currency_id'],
|
||||||
|
@ -119,7 +119,7 @@ class account_statement_from_invoice_lines(osv.osv_memory):
|
||||||
'statement_id': statement_id,
|
'statement_id': statement_id,
|
||||||
'ref': line.ref,
|
'ref': line.ref,
|
||||||
'voucher_id': voucher_id,
|
'voucher_id': voucher_id,
|
||||||
'date': time.strftime('%Y-%m-%d'),
|
'date': statement.date,
|
||||||
}, context=context)
|
}, context=context)
|
||||||
return {'type': 'ir.actions.act_window_close'}
|
return {'type': 'ir.actions.act_window_close'}
|
||||||
|
|
||||||
|
|
|
@ -111,9 +111,6 @@ class procurement_order(osv.osv):
|
||||||
bom_result = production_obj.action_compute(cr, uid,
|
bom_result = production_obj.action_compute(cr, uid,
|
||||||
[produce_id], properties=[x.id for x in procurement.property_ids])
|
[produce_id], properties=[x.id for x in procurement.property_ids])
|
||||||
production_obj.signal_button_confirm(cr, uid, [produce_id])
|
production_obj.signal_button_confirm(cr, uid, [produce_id])
|
||||||
if res_id:
|
|
||||||
move_obj.write(cr, uid, [res_id],
|
|
||||||
{'location_id': procurement.location_id.id})
|
|
||||||
self.production_order_create_note(cr, uid, ids, context=context)
|
self.production_order_create_note(cr, uid, ids, context=context)
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue