forked from Yaltik/golem
[IMP]GOLEM Resource Account : prefer origin more than name / reference here
This commit is contained in:
parent
9b25450a4a
commit
237ce73198
@ -55,18 +55,15 @@ class GolemReservationInvoiceWizard(models.TransientModel):
|
|||||||
product = reservation.resource_id.product_tmpl_id
|
product = reservation.resource_id.product_tmpl_id
|
||||||
amount = product.standard_price
|
amount = product.standard_price
|
||||||
lines.append((0, 0, {
|
lines.append((0, 0, {
|
||||||
'name': reservation.resource_id.name,
|
'origin': reservation.resource_id.name,
|
||||||
#'origin': ,
|
|
||||||
'account_id': account_id,
|
'account_id': account_id,
|
||||||
'price_unit': amount,
|
'price_unit': amount,
|
||||||
'quantity': 1.0,
|
'quantity': 1.0,
|
||||||
'discount': 0.0,
|
|
||||||
'uom_id': product.uom_id.id,
|
'uom_id': product.uom_id.id,
|
||||||
'product_id': product.id,
|
'product_id': product.id,
|
||||||
}))
|
}))
|
||||||
invoice = inv_obj.create({
|
invoice = inv_obj.create({
|
||||||
'name': self.reservation_ids[-1].name,
|
'origin': self.reservation_ids[-1].name,
|
||||||
#'origin': self.application_number,
|
|
||||||
'type': 'out_invoice',
|
'type': 'out_invoice',
|
||||||
'reference': False,
|
'reference': False,
|
||||||
'account_id': partner_id.property_account_receivable_id.id,
|
'account_id': partner_id.property_account_receivable_id.id,
|
||||||
|
Loading…
Reference in New Issue
Block a user