Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

2

How can I add some properties to product in V7?

By
Cristian
on 2/26/13, 7:32 PM 2,415 views

Hi, I am working in a store and its products need some extra properties. For example, for each music album needs Author, Year, Label. Furthermore, the point of sales needs to search by all those properties.

I will wondering if there is any way to do that. Is there any Apps? Should I do it myself?.

I know there is "Variants" for products but It is not exactly that I need.

I hope to get some help or advice.

Regards, Cristian

2

Cyril Gaspard (GEM)

--Cyril Gaspard (GEM)--
4136
| 5 6 8
Paris, France
--Cyril Gaspard (GEM)--

Forum contributor since 2008

Cyril Gaspard (GEM)
On 4/6/13, 5:29 PM

Hi,

you must inherit product.product class and add fields you want to add in python and xml files.

For the search, you just have to override the function name_get by add the contained of field you add.

Bye

1
xiaolong97427
On 2/26/13, 8:05 PM

I can't post link, but search here (help.openerp.com) for : " How to add extra fields to a model? "

it looks like the Xiaolong's link. I tried to add the new Field in the Database Structure -> Models but It throws an error: assert self._rec_name in self._columns.keys() + ['id'], "Invalid rec_name %s for model %s" % (self._rec_name, self._name) AssertionError: Invalid rec_name name for model product.product. Searching in the web seems to be a bug

Cristian
on 2/27/13, 4:10 PM
0
fenshuajiang
On 2/27/13, 12:52 AM

use model "product_variant_multi"

Yes it's a possibility as well, but the module is not compatible with V7 yet. I trying to install and facing a lot of problem.

xiaolong97427
on 2/27/13, 2:57 AM

Just tested out product_multi_variant, don't think it is fully ported to v7, nor think it is the right answer to Cristian. Correct me if I am wrong.

Cristian, I feel your question is similar to mine link:[http://help.openerp.com/question/1652/any-existing-addon-can-solve-my-problem-sales-analysis-based-on-products-multi-attributes/]. Take a look and comment back if you want.

Jay
on 2/27/13, 5:43 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 2/26/13, 7:32 PM
Seen: 2415 times
Last updated: 10/17/16, 6:43 AM