1234567891011121314151617 |
- # -*- coding: utf-8 -*-
- from openerp.http import request as r
- def get_product_attribute():
- query = '''
- SELECT
- id,
- name
- FROM product_attribute
- '''
- r.cr.execute(query)
- return [
- {
- 'id': j[0],
- 'name': j[1],
- } for j in r.cr.fetchall()
- ]
|