Skip to content

Commit 0d187f7

Browse files
committed
Merge PR #589 into 16.0
Signed-off-by sbidoul
2 parents 6cf6a7a + 65e3608 commit 0d187f7

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

Diff for: mis_builder_budget/models/mis_budget_by_account.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class MisBudgetByAccount(models.Model):
1212
item_ids = fields.One2many(
1313
comodel_name="mis.budget.by.account.item", inverse_name="budget_id", copy=True
1414
)
15-
company_id = fields.Many2one(required=True)
15+
company_id = fields.Many2one(required=False)
1616
allow_items_overlap = fields.Boolean(
1717
help="If checked, overlap between budget items is allowed"
1818
)

Diff for: mis_builder_budget/models/mis_budget_by_account_item.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@ class MisBudgetByAccountItem(models.Model):
2222
)
2323
company_id = fields.Many2one(
2424
"res.company",
25-
related="budget_id.company_id",
25+
related="account_id.company_id",
2626
readonly=True,
2727
store=True,
2828
)
2929
company_currency_id = fields.Many2one(
3030
"res.currency",
31-
related="budget_id.company_id.currency_id",
31+
related="account_id.company_id.currency_id",
3232
string="Company Currency",
3333
readonly=True,
3434
help="Utility field to express amount currency",
@@ -38,7 +38,6 @@ class MisBudgetByAccountItem(models.Model):
3838
comodel_name="account.account",
3939
string="Account",
4040
required=True,
41-
# TODO domain (company_id)
4241
)
4342

4443
_sql_constraints = [

0 commit comments

Comments
 (0)