16.How To Define Many2one Field In Odoo || Relational Fields In Odoo

16.How To Define Many2one Field In Odoo || Relational Fields In Odoo

Odoo Mates

3 года назад

19,708 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Ragul P
Ragul P - 27.09.2022 12:09

Thanks for this video ,
How to decide which field i exactly need to fulfill my requirment like one2many or many2one or many2many

Ответить
aweb amara
aweb amara - 30.04.2022 01:23

can you make video relations one2one

Ответить
El Critismiquis
El Critismiquis - 23.04.2022 20:50

Your series are amazing! But I have one little, perhaps stupid, question: How does Odoo engine know which data are you asking for when making that many2one field? Is it because when using res.partner as comodel_name, contacts ids are the only kind of data you are going to get?

thanks!

Ответить
Melvin Guerra
Melvin Guerra - 24.02.2022 19:55

How to determine a certain value among the res.partner module?

Ответить
houda bou
houda bou - 25.01.2022 12:36

how to get list of customer contacts in account invoice please !

Ответить
Yonas Girma
Yonas Girma - 27.12.2021 09:41

Your videos are awesome. Please keep it up. It helped me a lot. I can't thank you enough.

Ответить
Aravind S
Aravind S - 24.12.2021 08:12

Thank you so much for the videos.
you helped me so much :)

Ответить
Engineer Asmaa
Engineer Asmaa - 09.12.2021 17:36

Vary Nice✔👌

Ответить
Francisco Arrona
Francisco Arrona - 02.12.2021 08:09

Hello in my case the UI does not show the values of the related model on a many2one field, it just show the string but either the list form nothing to capture, here is my model:
class enviarPago(models.TransientModel):
_name = "enviar.pago"
_description = "Envio de Pago"
transaction_id = fields.Many2one("payment.transaction", readonly=True)
acquirer_id = fields.Many2one("payment.acquirer", required=True)
amount = fields.Monetary(string="Monto", required=True)
currency_id = fields.Many2one("res.currency", string="Moneda")
payment_date = fields.Date(string="Fecha Pago:", required=True, default=fields.Date.context_today)
pers_id = fields.Many2one("hr.employee", readonly=True)

and the xml:
<field name="acquirer_id" string="Forma Pago" />
<field name="amount" string="Monto:" />
</group>
<group>
<field name="payment_date" />
<field name="currency_id" />
<field name="pers_id" string="Chofer" />

The one that does not work is the employee pers_id while as the acquirer and the currency work fine. I have de hr module on my manifest dependencies. Help please

Ответить
JH
JH - 08.11.2021 12:09

hey, thanks for the video. I wanted to ask.

so I have 3 models, "modelA" "modelB" and "modelC"

"modelA" has a many2one field from "modelB" records, it's called "your_name"
"modelC" has a char field, called "names"

I've created a function on "modelA" to create a record , and pass modelA.your_name value to "names" field on "modelC".
when I execute the code, instead of showing the value, it just shows "modelB(2)", or "modelB(3)", the numbers changes according to the value from the your_name field.

can you tell me how to make it show the value? all I know that this happens because the "modelC" did'nt know the values from "modelB".
p.s does myexplanation clear? pls let meknow. thanks

Ответить
Ali Mohamed
Ali Mohamed - 28.10.2021 22:02

thank you so much for this videos

Ответить
haseeb ahmed
haseeb ahmed - 16.07.2021 20:35

thanks, very helpful.
if i wanted to bind some attribute of res.partner, how to acheive this. i.e rather than showing responsible person name, i wanted to show that person contact number. thanks in adv for all the help

Ответить
DXB_CODER
DXB_CODER - 22.05.2021 10:08

Hello, thank you so much for the video.
When we add a new relational field, shouldn't we specify something in the depends section inside the manifest file?
Regards

Ответить