Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
2 Risposte
1623 Visualizzazioni

Hi all

i want to ad a check box to a quality worksheet. The field text is splitting between 2 rows and id like it to be on one line.

example

"Terminal markers

attached"

instead id like 

"Terminal markers attached" > Checkbox 

ive tried width style and colspan but i can seem to find the right combination.

odoo 17

Thanks

Avatar
Abbandona
Risposta migliore

Hi,


To add a checkbox to a quality worksheet in Odoo 17 and ensure that the field text stays on one line, you can use simply give a string attribute inside the label tag.


For example, Try to use the following code:


<odoo>
<record id="view_quality_worksheet_form" model="ir.ui.view">
<field name="name">quality.worksheet.form</field>
<field name="model">quality.worksheet</field>
        <field name="arch" type="xml">
            <form>
                <div>
                    <label for="checkbox" string="Terminal markers attached"/>
                    <field name="checkbox" id="checkbox"/>
                </div>
            </form>
        </field>
    </record>
</odoo>


Hope it helps.


Avatar
Abbandona
Risposta migliore

Hey Steven,

This would be the simplest way to get the two fields to appear on "one line". I added the columns block to the worksheet and added the text field in the left column and the checkbox in the right column. 


Testing the worksheet on a quality check, this is how it is displayed. I hope this helps!


Avatar
Abbandona
Post correlati Risposte Visualizzazioni Attività
2
feb 16
6503
1
nov 22
2645
5
gen 24
13438
1
lug 24
1338
0
lug 24
1076