Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
10375 Lượt xem

<notebook>

                        <page string="Worked Days &amp; Inputs">

                            <separator string="Worked Days"/>

                            <field name="worked_days_line_ids">

                                <tree string="Worked Days" editable="bottom">

                                    <field name="name"/>

                                    <field name="code"/>

                                    <field name="number_of_days" sum="Total Working Days"/>

                                    <field name="number_of_hours"/>

                                    <field name="contract_id"/>

                                    <field name="sequence" invisible="True"/>

                                </tree>

                                <form string="Worked Day">

                                    <group col="4">

                                        <field name="name"/>

                                        <field name="code"/>

                                        <field name="sequence"/>

                                        <field name="number_of_days"/>

                                        <field name="number_of_hours"/>

                                        <field name="contract_id"/>

                                    </group>

                                </form>

                            </field>

           </page>

</notebook>

I want to write an xpath for this notebook.

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hello try this

<notebook position="inside">

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Do you mean groups as in access right groups? If yes, you need to use the groups attribute to give a specific group a viewing access to a specific form component, like this:

<xpath expr="//notebook" position="attributes">
<!-- Show the notebook to accounting users -->
<attribute name="groups">account.group_account_user</attribute>
</xpath>

Or if you mean you simply want to add <group> elements inside the form's notebook, you can use: 

<xpath expr="//notebook" position="inside">
<group string="My new group">
<!-- all the new fields go here -->
</group>
</xpath>
Ảnh đại diện
Huỷ bỏ

Thank you ..position="inside"..is worked for me

Bài viết liên quan Trả lời Lượt xem Hoạt động
2
thg 2 24
1933
0
thg 3 15
4913
2
thg 5 24
2272
3
thg 4 23
11752
1
thg 4 23
14750