New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Field selector in views #17304

Open
wants to merge 2 commits into
base: master
from

Conversation

Projects
None yet
2 participants
@qsm-odoo
Contributor

qsm-odoo commented May 30, 2017

TASK: https://www.odoo.com/web#id=33821&view_type=form&model=project.task&menu_id=

Implement the field selector field (to be able to select a field chain as a field's value).

Also improve the field selector widget so that x2x fields can be selected (and not automatically followed).

@qsm-odoo qsm-odoo added the RD label May 30, 2017

@qsm-odoo qsm-odoo self-assigned this May 30, 2017

@qsm-odoo qsm-odoo requested a review from ged-odoo May 30, 2017

@qsm-odoo

This comment has been minimized.

Show comment
Hide comment
@qsm-odoo

qsm-odoo May 30, 2017

Contributor

Note: I did not use the field anywhere in the views yet because there is a problem where I tried to use it (ir.model.fields): no way to access the model name of the field in creation/edition.

Contributor

qsm-odoo commented May 30, 2017

Note: I did not use the field anywhere in the views yet because there is a problem where I tried to use it (ir.model.fields): no way to access the model name of the field in creation/edition.

@ged-odoo ged-odoo added the Framework label May 31, 2017

qsm-odoo added some commits May 30, 2017

[IMP] web: allow to select x2x field with field selector
Before this commit, when the user was clicking on a x2x field in a
field selector, it was following the relation and proposed the
related model fields. If the user wanted to select the x2x field
itself without following it, he had to close the popover after
following the relation.

Now x2x field suggestions have two buttons: one to select the field
(like the other basic fields) and one to follow the relation.
[IMP] web: add new "field" field widget
Allow to select a field chain associated to a given model in views.

This is designed to replace the use of char fields where needed,
this commit only does that for the "related" field of the
"ir.model.field" view.
@@ -225,6 +225,7 @@
<field name="name"/>
<field name="field_description"/>
<field name="model_id" attrs="{'readonly': [('state','!=', 'manual')]}"/>
<field name="model" invisible="1"/>

This comment has been minimized.

@qsm-odoo

qsm-odoo Oct 18, 2017

Contributor

This is empty in creation even after choosing a model (model_id), this is a problem at python level. I do not know if there is any other place where I can use this widget="field".

@qsm-odoo

qsm-odoo Oct 18, 2017

Contributor

This is empty in creation even after choosing a model (model_id), this is a problem at python level. I do not know if there is any other place where I can use this widget="field".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment