diff --git a/account_move_line_stock_info/README.rst b/account_move_line_stock_info/README.rst index 9423fd625..b0021ad3f 100644 --- a/account_move_line_stock_info/README.rst +++ b/account_move_line_stock_info/README.rst @@ -12,12 +12,12 @@ This module adds the stock move to the account move lines that it generates. Usage ===== -* The stock manager can check the journal items generated by a stock - move, by accessing to the picking, then clicking on one of the moves, to - display the list of journal items. +* The stock manager can check the journal items by accessing to 'Inventory > +Reports > Stock moves'. -* An accounting user or manager can review the details of a move that is - associated to a journal item that she/he is checking. +* A user belonging to the group 'Accounting & Finance/Adviser' can review the + details of a move that is associated to a journal item through + 'Invoicing > Adviser > Journal Entries (or Journal items)'. .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas :alt: Try me on Runbot diff --git a/account_move_line_stock_info/__openerp__.py b/account_move_line_stock_info/__openerp__.py index 582675405..ae3e3dc74 100644 --- a/account_move_line_stock_info/__openerp__.py +++ b/account_move_line_stock_info/__openerp__.py @@ -3,7 +3,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). { "name": "Account Move Line Stock Move", - "version": "8.0.1.0.0", + "version": "9.0.1.0.0", "depends": [ "stock_account" ], diff --git a/account_move_line_stock_info/tests/test_account_move_line_stock_move.py b/account_move_line_stock_info/tests/test_account_move_line_stock_move.py index 6a10210d8..67244a18c 100644 --- a/account_move_line_stock_info/tests/test_account_move_line_stock_move.py +++ b/account_move_line_stock_info/tests/test_account_move_line_stock_move.py @@ -32,20 +32,20 @@ class TestAccountMoveLineStockInfo(common.TransactionCase): 'account.group_account_manager') # Create account for Goods Received Not Invoiced - acc_type = 'equity' + acc_type = self._create_account_type('equity', 'other') name = 'Goods Received Not Invoiced' code = 'grni' self.account_grni = self._create_account(acc_type, name, code, self.company) # Create account for Cost of Goods Sold - acc_type = 'expense' + acc_type = self._create_account_type('expense', 'other') name = 'Cost of Goods Sold' code = 'cogs' self.account_cogs = self._create_account(acc_type, name, code, self.company) # Create account for Inventory - acc_type = 'asset' + acc_type = self._create_account_type('asset', 'other') name = 'Inventory' code = 'inventory' self.account_inventory = self._create_account(acc_type, name, code, @@ -82,14 +82,20 @@ class TestAccountMoveLineStockInfo(common.TransactionCase): }) return user.id + def _create_account_type(self, name, type): + acc_type = self.acc_type_model.create({ + 'name': name, + 'type': type + }) + return acc_type + def _create_account(self, acc_type, name, code, company): """Create an account.""" - types = self.acc_type_model.search([('code', '=', acc_type)]) account = self.account_model.create({ 'name': name, 'code': code, 'type': 'other', - 'user_type': types and types[0].id, + 'user_type_id': acc_type.id, 'company_id': company.id }) return account diff --git a/account_move_line_stock_info/views/account_move_line_view.xml b/account_move_line_stock_info/views/account_move_line_view.xml index 6688a82b0..161fee8c8 100644 --- a/account_move_line_stock_info/views/account_move_line_view.xml +++ b/account_move_line_stock_info/views/account_move_line_view.xml @@ -1,6 +1,5 @@ - - + account.move.line.form @@ -24,5 +23,4 @@ - - + diff --git a/account_move_line_stock_info/views/stock_move_view.xml b/account_move_line_stock_info/views/stock_move_view.xml index 4a86707fd..f472a4412 100644 --- a/account_move_line_stock_info/views/stock_move_view.xml +++ b/account_move_line_stock_info/views/stock_move_view.xml @@ -1,6 +1,5 @@ - - + stock.move.form @@ -33,5 +32,4 @@ - - +