12345678910111213141516171819202122232425 |
- # -*- coding: utf-8 -*-
- from openerp import models, fields, api
- class ProductProduct(models.Model):
- _inherit = 'product.product'
- ############################################################
- # PRODUCT PRODUCT
- ############################################################
- @api.model
- def getProductProductSearch(self,domain):
- ProductProduct = self.env['product.product'].search(domain)
- values = []
- for product in ProductProduct:
- values.append({
- 'id': product.id,
- 'display_name': product.display_name,
- 'ean13': product.ean13,
- 'default_code': product.default_code,
- })
- return values
|