Skip to Content
Menu
This question has been flagged
1 Atsakyti
9705 Rodiniai

Is it possible to use the following?:

<field .. .. attrs="{'invisible': [('partner_id.name', '!=', False)]}">

The main question is: is the dot ('.') allowed?

We couldn't get it to work..

Portretas
Atmesti
Best Answer

Well you could not get it works, because it does not. To make such things, you need to add fields on the current model (see fields.related)

Portretas
Atmesti
Autorius

OK, you already gave an alternative solution! Thanks!

Autorius

Why does a +domain+ allow the dot notation? and attrs not? Do you know why? Or where it is documented?

A related field in not set till you save. What happens if you've got a boolean and depending on the setting of the boolean you will be able to see certain fields.

Related Posts Replies Rodiniai Veikla
1
kov. 24
5914
2
liep. 18
8121
1
kov. 15
12074
0
kov. 15
4580
2
rugs. 24
4503