odoo-addon-account-reconcile-oca 17.0.1.5.8__py3-none-any.whl → 18.0.1.0.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- odoo/addons/account_reconcile_oca/README.rst +6 -6
- odoo/addons/account_reconcile_oca/__manifest__.py +1 -1
- odoo/addons/account_reconcile_oca/demo/demo.xml +0 -1
- odoo/addons/account_reconcile_oca/i18n/account_reconcile_oca.pot +6 -26
- odoo/addons/account_reconcile_oca/models/account_account_reconcile.py +6 -8
- odoo/addons/account_reconcile_oca/models/account_bank_statement_line.py +22 -16
- odoo/addons/account_reconcile_oca/models/account_reconcile_abstract.py +1 -1
- odoo/addons/account_reconcile_oca/static/description/index.html +4 -4
- odoo/addons/account_reconcile_oca/static/src/js/reconcile/reconcile_controller.esm.js +2 -3
- odoo/addons/account_reconcile_oca/static/src/js/reconcile/reconcile_kanban_record.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile/reconcile_renderer.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile/reconcile_view.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_form/reconcile_form_controller.esm.js +1 -3
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_form/reconcile_form_notebook.esm.js +0 -1
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_form/reconcile_form_renderer.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_form/reconcile_form_view.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_manual/reconcile_manual_controller.esm.js +2 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_manual/reconcile_manual_view.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_move_line/reconcile_move_line_controller.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_move_line/reconcile_move_line_renderer.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/reconcile_move_line/reconcile_move_line_view.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/widgets/reconcile_chatter_field.esm.js +2 -4
- odoo/addons/account_reconcile_oca/static/src/js/widgets/reconcile_data_widget.esm.js +2 -1
- odoo/addons/account_reconcile_oca/static/src/js/widgets/reconcile_move_line_widget.esm.js +0 -2
- odoo/addons/account_reconcile_oca/static/src/js/widgets/selection_badge_uncheck.esm.js +0 -1
- odoo/addons/account_reconcile_oca/static/src/xml/reconcile.xml +3 -3
- odoo/addons/account_reconcile_oca/tests/test_account_reconcile.py +32 -55
- odoo/addons/account_reconcile_oca/tests/test_bank_account_reconcile.py +31 -28
- odoo/addons/account_reconcile_oca/views/account_account.xml +3 -5
- odoo/addons/account_reconcile_oca/views/account_account_reconcile.xml +13 -20
- odoo/addons/account_reconcile_oca/views/account_bank_statement.xml +0 -2
- odoo/addons/account_reconcile_oca/views/account_bank_statement_line.xml +66 -71
- odoo/addons/account_reconcile_oca/views/account_journal.xml +8 -12
- odoo/addons/account_reconcile_oca/views/account_move.xml +0 -4
- odoo/addons/account_reconcile_oca/views/account_move_line.xml +23 -24
- odoo/addons/account_reconcile_oca/views/res_config_settings.xml +0 -4
- {odoo_addon_account_reconcile_oca-17.0.1.5.8.dist-info → odoo_addon_account_reconcile_oca-18.0.1.0.1.dist-info}/METADATA +11 -11
- {odoo_addon_account_reconcile_oca-17.0.1.5.8.dist-info → odoo_addon_account_reconcile_oca-18.0.1.0.1.dist-info}/RECORD +40 -40
- {odoo_addon_account_reconcile_oca-17.0.1.5.8.dist-info → odoo_addon_account_reconcile_oca-18.0.1.0.1.dist-info}/WHEEL +0 -0
- {odoo_addon_account_reconcile_oca-17.0.1.5.8.dist-info → odoo_addon_account_reconcile_oca-18.0.1.0.1.dist-info}/top_level.txt +0 -0
@@ -1,3 +1,4 @@
|
|
1
|
+
from odoo import Command
|
1
2
|
from odoo.tests import Form, tagged
|
2
3
|
|
3
4
|
from odoo.addons.account_reconcile_model_oca.tests.common import (
|
@@ -12,9 +13,9 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
12
13
|
return {**cls.env.context, "_test_account_reconcile_oca": True}
|
13
14
|
|
14
15
|
@classmethod
|
15
|
-
def setUpClass(cls
|
16
|
-
super().setUpClass(
|
17
|
-
cls.env = cls.env(context=cls.
|
16
|
+
def setUpClass(cls):
|
17
|
+
super().setUpClass()
|
18
|
+
cls.env = cls.env(context=dict(cls.env.context, tracking_disable=True))
|
18
19
|
cls.acc_bank_stmt_model = cls.env["account.bank.statement"]
|
19
20
|
cls.acc_bank_stmt_line_model = cls.env["account.bank.statement.line"]
|
20
21
|
cls.bank_journal_usd.suspense_account_id = (
|
@@ -28,7 +29,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
28
29
|
.search(
|
29
30
|
[
|
30
31
|
("account_type", "=", "asset_current"),
|
31
|
-
("
|
32
|
+
("company_ids", "in", cls.env.company.id),
|
32
33
|
],
|
33
34
|
limit=1,
|
34
35
|
)
|
@@ -40,7 +41,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
40
41
|
.search(
|
41
42
|
[
|
42
43
|
("account_type", "=", "asset_receivable"),
|
43
|
-
("
|
44
|
+
("company_ids", "in", cls.env.company.id),
|
44
45
|
],
|
45
46
|
limit=1,
|
46
47
|
)
|
@@ -52,7 +53,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
52
53
|
.search(
|
53
54
|
[
|
54
55
|
("account_type", "=", "equity"),
|
55
|
-
("
|
56
|
+
("company_ids", "in", cls.env.company.id),
|
56
57
|
],
|
57
58
|
limit=1,
|
58
59
|
)
|
@@ -63,7 +64,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
63
64
|
.search(
|
64
65
|
[
|
65
66
|
("account_type", "=", "asset_non_current"),
|
66
|
-
("
|
67
|
+
("company_ids", "in", cls.env.company.id),
|
67
68
|
],
|
68
69
|
limit=1,
|
69
70
|
)
|
@@ -73,23 +74,19 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
73
74
|
cls.move_1 = cls.env["account.move"].create(
|
74
75
|
{
|
75
76
|
"line_ids": [
|
76
|
-
(
|
77
|
-
0,
|
78
|
-
0,
|
77
|
+
Command.create(
|
79
78
|
{
|
80
79
|
"account_id": cls.current_assets_account.id,
|
81
80
|
"name": "DEMO",
|
82
81
|
"credit": 100,
|
83
|
-
}
|
82
|
+
}
|
84
83
|
),
|
85
|
-
(
|
86
|
-
0,
|
87
|
-
0,
|
84
|
+
Command.create(
|
88
85
|
{
|
89
86
|
"account_id": cls.non_current_assets_account.id,
|
90
87
|
"name": "DEMO",
|
91
88
|
"debit": 100,
|
92
|
-
}
|
89
|
+
}
|
93
90
|
),
|
94
91
|
]
|
95
92
|
}
|
@@ -98,23 +95,19 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
98
95
|
cls.move_2 = cls.env["account.move"].create(
|
99
96
|
{
|
100
97
|
"line_ids": [
|
101
|
-
(
|
102
|
-
0,
|
103
|
-
0,
|
98
|
+
Command.create(
|
104
99
|
{
|
105
100
|
"account_id": cls.non_current_assets_account.id,
|
106
101
|
"name": "DEMO",
|
107
102
|
"credit": 50,
|
108
|
-
}
|
103
|
+
}
|
109
104
|
),
|
110
|
-
(
|
111
|
-
0,
|
112
|
-
0,
|
105
|
+
Command.create(
|
113
106
|
{
|
114
107
|
"account_id": cls.equity_account.id,
|
115
108
|
"name": "DEMO",
|
116
109
|
"debit": 50,
|
117
|
-
}
|
110
|
+
}
|
118
111
|
),
|
119
112
|
]
|
120
113
|
}
|
@@ -123,23 +116,19 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
123
116
|
cls.move_3 = cls.env["account.move"].create(
|
124
117
|
{
|
125
118
|
"line_ids": [
|
126
|
-
(
|
127
|
-
0,
|
128
|
-
0,
|
119
|
+
Command.create(
|
129
120
|
{
|
130
121
|
"account_id": cls.non_current_assets_account.id,
|
131
122
|
"name": "DEMO",
|
132
123
|
"credit": 50,
|
133
|
-
}
|
124
|
+
}
|
134
125
|
),
|
135
|
-
(
|
136
|
-
0,
|
137
|
-
0,
|
126
|
+
Command.create(
|
138
127
|
{
|
139
128
|
"account_id": cls.equity_account.id,
|
140
129
|
"name": "DEMO",
|
141
130
|
"debit": 50,
|
142
|
-
}
|
131
|
+
}
|
143
132
|
),
|
144
133
|
]
|
145
134
|
}
|
@@ -216,24 +205,20 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
216
205
|
move_1 = self.env["account.move"].create(
|
217
206
|
{
|
218
207
|
"line_ids": [
|
219
|
-
(
|
220
|
-
0,
|
221
|
-
0,
|
208
|
+
Command.create(
|
222
209
|
{
|
223
210
|
"account_id": self.current_assets_account.id,
|
224
211
|
"name": "DEMO",
|
225
212
|
"credit": 100,
|
226
|
-
}
|
213
|
+
}
|
227
214
|
),
|
228
|
-
(
|
229
|
-
0,
|
230
|
-
0,
|
215
|
+
Command.create(
|
231
216
|
{
|
232
217
|
"account_id": self.asset_receivable_account.id,
|
233
218
|
"partner_id": self.env.user.partner_id.id,
|
234
219
|
"name": "DEMO",
|
235
220
|
"debit": 100,
|
236
|
-
}
|
221
|
+
}
|
237
222
|
),
|
238
223
|
]
|
239
224
|
}
|
@@ -243,24 +228,20 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
243
228
|
move_2 = self.env["account.move"].create(
|
244
229
|
{
|
245
230
|
"line_ids": [
|
246
|
-
(
|
247
|
-
0,
|
248
|
-
0,
|
231
|
+
Command.create(
|
249
232
|
{
|
250
233
|
"account_id": self.current_assets_account.id,
|
251
234
|
"name": "DEMO",
|
252
235
|
"debit": 100,
|
253
|
-
}
|
236
|
+
}
|
254
237
|
),
|
255
|
-
(
|
256
|
-
0,
|
257
|
-
0,
|
238
|
+
Command.create(
|
258
239
|
{
|
259
240
|
"account_id": self.asset_receivable_account.id,
|
260
241
|
"partner_id": self.env.company.partner_id.id,
|
261
242
|
"name": "DEMO",
|
262
243
|
"credit": 100,
|
263
|
-
}
|
244
|
+
}
|
264
245
|
),
|
265
246
|
]
|
266
247
|
}
|
@@ -277,24 +258,20 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
277
258
|
move_3 = self.env["account.move"].create(
|
278
259
|
{
|
279
260
|
"line_ids": [
|
280
|
-
(
|
281
|
-
0,
|
282
|
-
0,
|
261
|
+
Command.create(
|
283
262
|
{
|
284
263
|
"account_id": self.current_assets_account.id,
|
285
264
|
"name": "DEMO",
|
286
265
|
"debit": 100,
|
287
|
-
}
|
266
|
+
}
|
288
267
|
),
|
289
|
-
(
|
290
|
-
0,
|
291
|
-
0,
|
268
|
+
Command.create(
|
292
269
|
{
|
293
270
|
"account_id": self.asset_receivable_account.id,
|
294
271
|
"partner_id": self.env.user.partner_id.id,
|
295
272
|
"name": "DEMO",
|
296
273
|
"credit": 100,
|
297
|
-
}
|
274
|
+
}
|
298
275
|
),
|
299
276
|
]
|
300
277
|
}
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import time
|
2
2
|
|
3
|
+
from odoo import Command
|
3
4
|
from odoo.tests import Form, tagged
|
4
5
|
|
5
6
|
from odoo.addons.account_reconcile_model_oca.tests.common import (
|
@@ -14,8 +15,8 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
14
15
|
return {**cls.env.context, "_test_account_reconcile_oca": True}
|
15
16
|
|
16
17
|
@classmethod
|
17
|
-
def setUpClass(cls
|
18
|
-
super().setUpClass(
|
18
|
+
def setUpClass(cls):
|
19
|
+
super().setUpClass()
|
19
20
|
cls.env = cls.env(context=cls._setup_context())
|
20
21
|
# Auto-disable reconciliation model created automatically with
|
21
22
|
# generate_account_reconcile_model() to avoid side effects in tests
|
@@ -39,7 +40,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
39
40
|
cls.current_assets_account = cls.env["account.account"].search(
|
40
41
|
[
|
41
42
|
("account_type", "=", "asset_current"),
|
42
|
-
("
|
43
|
+
("company_ids", "in", cls.env.company.id),
|
43
44
|
],
|
44
45
|
limit=1,
|
45
46
|
)
|
@@ -51,7 +52,9 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
51
52
|
"rule_type": "writeoff_button",
|
52
53
|
"match_partner": True,
|
53
54
|
"match_partner_ids": [],
|
54
|
-
"line_ids": [
|
55
|
+
"line_ids": [
|
56
|
+
Command.create({"account_id": cls.current_assets_account.id})
|
57
|
+
],
|
55
58
|
}
|
56
59
|
)
|
57
60
|
cls.tax_10 = cls.env["account.tax"].create(
|
@@ -190,7 +193,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
190
193
|
f.add_account_move_line_id = receivable1
|
191
194
|
self.assertFalse(f.add_account_move_line_id)
|
192
195
|
self.assertTrue(f.can_reconcile)
|
193
|
-
f.manual_reference = "account.move.line
|
196
|
+
f.manual_reference = f"account.move.line;{receivable1.id}"
|
194
197
|
self.assertEqual(-50, f.manual_amount)
|
195
198
|
self.assertEqual(2, len(bank_stmt_line.reconcile_data_info["data"]))
|
196
199
|
bank_stmt_line.button_manual_reference_full_paid()
|
@@ -199,7 +202,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
199
202
|
bank_stmt_line,
|
200
203
|
view="account_reconcile_oca.bank_statement_line_form_reconcile_view",
|
201
204
|
) as f:
|
202
|
-
f.manual_reference = "account.move.line
|
205
|
+
f.manual_reference = f"account.move.line;{receivable1.id}"
|
203
206
|
self.assertEqual(-100, f.manual_amount)
|
204
207
|
|
205
208
|
def test_reconcile_invoice_unreconcile(self):
|
@@ -303,12 +306,12 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
303
306
|
f.add_account_move_line_id = receivable1
|
304
307
|
self.assertFalse(f.add_account_move_line_id)
|
305
308
|
self.assertTrue(f.can_reconcile)
|
306
|
-
f.manual_reference = "account.move.line
|
309
|
+
f.manual_reference = f"account.move.line;{receivable1.id}"
|
307
310
|
self.assertEqual(f.manual_amount, -100)
|
308
311
|
f.manual_amount = -70
|
309
312
|
self.assertFalse(f.can_reconcile)
|
310
313
|
f.add_account_move_line_id = receivable2
|
311
|
-
f.manual_reference = "account.move.line
|
314
|
+
f.manual_reference = f"account.move.line;{receivable2.id}"
|
312
315
|
self.assertEqual(f.manual_amount, -30)
|
313
316
|
self.assertTrue(f.can_reconcile)
|
314
317
|
self.assertEqual(inv1.amount_residual_signed, 100)
|
@@ -366,12 +369,12 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
366
369
|
f.add_account_move_line_id = receivable1
|
367
370
|
self.assertFalse(f.add_account_move_line_id)
|
368
371
|
self.assertTrue(f.can_reconcile)
|
369
|
-
f.manual_reference = "account.move.line
|
372
|
+
f.manual_reference = f"account.move.line;{receivable1.id}"
|
370
373
|
self.assertEqual(f.manual_amount, 100)
|
371
374
|
f.manual_amount = 70
|
372
375
|
self.assertFalse(f.can_reconcile)
|
373
376
|
f.add_account_move_line_id = receivable2
|
374
|
-
f.manual_reference = "account.move.line
|
377
|
+
f.manual_reference = f"account.move.line;{receivable2.id}"
|
375
378
|
self.assertEqual(f.manual_amount, 30)
|
376
379
|
self.assertTrue(f.can_reconcile)
|
377
380
|
self.assertEqual(inv1.amount_residual_signed, -100)
|
@@ -430,7 +433,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
430
433
|
bank statement.
|
431
434
|
"""
|
432
435
|
self.rule.line_ids.write(
|
433
|
-
{"tax_ids": [(
|
436
|
+
{"tax_ids": [Command.link(self.tax_10.id)], "force_tax_included": True}
|
434
437
|
)
|
435
438
|
bank_stmt = self.acc_bank_stmt_model.create(
|
436
439
|
{
|
@@ -541,7 +544,9 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
541
544
|
"match_label": "contains",
|
542
545
|
"match_label_param": "DEMO WRITEOFF",
|
543
546
|
"auto_reconcile": True,
|
544
|
-
"line_ids": [
|
547
|
+
"line_ids": [
|
548
|
+
Command.create({"account_id": self.current_assets_account.id})
|
549
|
+
],
|
545
550
|
}
|
546
551
|
)
|
547
552
|
|
@@ -617,7 +622,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
617
622
|
.move_id
|
618
623
|
)
|
619
624
|
bank_stmt_line.unreconcile_bank_line()
|
620
|
-
self.assertTrue(reconcile_move.
|
625
|
+
self.assertTrue(reconcile_move.reversal_move_ids)
|
621
626
|
self.assertFalse(bank_stmt_line.is_reconciled)
|
622
627
|
|
623
628
|
def test_reconcile_model_with_foreign_currency(self):
|
@@ -709,13 +714,13 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
709
714
|
f.add_account_move_line_id = receivable1
|
710
715
|
self.assertTrue(f.can_reconcile)
|
711
716
|
self.assertFalse(bank_stmt_line.is_reconciled)
|
712
|
-
self.
|
717
|
+
self.assertTrue(bank_stmt_line.checked)
|
713
718
|
bank_stmt_line.action_to_check()
|
714
719
|
self.assertTrue(bank_stmt_line.is_reconciled)
|
715
|
-
self.
|
720
|
+
self.assertFalse(bank_stmt_line.checked)
|
716
721
|
bank_stmt_line.action_checked()
|
717
722
|
self.assertTrue(bank_stmt_line.is_reconciled)
|
718
|
-
self.
|
723
|
+
self.assertTrue(bank_stmt_line.checked)
|
719
724
|
|
720
725
|
def test_reconcile_invoice_to_check_not_reconciled(self):
|
721
726
|
"""
|
@@ -740,13 +745,13 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
740
745
|
}
|
741
746
|
)
|
742
747
|
self.assertFalse(bank_stmt_line.is_reconciled)
|
743
|
-
self.
|
748
|
+
self.assertTrue(bank_stmt_line.checked)
|
744
749
|
bank_stmt_line.action_to_check()
|
745
750
|
self.assertFalse(bank_stmt_line.is_reconciled)
|
746
|
-
self.
|
751
|
+
self.assertFalse(bank_stmt_line.checked)
|
747
752
|
bank_stmt_line.action_checked()
|
748
753
|
self.assertFalse(bank_stmt_line.is_reconciled)
|
749
|
-
self.
|
754
|
+
self.assertTrue(bank_stmt_line.checked)
|
750
755
|
|
751
756
|
# Testing widget
|
752
757
|
|
@@ -821,7 +826,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
821
826
|
f.add_account_move_line_id = receivable1
|
822
827
|
self.assertFalse(f.add_account_move_line_id)
|
823
828
|
self.assertTrue(f.can_reconcile)
|
824
|
-
f.manual_reference = "account.move.line
|
829
|
+
f.manual_reference = f"account.move.line;{receivable1.id}"
|
825
830
|
self.assertEqual(f.manual_amount, -100)
|
826
831
|
f.manual_delete = True
|
827
832
|
self.assertFalse(f.can_reconcile)
|
@@ -897,7 +902,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
897
902
|
) as f:
|
898
903
|
self.assertFalse(f.can_reconcile)
|
899
904
|
self.assertFalse(f.partner_id)
|
900
|
-
f.manual_reference = "account.move.line
|
905
|
+
f.manual_reference = f"account.move.line;{liquidity_lines.id}"
|
901
906
|
f.manual_partner_id = inv1.partner_id
|
902
907
|
f.save()
|
903
908
|
self.assertEqual(f.partner_id, inv1.partner_id)
|
@@ -1051,12 +1056,12 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
1051
1056
|
def test_partner_name_with_parent(self):
|
1052
1057
|
parent_partner = self.env["res.partner"].create(
|
1053
1058
|
{
|
1054
|
-
"name": "
|
1059
|
+
"name": "test_account_reconcile_oca",
|
1055
1060
|
}
|
1056
1061
|
)
|
1057
1062
|
child_partner = self.env["res.partner"].create(
|
1058
1063
|
{
|
1059
|
-
"name": "
|
1064
|
+
"name": "test_account_reconcile_oca",
|
1060
1065
|
"parent_id": parent_partner.id,
|
1061
1066
|
"type": "delivery",
|
1062
1067
|
}
|
@@ -1072,7 +1077,6 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
1072
1077
|
"name": "test",
|
1073
1078
|
}
|
1074
1079
|
)
|
1075
|
-
|
1076
1080
|
self.invoice_matching_models.active = True
|
1077
1081
|
self.invoice_matching_models.match_text_location_label = False
|
1078
1082
|
bank_stmt_line = self.acc_bank_stmt_line_model.create(
|
@@ -1083,10 +1087,9 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
1083
1087
|
"amount": 100,
|
1084
1088
|
"date": time.strftime("%Y-07-15"),
|
1085
1089
|
"payment_ref": "test",
|
1086
|
-
"partner_name": "
|
1090
|
+
"partner_name": "test_account_reconcile_oca",
|
1087
1091
|
}
|
1088
1092
|
)
|
1089
|
-
|
1090
1093
|
bkstmt_data = bank_stmt_line.reconcile_data_info
|
1091
1094
|
self.assertEqual(len(bkstmt_data["counterparts"]), 1)
|
1092
1095
|
self.assertEqual(
|
@@ -1368,7 +1371,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
1368
1371
|
)
|
1369
1372
|
# check that adding a partner does not recompute the amounts on accounting
|
1370
1373
|
# entries, but is still synchronized with accounting entries
|
1371
|
-
f.manual_reference = "account.move.line
|
1374
|
+
f.manual_reference = f"account.move.line;{liquidity_lines.id}"
|
1372
1375
|
f.manual_partner_id = inv1.partner_id
|
1373
1376
|
self.assertEqual(f.partner_id, inv1.partner_id)
|
1374
1377
|
self.assertEqual(liquidity_lines.debit, 83.33)
|
@@ -1377,7 +1380,7 @@ class TestReconciliationWidget(TestAccountReconciliationCommon):
|
|
1377
1380
|
# partner change
|
1378
1381
|
self.assertEqual(liquidity_lines.debit, 83.33)
|
1379
1382
|
self.assertEqual(liquidity_lines.partner_id, inv1.partner_id)
|
1380
|
-
f.manual_reference = "account.move.line
|
1383
|
+
f.manual_reference = f"account.move.line;{line['id']}"
|
1381
1384
|
# simulate click on statement line, check amount does not recompute
|
1382
1385
|
f.manual_partner_id = inv1.partner_id
|
1383
1386
|
self.assertEqual(f.manual_amount, 83.33)
|
@@ -2,13 +2,12 @@
|
|
2
2
|
<!-- Copyright 2023 Dixmit
|
3
3
|
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
|
4
4
|
<odoo>
|
5
|
-
|
6
5
|
<record model="ir.ui.view" id="view_account_list">
|
7
|
-
<field name="name">account.account.
|
6
|
+
<field name="name">account.account.list (in account_reconcile_oca)</field>
|
8
7
|
<field name="model">account.account</field>
|
9
8
|
<field name="inherit_id" ref="account.view_account_list" />
|
10
9
|
<field name="arch" type="xml">
|
11
|
-
<
|
10
|
+
<list position="inside">
|
12
11
|
<button
|
13
12
|
type="action"
|
14
13
|
name="%(account_reconcile_oca.account_account_account_account_reconcile_act_window)s"
|
@@ -16,8 +15,7 @@
|
|
16
15
|
class="float-end btn-secondary"
|
17
16
|
invisible="reconcile == False"
|
18
17
|
/>
|
19
|
-
</
|
18
|
+
</list>
|
20
19
|
</field>
|
21
20
|
</record>
|
22
|
-
|
23
21
|
</odoo>
|
@@ -2,7 +2,6 @@
|
|
2
2
|
<!-- Copyright 2023 Dixmit
|
3
3
|
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
|
4
4
|
<odoo>
|
5
|
-
|
6
5
|
<record model="ir.ui.view" id="account_account_reconcile_form_view">
|
7
6
|
<field
|
8
7
|
name="name"
|
@@ -36,7 +35,7 @@
|
|
36
35
|
<field name="is_reconciled" invisible="1" />
|
37
36
|
<group>
|
38
37
|
<group>
|
39
|
-
|
38
|
+
<field name="partner_id" />
|
40
39
|
</group>
|
41
40
|
<group>
|
42
41
|
<field name="account_id" />
|
@@ -58,7 +57,7 @@
|
|
58
57
|
name="add_account_move_line_id"
|
59
58
|
widget="account_reconcile_oca_match"
|
60
59
|
domain="[('parent_state', '=', 'posted'), ('amount_residual', '!=', 0), ('account_id', '=', account_id)]"
|
61
|
-
context="{'search_default_partner_id': partner_id, '
|
60
|
+
context="{'search_default_partner_id': partner_id, 'list_view_ref': 'account_reconcile_oca.account_move_line_tree_reconcile_view', 'search_view_ref': 'account_reconcile_oca.account_move_line_search_reconcile_view'}"
|
62
61
|
/>
|
63
62
|
</page>
|
64
63
|
</notebook>
|
@@ -82,15 +81,15 @@
|
|
82
81
|
<record model="ir.ui.view" id="account_account_reconcile_tree_view">
|
83
82
|
<field
|
84
83
|
name="name"
|
85
|
-
>account.account.reconcile.
|
84
|
+
>account.account.reconcile.list (in account_reconcile_oca)</field>
|
86
85
|
<field name="model">account.account.reconcile</field>
|
87
86
|
<field name="arch" type="xml">
|
88
|
-
<
|
87
|
+
<list>
|
89
88
|
<!-- TODO -->
|
90
89
|
<field name="id" />
|
91
90
|
<field name="account_id" />
|
92
91
|
<field name="partner_id" />
|
93
|
-
</
|
92
|
+
</list>
|
94
93
|
</field>
|
95
94
|
</record>
|
96
95
|
|
@@ -102,17 +101,12 @@
|
|
102
101
|
<field name="arch" type="xml">
|
103
102
|
<kanban js_class="reconcile">
|
104
103
|
<templates>
|
105
|
-
<t t-name="
|
106
|
-
<div
|
107
|
-
|
108
|
-
|
109
|
-
>
|
110
|
-
<
|
111
|
-
<field name="account_id" />
|
112
|
-
</div>
|
113
|
-
<div>
|
114
|
-
<field name="partner_id" />
|
115
|
-
</div>
|
104
|
+
<t t-name="card">
|
105
|
+
<div>
|
106
|
+
<field name="account_id" />
|
107
|
+
</div>
|
108
|
+
<div>
|
109
|
+
<field name="partner_id" />
|
116
110
|
</div>
|
117
111
|
</t>
|
118
112
|
</templates>
|
@@ -161,9 +155,8 @@
|
|
161
155
|
|
162
156
|
<record model="ir.ui.menu" id="account_account_reconcile_menu">
|
163
157
|
<field name="name">Reconcile</field>
|
164
|
-
<field name="parent_id" ref="account.
|
158
|
+
<field name="parent_id" ref="account.menu_finance_entries" />
|
165
159
|
<field name="action" ref="account_account_reconcile_act_window" />
|
166
|
-
<field name="sequence" eval="
|
160
|
+
<field name="sequence" eval="140" />
|
167
161
|
</record>
|
168
|
-
|
169
162
|
</odoo>
|
@@ -2,7 +2,6 @@
|
|
2
2
|
<!-- Copyright 2023 Dixmit
|
3
3
|
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
|
4
4
|
<odoo>
|
5
|
-
|
6
5
|
<record id="account_bank_statement_form_edit" model="ir.ui.view">
|
7
6
|
<field name="name">Edit Bank statement</field>
|
8
7
|
<field name="model">account.bank.statement</field>
|
@@ -27,7 +26,6 @@
|
|
27
26
|
<field name="line_ids" invisible="1" />
|
28
27
|
</group>
|
29
28
|
</sheet>
|
30
|
-
|
31
29
|
</form>
|
32
30
|
</field>
|
33
31
|
</record>
|