Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How to get bigger size for Text input fields used on survey templates ?

By
Yassine TEIMI
on 11/3/15, 9:18 AM 682 views

Dears,

I want to use a bigger size for Text input fields used on survey templates.

On the survey module, especially on the views folder, there is the survey_templates.xml file, I found the template responsible of generating text input fields :

<template id="textbox" name="Text box">
     <input type="text" class="form-control" t-att-name="prefix"/>
</template>

I didn't find the class "form-control" to try modify something there, could you tell me where can I find it ?

I also want to try to add the style attribute: style="size:40px;", so the text input will be like :

<input type="text" style="size:40px;" class="form-control" t-att-name="prefix"/>

All your suggestions will be welcome.

 

0

Axel Mendoza

--Axel Mendoza--
10238
| 7 7 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full time employee trying to understand what to do an how

Reach me at aekroft@gmail.com

Axel Mendoza
On 11/3/15, 9:59 AM

You could use this

<input type="text"class="form-control" t-att-name="prefix" widget="text"/>

or this:

<h1>
<input type="text" class="form-control" t-att-name="prefix"/>
</h1>

Hey Axel, Sorry I did'nt express myself well, it's not for the text font, it's for the Text input layout, I want to make it wider. (so when the user prints the survey he gets all the informations he entered)

Yassine TEIMI
on 11/3/15, 10:12 AM

I've tested with : style="width:40px;" with no changes noticed. I hope you get what I intend to do, it's simple, I want the input zone to be wider.

Yassine TEIMI
on 11/3/15, 10:26 AM

That are two different things. the survey form and the report template, if you wanna get it bigger in the form you could wrap the field inside an h1 or add the widget text to use a textarea. in the report template you could use a paragraph to show the value of the field

Axel Mendoza
on 11/3/15, 10:27 AM

see my updated answer with this

Axel Mendoza
on 11/3/15, 10:29 AM

It worked with : font-size, it automatically increased the width, with the font size, is there a way to increase the width only ? Thanks.

Yassine TEIMI
on 11/3/15, 10:35 AM

test the others solutions

Axel Mendoza
on 11/3/15, 10:36 AM

I've tested the two suggestions, nothing changed on the survey form. Indeed, there is the survey form, and report template, but both uses the same template, the difference is that the survey form displays a wizard (page by page), and the printable view (report template) displays all the pages at the same time, both uses the same template. How can I use the paragraphe in this case ? would the

tag take effect only when I print the survey ?

Yassine TEIMI
on 11/3/15, 11:29 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

2 follower(s)

Stats

Asked: 11/3/15, 9:18 AM
Seen: 682 times
Last updated: 11/3/15, 10:31 AM