-
-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[IMP] repair_picking_after_done: Implement auto-transfer functionalit…
…y for completed repair orders
- Loading branch information
Showing
12 changed files
with
182 additions
and
34 deletions.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
from . import repair | ||
from . import res_config_settings |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Copyright 2024 Patryk Pyczko (APSL-Nagarro)<ppyczko@apsl.net> | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import fields, models | ||
|
||
|
||
class ResConfigSettings(models.TransientModel): | ||
_inherit = "res.config.settings" | ||
|
||
auto_transfer_repair = fields.Boolean( | ||
"Automatic Transfer on Repair Completion", | ||
config_parameter="repair.auto_transfer_repair", | ||
help="Automatically create and validate transfers for " | ||
"repair orders upon completion.", | ||
) |
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 +1,6 @@ | ||
No configuration needed for this module. | ||
To enable automatic transfers for repaired products when a repair order is completed: | ||
|
||
- Navigate to Repairs → Configuration → Settings. | ||
- Enable the **Automatic Transfer on Repair Completion** setting. | ||
|
||
When enabled, internal transfers for repaired products are automatically created and validated upon completing the repair order. |
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,2 +1,4 @@ | ||
This module adds the functionality to create transfer of repaired move | ||
once repair order is done. | ||
This module enhances Odoo's repair process by introducing automatic stock transfers for repaired products. | ||
|
||
- **Automatic Transfer:** When a repair order is marked as done, a stock transfer for the remaining repaired products is automatically created and validated if the ***auto_transfer_repair*** parameter is enabled. | ||
- **Manual Transfer:** Users can manually create stock transfers when automatic transfer is disabled. |
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,9 @@ | ||
After repair order is done, You will be able to see button "Transfer" on | ||
repair order's form view. You will be able to create internal transfer | ||
between repair location to any destination location. | ||
**Manual Transfers** | ||
|
||
1. After a repair order is marked as **Done**, a **Create Transfer** button will appear on the repair order's form view. | ||
2. Click the Create Transfer button to create an internal transfer for the repaired products. | ||
3. Specify the destination location and quantity to complete the transfer. | ||
|
||
**Automatic Transfers** | ||
|
||
1. If the ***auto_transfer_repair*** configuration parameter is enabled, an internal transfer is automatically created and validated when the repair order is marked as **Done**. |
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
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
20 changes: 20 additions & 0 deletions
20
repair_picking_after_done/views/res_config_settings_views.xml
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,20 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<odoo> | ||
|
||
<record id="res_config_settings_view_form_inherit" model="ir.ui.view"> | ||
<field name="name">res.config.settings.view.form.inherit.repair</field> | ||
<field name="model">res.config.settings</field> | ||
<field name="inherit_id" ref="base_repair_config.res_config_settings_view_form" /> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//block[@name='repair_setting_container']" position="inside"> | ||
<setting | ||
id="auto_transfer_repair_setting" | ||
help="Automatically create and validate stock transfers for completed repair orders." | ||
> | ||
<field name="auto_transfer_repair" /> | ||
</setting> | ||
</xpath> | ||
</field> | ||
</record> | ||
|
||
</odoo> |