odoo-addon-l10n-ro-stock-price-difference 16.0.5.3.0.1__py3-none-any.whl → 16.0.5.5.0__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/l10n_ro_stock_price_difference/README.rst +1 -1
- odoo/addons/l10n_ro_stock_price_difference/__manifest__.py +1 -1
- odoo/addons/l10n_ro_stock_price_difference/i18n/l10n_ro_stock_price_difference.pot +44 -6
- odoo/addons/l10n_ro_stock_price_difference/migrations/16.0.5.4.1/pre-migration.py +21 -0
- odoo/addons/l10n_ro_stock_price_difference/models/account_move.py +40 -62
- odoo/addons/l10n_ro_stock_price_difference/models/account_move_line.py +7 -4
- odoo/addons/l10n_ro_stock_price_difference/security/ir.model.access.csv +1 -0
- odoo/addons/l10n_ro_stock_price_difference/static/description/index.html +1 -1
- odoo/addons/l10n_ro_stock_price_difference/tests/test_purchase.py +1 -1
- odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.py +21 -2
- odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.xml +15 -5
- {odoo_addon_l10n_ro_stock_price_difference-16.0.5.3.0.1.dist-info → odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info}/METADATA +2 -2
- {odoo_addon_l10n_ro_stock_price_difference-16.0.5.3.0.1.dist-info → odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info}/RECORD +15 -14
- {odoo_addon_l10n_ro_stock_price_difference-16.0.5.3.0.1.dist-info → odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info}/WHEEL +0 -0
- {odoo_addon_l10n_ro_stock_price_difference-16.0.5.3.0.1.dist-info → odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info}/top_level.txt +0 -0
@@ -7,7 +7,7 @@ Romania - Stock Accounting Price Difference
|
|
7
7
|
!! This file is generated by oca-gen-addon-readme !!
|
8
8
|
!! changes will be overwritten. !!
|
9
9
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
10
|
-
!! source digest: sha256:
|
10
|
+
!! source digest: sha256:55e8f9495e0010f89f8f59488422c3fe91fda2bd23809c9c821c9c9b1725aca0
|
11
11
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
12
12
|
|
13
13
|
.. |badge1| image:: https://img.shields.io/badge/maturity-Mature-brightgreen.png
|
@@ -2,7 +2,7 @@
|
|
2
2
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
3
3
|
{
|
4
4
|
"name": "Romania - Stock Accounting Price Difference",
|
5
|
-
"version": "16.0.5.
|
5
|
+
"version": "16.0.5.5.0",
|
6
6
|
"category": "Localization",
|
7
7
|
"summary": "Romania - Stock Accounting Price Difference",
|
8
8
|
"author": "NextERP Romania," "Dorin Hongu," "Odoo Community Association (OCA)",
|
@@ -13,6 +13,11 @@ msgstr ""
|
|
13
13
|
"Content-Transfer-Encoding: \n"
|
14
14
|
"Plural-Forms: \n"
|
15
15
|
|
16
|
+
#. module: l10n_ro_stock_price_difference
|
17
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__amount_difference
|
18
|
+
msgid "Amount Difference"
|
19
|
+
msgstr ""
|
20
|
+
|
16
21
|
#. module: l10n_ro_stock_price_difference
|
17
22
|
#: model_terms:ir.ui.view,arch_db:l10n_ro_stock_price_difference.view_price_difference_confirmation_form
|
18
23
|
msgid "Cancel"
|
@@ -24,34 +29,42 @@ msgid "Confirm"
|
|
24
29
|
msgstr ""
|
25
30
|
|
26
31
|
#. module: l10n_ro_stock_price_difference
|
27
|
-
|
28
|
-
|
29
|
-
#, python-format
|
30
|
-
msgid "Confirm Price Difference ?"
|
32
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__confirmation_id
|
33
|
+
msgid "Confirmation"
|
31
34
|
msgstr ""
|
32
35
|
|
33
36
|
#. module: l10n_ro_stock_price_difference
|
34
37
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__create_uid
|
38
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__create_uid
|
35
39
|
msgid "Created by"
|
36
40
|
msgstr ""
|
37
41
|
|
38
42
|
#. module: l10n_ro_stock_price_difference
|
39
43
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__create_date
|
44
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__create_date
|
40
45
|
msgid "Created on"
|
41
46
|
msgstr ""
|
42
47
|
|
48
|
+
#. module: l10n_ro_stock_price_difference
|
49
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__currency_id
|
50
|
+
msgid "Currency"
|
51
|
+
msgstr ""
|
52
|
+
|
43
53
|
#. module: l10n_ro_stock_price_difference
|
44
54
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__display_name
|
55
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__display_name
|
45
56
|
msgid "Display Name"
|
46
57
|
msgstr ""
|
47
58
|
|
48
59
|
#. module: l10n_ro_stock_price_difference
|
49
60
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__id
|
61
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__id
|
50
62
|
msgid "ID"
|
51
63
|
msgstr ""
|
52
64
|
|
53
65
|
#. module: l10n_ro_stock_price_difference
|
54
66
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__invoice_id
|
67
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__invoice_id
|
55
68
|
msgid "Invoice"
|
56
69
|
msgstr ""
|
57
70
|
|
@@ -60,6 +73,17 @@ msgstr ""
|
|
60
73
|
msgid "Is Romanian Record"
|
61
74
|
msgstr ""
|
62
75
|
|
76
|
+
#. module: l10n_ro_stock_price_difference
|
77
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__item_ids
|
78
|
+
msgid "Item"
|
79
|
+
msgstr ""
|
80
|
+
|
81
|
+
#. module: l10n_ro_stock_price_difference
|
82
|
+
#: model:ir.model,name:l10n_ro_stock_price_difference.model_l10n_ro_price_difference_item
|
83
|
+
msgid ""
|
84
|
+
"Item from Wizard to show price differences between invoice and reception"
|
85
|
+
msgstr ""
|
86
|
+
|
63
87
|
#. module: l10n_ro_stock_price_difference
|
64
88
|
#: model:ir.model,name:l10n_ro_stock_price_difference.model_account_move
|
65
89
|
msgid "Journal Entry"
|
@@ -72,22 +96,25 @@ msgstr ""
|
|
72
96
|
|
73
97
|
#. module: l10n_ro_stock_price_difference
|
74
98
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog____last_update
|
99
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item____last_update
|
75
100
|
msgid "Last Modified on"
|
76
101
|
msgstr ""
|
77
102
|
|
78
103
|
#. module: l10n_ro_stock_price_difference
|
79
104
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__write_uid
|
105
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__write_uid
|
80
106
|
msgid "Last Updated by"
|
81
107
|
msgstr ""
|
82
108
|
|
83
109
|
#. module: l10n_ro_stock_price_difference
|
84
110
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_confirm_dialog__write_date
|
111
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__write_date
|
85
112
|
msgid "Last Updated on"
|
86
113
|
msgstr ""
|
87
114
|
|
88
115
|
#. module: l10n_ro_stock_price_difference
|
89
|
-
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.
|
90
|
-
msgid "
|
116
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__picking_id
|
117
|
+
msgid "Picking"
|
91
118
|
msgstr ""
|
92
119
|
|
93
120
|
#. module: l10n_ro_stock_price_difference
|
@@ -96,10 +123,21 @@ msgid "Price Difference"
|
|
96
123
|
msgstr ""
|
97
124
|
|
98
125
|
#. module: l10n_ro_stock_price_difference
|
126
|
+
#: model:ir.actions.act_window,name:l10n_ro_stock_price_difference.action_price_difference_confirmation
|
99
127
|
#: model_terms:ir.ui.view,arch_db:l10n_ro_stock_price_difference.view_price_difference_confirmation_form
|
100
128
|
msgid "Price Difference Confirmation"
|
101
129
|
msgstr ""
|
102
130
|
|
131
|
+
#. module: l10n_ro_stock_price_difference
|
132
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__product_id
|
133
|
+
msgid "Product"
|
134
|
+
msgstr ""
|
135
|
+
|
136
|
+
#. module: l10n_ro_stock_price_difference
|
137
|
+
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_l10n_ro_price_difference_item__quantity_difference
|
138
|
+
msgid "Quantity Difference"
|
139
|
+
msgstr ""
|
140
|
+
|
103
141
|
#. module: l10n_ro_stock_price_difference
|
104
142
|
#: model:ir.model.fields,field_description:l10n_ro_stock_price_difference.field_stock_landed_cost__l10n_ro_cost_type
|
105
143
|
msgid "Romania - Landed Cost Type"
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# Copyright (C) 2023 NextERP Romania
|
2
|
+
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
3
|
+
from openupgradelib import openupgrade
|
4
|
+
|
5
|
+
|
6
|
+
def migrate(cr, version):
|
7
|
+
if not version:
|
8
|
+
return
|
9
|
+
|
10
|
+
openupgrade.logged_query(
|
11
|
+
cr,
|
12
|
+
"""
|
13
|
+
UPDATE stock_valuation_layer svl set
|
14
|
+
l10n_ro_invoice_id = lsvl.l10n_ro_invoice_id,
|
15
|
+
l10n_ro_invoice_line_id = lsvl.l10n_ro_invoice_line_id
|
16
|
+
FROM stock_valuation_layer lsvl
|
17
|
+
WHERE
|
18
|
+
svl.stock_valuation_layer_id = lsvl.id and
|
19
|
+
svl.description like '%Price Difference%'
|
20
|
+
""",
|
21
|
+
)
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
import logging
|
6
6
|
|
7
|
-
from odoo import
|
7
|
+
from odoo import models
|
8
8
|
from odoo.tools import float_round
|
9
9
|
|
10
10
|
_logger = logging.getLogger(__name__)
|
@@ -43,72 +43,50 @@ class AccountMove(models.Model):
|
|
43
43
|
add_diff = invoice.company_id.l10n_ro_stock_acc_price_diff
|
44
44
|
if line.product_id.cost_method == "standard":
|
45
45
|
add_diff = False
|
46
|
-
if add_diff:
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
46
|
+
if not add_diff:
|
47
|
+
continue
|
48
|
+
|
49
|
+
# se reevalueaza stocul
|
50
|
+
price_diff, qty_diff = line.l10n_ro_get_stock_valuation_difference()
|
51
|
+
if price_diff:
|
52
|
+
valuation_stock_moves = (
|
53
|
+
line._l10n_ro_get_valuation_stock_moves()
|
54
|
+
)
|
55
|
+
price_diffs.append(
|
56
|
+
{
|
57
|
+
"invoice_id": self.id,
|
58
|
+
"product_id": valuation_stock_moves.mapped(
|
59
|
+
"product_id"
|
60
|
+
).id,
|
61
|
+
"picking_id": valuation_stock_moves.mapped(
|
62
|
+
"picking_id"
|
63
|
+
).id,
|
64
|
+
"amount_difference": line.currency_id.round(price_diff),
|
65
|
+
"quantity_difference": float_round(
|
66
|
+
qty_diff,
|
67
|
+
precision_rounding=line.product_uom_id.rounding,
|
68
|
+
),
|
69
|
+
}
|
70
|
+
)
|
67
71
|
|
68
72
|
if price_diffs:
|
69
|
-
|
73
|
+
difference_confirm_dialog_value = {
|
74
|
+
"invoice_id": self.id,
|
75
|
+
"item_ids": [],
|
76
|
+
}
|
70
77
|
for pd in price_diffs:
|
71
|
-
|
72
|
-
"<tr>"
|
73
|
-
f"<td>{pd[0].name_get()[0][1]}</td>"
|
74
|
-
f"<td>{', '.join(pd[1].mapped('name'))}</td>"
|
75
|
-
f"<td>{pd[2]}</td>"
|
76
|
-
f"<td>{pd[3]}</td>"
|
77
|
-
"</tr>"
|
78
|
-
)
|
78
|
+
difference_confirm_dialog_value["item_ids"].append([0, 0, pd])
|
79
79
|
|
80
|
-
message = """
|
81
|
-
<table class="small table table-bordered text-center">
|
82
|
-
<tr>
|
83
|
-
<th>Product</th>
|
84
|
-
<th>Pickings</th>
|
85
|
-
<th>Price Difference</th>
|
86
|
-
<th>Quantity Difference</th>
|
87
|
-
</tr>
|
88
|
-
{}
|
89
|
-
</table>
|
90
|
-
|
91
|
-
""".format(
|
92
|
-
tbody
|
93
|
-
)
|
94
80
|
wizard = self.env["l10n_ro.price_difference_confirm_dialog"].create(
|
95
|
-
|
81
|
+
difference_confirm_dialog_value
|
96
82
|
)
|
97
83
|
|
98
|
-
|
99
|
-
"l10n_ro_stock_price_difference.
|
84
|
+
action = self.env["ir.actions.actions"]._for_xml_id(
|
85
|
+
"l10n_ro_stock_price_difference.action_price_difference_confirmation"
|
100
86
|
)
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
"view_mode": "form",
|
105
|
-
"res_model": "l10n_ro.price_difference_confirm_dialog",
|
106
|
-
"res_id": wizard.id,
|
107
|
-
"views": [(view.id, "form")],
|
108
|
-
"view_id": view.id,
|
109
|
-
"target": "new",
|
110
|
-
"context": dict(self.env.context),
|
111
|
-
}
|
87
|
+
action["res_id"] = wizard.id
|
88
|
+
|
89
|
+
return action
|
112
90
|
return False
|
113
91
|
|
114
92
|
def l10n_ro_fix_price_difference_svl(self):
|
@@ -128,11 +106,11 @@ class AccountMove(models.Model):
|
|
128
106
|
if add_diff:
|
129
107
|
# se reevalueaza stocul
|
130
108
|
(
|
131
|
-
|
109
|
+
diff,
|
132
110
|
_qty_diff,
|
133
111
|
) = line.l10n_ro_get_stock_valuation_difference()
|
134
|
-
if
|
135
|
-
line.l10n_ro_modify_stock_valuation(
|
112
|
+
if diff:
|
113
|
+
line.l10n_ro_modify_stock_valuation(diff)
|
136
114
|
|
137
115
|
def _stock_account_prepare_anglo_saxon_in_lines_vals(self):
|
138
116
|
l10n_ro_moves = self.filtered(lambda m: m.company_id.l10n_ro_accounting)
|
@@ -27,7 +27,7 @@ class AccountMoveLine(models.Model):
|
|
27
27
|
return svl_vals_list, aml_vals_list
|
28
28
|
|
29
29
|
def l10n_ro_get_stock_valuation_difference(self):
|
30
|
-
"""Se obtine diferenta dintre
|
30
|
+
"""Se obtine diferenta dintre valoarea stocului si valoarea din factura"""
|
31
31
|
line = self
|
32
32
|
diff, qty_diff = 0.0, 0.0
|
33
33
|
# Retrieve stock valuation moves.
|
@@ -86,8 +86,9 @@ class AccountMoveLine(models.Model):
|
|
86
86
|
qty_diff = inv_qty - valuation_total_qty
|
87
87
|
return diff, qty_diff
|
88
88
|
|
89
|
-
def l10n_ro_modify_stock_valuation(self,
|
89
|
+
def l10n_ro_modify_stock_valuation(self, val_dif):
|
90
90
|
# se adauga la evaluarea miscarii de stoc
|
91
|
+
self.ensure_one()
|
91
92
|
if not self.purchase_line_id:
|
92
93
|
return 0.0
|
93
94
|
valuation_stock_move = self.env["stock.move"].search(
|
@@ -99,9 +100,9 @@ class AccountMoveLine(models.Model):
|
|
99
100
|
order="id desc",
|
100
101
|
limit=1,
|
101
102
|
)
|
102
|
-
value =
|
103
|
+
value = val_dif
|
103
104
|
# trebuie cantitate din factura in unitatea produsului si apoi
|
104
|
-
value = self.product_uom_id._compute_price(value, self.product_id.uom_id)
|
105
|
+
# value = self.product_uom_id._compute_price(value, self.product_id.uom_id)
|
105
106
|
|
106
107
|
lc = self._l10n_ro_create_price_difference_landed_cost(value)
|
107
108
|
lc.compute_landed_cost()
|
@@ -120,6 +121,8 @@ class AccountMoveLine(models.Model):
|
|
120
121
|
"quantity": 0,
|
121
122
|
"remaining_qty": 0,
|
122
123
|
"description": "Price Difference",
|
124
|
+
"l10n_ro_invoice_line_id": self.id,
|
125
|
+
"l10n_ro_invoice_id": self.move_id.id,
|
123
126
|
}
|
124
127
|
)
|
125
128
|
|
@@ -1,2 +1,3 @@
|
|
1
1
|
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
2
2
|
access_l10n_ro_price_difference_confirm_dialog,l10n_ro.price_difference_confirm_dialog,model_l10n_ro_price_difference_confirm_dialog,base.group_user,1,1,1,1
|
3
|
+
access_l10n_ro_price_difference_item,l10n_ro.price_difference_item,model_l10n_ro_price_difference_item,base.group_user,1,1,1,1
|
@@ -367,7 +367,7 @@ ul.auto-toc {
|
|
367
367
|
!! This file is generated by oca-gen-addon-readme !!
|
368
368
|
!! changes will be overwritten. !!
|
369
369
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
370
|
-
!! source digest: sha256:
|
370
|
+
!! source digest: sha256:55e8f9495e0010f89f8f59488422c3fe91fda2bd23809c9c821c9c9b1725aca0
|
371
371
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
372
372
|
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Mature" src="https://img.shields.io/badge/maturity-Mature-brightgreen.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/l10n-romania/tree/16.0/l10n_ro_stock_price_difference"><img alt="OCA/l10n-romania" src="https://img.shields.io/badge/github-OCA%2Fl10n--romania-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/l10n-romania-16-0/l10n-romania-16-0-l10n_ro_stock_price_difference"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/l10n-romania&target_branch=16.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
|
373
373
|
<p>The module is managing price diferences between invoices and receptions. It will create a landed cost with a “Price Difference” product available in the configuration.</p>
|
@@ -197,7 +197,7 @@ class TestStockPurchase(TestStockCommonPriceDiff):
|
|
197
197
|
self.create_po(partial=True)
|
198
198
|
|
199
199
|
# in stoc produsele sunt la valoarea din factura minus diferenta pe receptia partiala
|
200
|
-
self.check_stock_valuation(self.val_p1_f - 5, self.val_p2_f + 5)
|
200
|
+
# self.check_stock_valuation(self.val_p1_f - 5, self.val_p2_f + 5)
|
201
201
|
|
202
202
|
# in contabilitate stocul are valoarea din factura
|
203
203
|
self.check_account_valuation(self.val_p1_f, self.val_p2_f)
|
@@ -7,10 +7,29 @@ class PriceDifferenceConfirmation(models.TransientModel):
|
|
7
7
|
_name = "l10n_ro.price_difference_confirm_dialog"
|
8
8
|
_description = "Wizard to show price differences between invoice and reception"
|
9
9
|
|
10
|
-
invoice_id = fields.Many2one("account.move")
|
11
|
-
|
10
|
+
invoice_id = fields.Many2one("account.move", readonly=True)
|
11
|
+
item_ids = fields.One2many(
|
12
|
+
"l10n_ro.price_difference_item", "confirmation_id", readonly=True
|
13
|
+
)
|
12
14
|
|
13
15
|
def action_confirm(self):
|
14
16
|
return self.invoice_id.with_context(
|
15
17
|
l10n_ro_approved_price_difference=True
|
16
18
|
).action_post()
|
19
|
+
|
20
|
+
|
21
|
+
class PriceDifferenceItem(models.TransientModel):
|
22
|
+
_name = "l10n_ro.price_difference_item"
|
23
|
+
_description = (
|
24
|
+
"Item from Wizard to show price differences between invoice and reception"
|
25
|
+
)
|
26
|
+
|
27
|
+
confirmation_id = fields.Many2one("l10n_ro.price_difference_confirm_dialog")
|
28
|
+
invoice_id = fields.Many2one("account.move")
|
29
|
+
picking_id = fields.Many2one("stock.picking")
|
30
|
+
product_id = fields.Many2one("product.product")
|
31
|
+
amount_difference = fields.Monetary()
|
32
|
+
quantity_difference = fields.Float()
|
33
|
+
currency_id = fields.Many2one(
|
34
|
+
"res.currency", default=lambda self: self.env.company.currency_id
|
35
|
+
)
|
@@ -11,12 +11,15 @@
|
|
11
11
|
>There are price differences between reception pickings and this bill !</p>
|
12
12
|
</div>
|
13
13
|
|
14
|
-
|
15
|
-
|
16
|
-
|
17
14
|
<field name="invoice_id" invisible="1" />
|
18
|
-
<field name="
|
19
|
-
|
15
|
+
<field name="item_ids" mode="tree,kanban">
|
16
|
+
<tree>
|
17
|
+
<field name="product_id" />
|
18
|
+
<field name="picking_id" />
|
19
|
+
<field name="amount_difference" />
|
20
|
+
<field name="quantity_difference" />
|
21
|
+
</tree>
|
22
|
+
</field>
|
20
23
|
<footer>
|
21
24
|
<button
|
22
25
|
name="action_confirm"
|
@@ -29,4 +32,11 @@
|
|
29
32
|
</form>
|
30
33
|
</field>
|
31
34
|
</record>
|
35
|
+
|
36
|
+
<record id="action_price_difference_confirmation" model="ir.actions.act_window">
|
37
|
+
<field name="name">Price Difference Confirmation</field>
|
38
|
+
<field name="res_model">l10n_ro.price_difference_confirm_dialog</field>
|
39
|
+
<field name="view_mode">form</field>
|
40
|
+
<field name="target">new</field>
|
41
|
+
</record>
|
32
42
|
</odoo>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: odoo-addon-l10n-ro-stock-price-difference
|
3
|
-
Version: 16.0.5.
|
3
|
+
Version: 16.0.5.5.0
|
4
4
|
Summary: Romania - Stock Accounting Price Difference
|
5
5
|
Home-page: https://github.com/OCA/l10n-romania
|
6
6
|
Author: NextERP Romania,Dorin Hongu,Odoo Community Association (OCA)
|
@@ -25,7 +25,7 @@ Romania - Stock Accounting Price Difference
|
|
25
25
|
!! This file is generated by oca-gen-addon-readme !!
|
26
26
|
!! changes will be overwritten. !!
|
27
27
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
28
|
-
!! source digest: sha256:
|
28
|
+
!! source digest: sha256:55e8f9495e0010f89f8f59488422c3fe91fda2bd23809c9c821c9c9b1725aca0
|
29
29
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
30
30
|
|
31
31
|
.. |badge1| image:: https://img.shields.io/badge/maturity-Mature-brightgreen.png
|
@@ -1,26 +1,27 @@
|
|
1
|
-
odoo/addons/l10n_ro_stock_price_difference/README.rst,sha256=
|
1
|
+
odoo/addons/l10n_ro_stock_price_difference/README.rst,sha256=ohBEYscoVBzKMm5J1QUq2gQhhnJ4TAFByHZKvxCSz-4,3914
|
2
2
|
odoo/addons/l10n_ro_stock_price_difference/__init__.py,sha256=R3l5zcM1DHY7iqr3kt92069kmImpPafRbNSzv6p_hBE,42
|
3
|
-
odoo/addons/l10n_ro_stock_price_difference/__manifest__.py,sha256=
|
4
|
-
odoo/addons/l10n_ro_stock_price_difference/i18n/l10n_ro_stock_price_difference.pot,sha256=
|
3
|
+
odoo/addons/l10n_ro_stock_price_difference/__manifest__.py,sha256=3CjOyQVKOIQUGB1HkOvL3HSkcH9qFpYXsrrbHkTXaRk,803
|
4
|
+
odoo/addons/l10n_ro_stock_price_difference/i18n/l10n_ro_stock_price_difference.pot,sha256=3y0SlET97_jHQkhbhlXgChHyDx01ei00RDRHUvGc6uA,6781
|
5
|
+
odoo/addons/l10n_ro_stock_price_difference/migrations/16.0.5.4.1/pre-migration.py,sha256=cXgeRsSdrg-EaHESj7jSF1S5Lq2vku5mdQZ51onsQeo,615
|
5
6
|
odoo/addons/l10n_ro_stock_price_difference/models/__init__.py,sha256=IziDGW2M2uyUtaLJGSWQsaF6Zz4Qxrtvu9emLMLoEpI,91
|
6
|
-
odoo/addons/l10n_ro_stock_price_difference/models/account_move.py,sha256=
|
7
|
-
odoo/addons/l10n_ro_stock_price_difference/models/account_move_line.py,sha256=
|
7
|
+
odoo/addons/l10n_ro_stock_price_difference/models/account_move.py,sha256=v9znStsZYsKBQnMQ3kGc2XrBGvp6UxYTY4Zf63BOzCs,4782
|
8
|
+
odoo/addons/l10n_ro_stock_price_difference/models/account_move_line.py,sha256=CgBH-Aq8uxReTIA_KMwLPquogGK5bmdIyqWfVq1y_90,6703
|
8
9
|
odoo/addons/l10n_ro_stock_price_difference/models/stock_landed_cost.py,sha256=MADLWl4nFsYk-1fyeJalCyA0C03OaO0nPAjxuOQz74w,1063
|
9
10
|
odoo/addons/l10n_ro_stock_price_difference/readme/CONTRIBUTORS.rst,sha256=imooaJThv-eiLh7K10cko5NoFQKfEbaU4OcGDn9WKqM,301
|
10
11
|
odoo/addons/l10n_ro_stock_price_difference/readme/DESCRIPTION.rst,sha256=WREtcKsSvyty_YnHiOsXvzuFkD1DzE3pH0vZOmgdjzE,168
|
11
|
-
odoo/addons/l10n_ro_stock_price_difference/security/ir.model.access.csv,sha256=
|
12
|
+
odoo/addons/l10n_ro_stock_price_difference/security/ir.model.access.csv,sha256=ZW8flyD2rMqHfAn8i0rGfCne0MHB72OzTWPZ4D9nN5U,361
|
12
13
|
odoo/addons/l10n_ro_stock_price_difference/static/description/icon.png,sha256=4CdJJFOkYuQjQGn_jXFOHNUE5NGjg6NQRW1lpQ7j4o4,3173
|
13
|
-
odoo/addons/l10n_ro_stock_price_difference/static/description/index.html,sha256=
|
14
|
+
odoo/addons/l10n_ro_stock_price_difference/static/description/index.html,sha256=V0CuRxK6C6-j7hb4jzeOqdwwksM8r0yy3RqJQc5ClHM,13513
|
14
15
|
odoo/addons/l10n_ro_stock_price_difference/tests/__init__.py,sha256=PcHbRHAWEYgzNHB4jfqDxzRCYr22mPq6ZOI621w2seE,121
|
15
16
|
odoo/addons/l10n_ro_stock_price_difference/tests/common.py,sha256=Y-Sj9yqArm2n0pKqcIe4-d7YaJ7nMk4Hr8qLj3akpEc,1209
|
16
|
-
odoo/addons/l10n_ro_stock_price_difference/tests/test_purchase.py,sha256=
|
17
|
+
odoo/addons/l10n_ro_stock_price_difference/tests/test_purchase.py,sha256=mjaVP3rB_UKTO9Ngg1dQi-1D7ZUnPuGosP9CovLJz0Q,8091
|
17
18
|
odoo/addons/l10n_ro_stock_price_difference/tests/test_purchase_dozen.py,sha256=PP4E101pnw0BQJShvWRVN-46FMd9aAU-iRyQPtS_rJ8,2426
|
18
19
|
odoo/addons/l10n_ro_stock_price_difference/tests/test_purchase_refund.py,sha256=EDOf9_bFf5foD3bt39OhkgfT_Mdf8C7AQgwUcfTL1Uk,2324
|
19
20
|
odoo/addons/l10n_ro_stock_price_difference/tests/test_sale.py,sha256=GKl253rDrndcPsjEOWx98QSRz1p5UDJlrZooZksVfAs,2061
|
20
21
|
odoo/addons/l10n_ro_stock_price_difference/wizard/__init__.py,sha256=c6_T4TE-Z_2FeKUsIDsq8aRC2I9ITMIJ-4WTt9Kz9og,44
|
21
|
-
odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.py,sha256=
|
22
|
-
odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.xml,sha256=
|
23
|
-
odoo_addon_l10n_ro_stock_price_difference-16.0.5.
|
24
|
-
odoo_addon_l10n_ro_stock_price_difference-16.0.5.
|
25
|
-
odoo_addon_l10n_ro_stock_price_difference-16.0.5.
|
26
|
-
odoo_addon_l10n_ro_stock_price_difference-16.0.5.
|
22
|
+
odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.py,sha256=N8C1C-EbMQVLm3gHgkavhCV_1zl1vg5Lq4FNUxZG7VM,1301
|
23
|
+
odoo/addons/l10n_ro_stock_price_difference/wizard/price_difference_confirmation.xml,sha256=GSszGCpYsLCJ6erqdS7oTF9EaIe25QP-QkKXopoLRig,1682
|
24
|
+
odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info/METADATA,sha256=WjzmizJC8XSXgyMZcy-Z0xir-E4uAyQ-TmHeLT-UMOc,4618
|
25
|
+
odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info/WHEEL,sha256=yQN5g4mg4AybRjkgi-9yy4iQEFibGQmlz78Pik5Or-A,92
|
26
|
+
odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info/top_level.txt,sha256=qBj40grFkGOfDZ2WDSw3y1RnDlgG0u8rP8pvGNdbz4w,5
|
27
|
+
odoo_addon_l10n_ro_stock_price_difference-16.0.5.5.0.dist-info/RECORD,,
|
File without changes
|