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

Hello Forum,

How to direct a Cursor to a specific field when user opens and edits a form of picking list e.g.??

The employees need to open a picking list and press edit it, then they type the number of packaged delivered. But when they start typing using the keyboard, the cursor is situated in first field (partner field) and I would like cursor situated directly in a specific field. Is it possible to do it? I mean to change the location of curson when you open and edit a form. Thank you.

아바타
취소
베스트 답변

You need to change the view definition and add an attribute default_focus: set to 1 to put the focus (cursor position) on this field when the form is first opened. There can only be one field within a view having this attribute set to 1.

Example:

<field name="name" default_focus=”1”/>


아바타
취소
작성자

Thanks a lot Odoo Master :)

@Zbik I would like to add default_focus inside the field in tree editable="bottom". But it not working, How to apply default_focus in tree editable="bottom"? Thanks

I have try this code for wizard char field but it is not working for me, Can you please give me solution for this?

Hello @Zbik, I have facing same problem as @prakash. For wizard char field it is not working for me. Can you provide solution for this problem?

FYI, I opened a bug report about the problem with default_focus not working in wizards https://github.com/odoo/odoo/issues/29589