
from odoo import models, fields


class StockMove(models.Model):
    _inherit = 'stock.move'

    product_id = fields.Many2one(domain=[('config_ok', '=', False)])


from ast import literal_eval
from odoo import models, fields


class StockMove(models.Model):
    _inherit = 'stock.move'

    def _get_product_domain(self):
        if literal_eval(self.env['ir.config_parameter'].sudo().get_param('product_configurator.product_selectable', default='False')):
            return []
        else:
            return [('config_ok', '=', False)]

    product_id = fields.Many2one(domain=_get_product_domain)

Put configurable product in Picking list
Put configurable product in Picking list

  
+ from ast import literal_eval
  from odoo import models, fields
  
  
  class StockMove(models.Model):
      _inherit = 'stock.move'
  
-     product_id = fields.Many2one(domain=[('config_ok', '=', False)])
+     def _get_product_domain(self):
+         if literal_eval(self.env['ir.config_parameter'].sudo().get_param('product_configurator.product_selectable', default='False')):
+             return []
+         else:
+             return [('config_ok', '=', False)]
  
+     product_id = fields.Many2one(domain=_get_product_domain)
+ 
Put configurable product in Picking list
## Code Before:

from odoo import models, fields


class StockMove(models.Model):
    _inherit = 'stock.move'

    product_id = fields.Many2one(domain=[('config_ok', '=', False)])

## Instruction:
Put configurable product in Picking list
## Code After:

from ast import literal_eval
from odoo import models, fields


class StockMove(models.Model):
    _inherit = 'stock.move'

    def _get_product_domain(self):
        if literal_eval(self.env['ir.config_parameter'].sudo().get_param('product_configurator.product_selectable', default='False')):
            return []
        else:
            return [('config_ok', '=', False)]

    product_id = fields.Many2one(domain=_get_product_domain)
