summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAzka Nathan <darizkyfaz@gmail.com>2023-08-29 10:21:37 +0700
committerAzka Nathan <darizkyfaz@gmail.com>2023-08-29 10:21:37 +0700
commit664cabd6c3056424a9bb5a7a1c281246f7ed94ff (patch)
treea959cb57a8c19bf7a3114aefbf66586042702426
parent2676aa95c7c37a8a798675ca58cd2263b2dfcee3 (diff)
financial report
-rw-r--r--indoteknik_custom/models/account_financial_report.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/indoteknik_custom/models/account_financial_report.py b/indoteknik_custom/models/account_financial_report.py
index 6147a3f3..d8037ee8 100644
--- a/indoteknik_custom/models/account_financial_report.py
+++ b/indoteknik_custom/models/account_financial_report.py
@@ -70,7 +70,12 @@ class AccountingReport(models.TransientModel):
for date_range in date_ranges:
row_number = 9
data['form']['used_context']['date_to'] = date_range['date_to']
- data['form']['used_context']['date_from'] = first_journal_date
+
+ if obj.account_report_id.id in [338]:
+ data['form']['used_context']['date_from'] = first_journal_date
+ else:
+ data['form']['used_context']['date_from'] = date_range['date_from']
+
comp_dic['state'] = 'posted'
comp_dic['journal_ids'] = data['form']['journal_ids']
data['form']['comparison_context'] = comp_dic