-
-
Notifications
You must be signed in to change notification settings - Fork 486
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[IMP] mrp_stock_owner_restriction: add handling of umbuild orders
- Loading branch information
1 parent
0136449
commit 83a43c3
Showing
5 changed files
with
79 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * mrp_stock_owner_restriction | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 16.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2023-04-12 07:13+0000\n" | ||
"PO-Revision-Date: 2023-04-12 07:13+0000\n" | ||
"Last-Translator: \n" | ||
"Language-Team: \n" | ||
"MIME-Version: 1.0\n" | ||
"Content-Type: text/plain; charset=UTF-8\n" | ||
"Content-Transfer-Encoding: \n" | ||
"Plural-Forms: \n" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model.fields,field_description:mrp_stock_owner_restriction.field_mrp_production__owner_id | ||
msgid "Assign Owner" | ||
msgstr "オーナー割当" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model.fields,field_description:mrp_stock_owner_restriction.field_mrp_production__owner_restriction | ||
msgid "Owner Restriction" | ||
msgstr "オーナー制限" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model.fields,help:mrp_stock_owner_restriction.field_mrp_production__owner_id | ||
msgid "Produced products will be assigned to this owner." | ||
msgstr "生産された製品は、このオーナーに割り当てられます。" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model,name:mrp_stock_owner_restriction.model_stock_move_line | ||
msgid "Product Moves (Stock Move Line)" | ||
msgstr "製品の移動(在庫移動ライン)" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model,name:mrp_stock_owner_restriction.model_mrp_production | ||
msgid "Production Order" | ||
msgstr "製造オーダ" | ||
|
||
#. module: mrp_stock_owner_restriction | ||
#: model:ir.model,name:mrp_stock_owner_restriction.model_stock_move | ||
msgid "Stock Move" | ||
msgstr "在庫移動" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from . import mrp_production | ||
from . import mrp_unbuild | ||
from . import stock_move_line | ||
from . import stock_move |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Copyright 2023 Quartile Limited | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import models | ||
|
||
|
||
class MrpUnbuild(models.Model): | ||
_inherit = "mrp.unbuild" | ||
|
||
def action_validate(self): | ||
owner_restriction = self.mo_id.picking_type_id.owner_restriction | ||
owner = self.mo_id.owner_id | ||
if owner and owner_restriction != "standard_behavior": | ||
self = self.with_context(force_restricted_owner_id=owner) | ||
return super().action_validate() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters