Skip to content

Commit

Permalink
[MIG] purchase_order_move_menu: Migration to 14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristianSantamaria committed Sep 6, 2023
1 parent b003bd3 commit 460c47f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 12 deletions.
2 changes: 1 addition & 1 deletion purchase_order_move_menu/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
""",
"author": "Solvos",
"license": "LGPL-3",
"version": "13.0.2.0.1",
"version": "14.0.2.0.1",
"category": "Operations/Purchase",
"website": "https://github.com/solvosci/slv-purchase",
"depends": ["purchase_stock"],
Expand Down
6 changes: 3 additions & 3 deletions purchase_order_move_menu/i18n/es.po
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ msgstr "Agrupar por"
#. module: purchase_order_move_menu
#: model_terms:ir.ui.view,arch_db:purchase_order_move_menu.stock_move_po_move_menu_search
msgid "Location Orig"
msgstr "Ubicaci??n Origen"
msgstr "Ubicación Origen"

#. module: purchase_order_move_menu
#: model:ir.model.fields,field_description:purchase_order_move_menu.field_stock_move__purchase_order
Expand All @@ -50,7 +50,7 @@ msgstr "Ref. pedido"
#. module: purchase_order_move_menu
#: model_terms:ir.ui.view,arch_db:purchase_order_move_menu.stock_move_po_move_menu_search
msgid "Picking"
msgstr "Albar??n"
msgstr "Albarán"

#. module: purchase_order_move_menu
#: model_terms:ir.ui.view,arch_db:purchase_order_move_menu.stock_move_po_move_menu_search
Expand All @@ -60,7 +60,7 @@ msgstr "Producto"
#. module: purchase_order_move_menu
#: model:ir.model.fields,field_description:purchase_order_move_menu.field_stock_move__po_product_categ_id
msgid "Product Category"
msgstr "Categor??a de producto"
msgstr "Categoría de producto"

#. module: purchase_order_move_menu
#: model:ir.actions.act_window,name:purchase_order_move_menu.action_stock_move_po_move_menu
Expand Down
9 changes: 1 addition & 8 deletions purchase_order_move_menu/models/stock_move.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,9 @@ def action_purchase_moves(self):
Modifies original purchase stock move action depending on Purchase
role of the logged user
"""
# Alternative development: making our own action from scatch, like
# https://github.com/odoo/odoo/blob/13.0/addons/stock/models/stock_quant.py#L622
# The selected strategy allow us to define action in XML file,
# but has the problem of the needed "fake zero results domain" in
# order to prevent "F5" pages reload, that should only use the
# original action definition
action = self.env.ref(
result = self.env["ir.actions.act_window"]._for_xml_id(
"purchase_order_move_menu.action_stock_move_po_move_menu"
)
result = action.read()[0]
# Default (fake) domain is replaced with the right one
domain_str = "('purchase_line_id','!=', False), ('state','=', 'done')"
if not self._check_purchase_all_permissions(self.env.user):
Expand Down

0 comments on commit 460c47f

Please sign in to comment.