Skip to content

Commit

Permalink
[MIG] customaddons migrated to v13
Browse files Browse the repository at this point in the history
  • Loading branch information
yibudak committed Oct 1, 2024
1 parent 6b7b537 commit 7ed2c22
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion altinkaya_stock_lot/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
{
"name": "Altinkaya Stock Lot Extensions",
"summary": "Adds custom fields to stock.production.lot",
"version": "12.0.1.0.0",
"version": "13.0.1.0.0",
"category": "stock",
"website": "https://github.com/yibudak",
"author": "Yiğit Budak",
Expand Down
2 changes: 1 addition & 1 deletion altinkaya_stock_lot/models/stock_inventory.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
class StockInventory(models.Model):
_inherit = "stock.inventory"

@api.multi

def action_validate(self):
return super(StockInventory, self).action_validate()
2 changes: 1 addition & 1 deletion altinkaya_stock_lot/models/stock_inventory_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
class InventoryLine(models.Model):
_inherit = "stock.inventory.line"

@api.multi

def _create_missing_lot(self):
"""EXPERIMENTAL: Create a lot for the move line if it is missing."""
for rec in self:
Expand Down
2 changes: 1 addition & 1 deletion altinkaya_stock_lot/models/stock_move_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
class StockMoveLine(models.Model):
_inherit = "stock.move.line"

@api.multi

def _create_missing_lot(self):
"""EXPERIMENTAL: Create a lot for the move line if it is missing."""
for rec in self:
Expand Down
2 changes: 1 addition & 1 deletion altinkaya_stock_lot/models/stock_picking.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
class StockPickin(models.Model):
_inherit = "stock.picking"

# @api.multi
#
# def button_validate(self):
# """Overridden to create lot_id for move_lines automatically"""
# picking_type = self.picking_type_id
Expand Down
4 changes: 2 additions & 2 deletions altinkaya_stock_lot/wizards/mrp_product_produce.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
class MrpProductProduce(models.TransientModel):
_inherit = "mrp.product.produce"

@api.multi

def do_produce(self):
"""Override do_produce method on MRP to generate lot_id automatically"""
if any(
Expand Down Expand Up @@ -59,6 +59,6 @@ class MrpProductProduceLine(models.TransientModel):
location_src_id = fields.Many2one(
"stock.location",
"Raw Materials Location",
related="product_produce_id.production_id.location_src_id",
related="raw_product_produce_id.production_id.location_src_id",
readonly=True,
)
4 changes: 2 additions & 2 deletions altinkaya_stock_lot/wizards/mrp_product_produce_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
<attribute name="attrs">{'invisible': True, 'required': False}</attribute>
</field>

<xpath expr="//field[@name='produce_line_ids']/tree/field[@name='product_tracking']" position="after">
<xpath expr="//field[@name='raw_workorder_line_ids']/tree/field[@name='product_tracking']" position="after">
<field name="location_src_id" invisible="1"/>
</xpath>

<xpath expr="//field[@name='produce_line_ids']/tree/field[@name='lot_id']" position="attributes">
<xpath expr="//field[@name='raw_workorder_line_ids']/tree/field[@name='lot_id']" position="attributes">
<attribute name="options">{'no_create': True, 'no_create_edit':True}</attribute>
<attribute name="domain">[('product_id', '=', product_id), ('quant_ids.location_id', '=', location_src_id)]</attribute>
</xpath>
Expand Down

0 comments on commit 7ed2c22

Please sign in to comment.