콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
5100 화면

Dear All,
I am having a requirement,
In my Multi-company environment, one of the child company(say X)---
Its Product(Name) should be, created based on the values at some fields.

For this, I created a new module, and inherited the product.product model.
In the view file, I added a new page on note book "Product Configuration". This page will be available only for "That Particular users-from my "company X". (it is controlled by a checkbox).

My new Product Configuration page, contains some new fields--whose selection determines the Name of Product. may be like... Product Name== field1+field2+field. These field1,field2,field are of types, selection,boolean,char,float,..etc.

How to achieve this ? Please help.

아바타
취소
베스트 답변

All you need to do is to modify name_get method of product.product. There you can define product name that will be represented accordingly to your fields.

아바타
취소
작성자

Dear Nazarri,

name_get() method is used for what?

What I want, is..at the time of Product creation.. the Product name should be taken from field1+field2+.. like that..

Name_get is used to represent object name in many2one relationships e.g. in sale order line. In you're issue there are few solutions you can use: you can modify product create() method (if vals.get(field1): vals[name] += vals[field1]); you can put onchange events on you field1, field2 etc. to update product name.

작성자

Dear Nazarri, Can you please elaborate it?

Yes, i can elaborate it, however I gave you a hint - the rest depends on you, if you don't want to read documentation you can at any moment pay freelancer to make this functionality working.

관련 게시물 답글 화면 활동
1
12월 22
5295
16
9월 24
76533
3
10월 22
9588
1
12월 21
9665
11
1월 24
34922