Compare commits
1 Commits
14.0-accou
...
14.0-add-c
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
55622ec6a9 |
@@ -242,17 +242,6 @@ class AccountMoveLine(models.Model):
|
|||||||
compute='_compute_reconcile_string', string='Reconcile', store=True)
|
compute='_compute_reconcile_string', string='Reconcile', store=True)
|
||||||
# for optional display in tree view
|
# for optional display in tree view
|
||||||
product_barcode = fields.Char(related='product_id.barcode', string="Product Barcode")
|
product_barcode = fields.Char(related='product_id.barcode', string="Product Barcode")
|
||||||
balance = fields.Monetary(
|
|
||||||
string='Balance',
|
|
||||||
default=0.0,
|
|
||||||
currency_field='company_currency_id',
|
|
||||||
compute="_compute_balance",
|
|
||||||
store=True)
|
|
||||||
|
|
||||||
@api.depends("credit", "debit")
|
|
||||||
def _compute_balance(self):
|
|
||||||
for line in self:
|
|
||||||
line.balance = line.debit - line.credit
|
|
||||||
|
|
||||||
def show_account_move_form(self):
|
def show_account_move_form(self):
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
|
|||||||
@@ -70,9 +70,6 @@
|
|||||||
<field name="matching_number" position="after">
|
<field name="matching_number" position="after">
|
||||||
<button title="View Journal Entry Form" type="object" name="show_account_move_form" icon="fa-arrow-right"/>
|
<button title="View Journal Entry Form" type="object" name="show_account_move_form" icon="fa-arrow-right"/>
|
||||||
</field>
|
</field>
|
||||||
<field name="credit" position="after">
|
|
||||||
<field name="balance" sum="Balance" />
|
|
||||||
</field>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|||||||
@@ -30,3 +30,4 @@ class ProductTemplate(models.Model):
|
|||||||
sale_ok = fields.Boolean(tracking=80)
|
sale_ok = fields.Boolean(tracking=80)
|
||||||
purchase_ok = fields.Boolean(tracking=90)
|
purchase_ok = fields.Boolean(tracking=90)
|
||||||
active = fields.Boolean(tracking=100)
|
active = fields.Boolean(tracking=100)
|
||||||
|
company_id = fields.Many2one(tracking=110)
|
||||||
|
|||||||
Reference in New Issue
Block a user