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.

2

column span

By
Frankie Chan
on 7/3/14, 5:29 AM 1,271 views

Hi,

I wrote the code:

 <group >

    <label for="remarks" string="Remarks"/>
        <div>     
            <field name="remarks" />
        </div>
 </group>

It appear like:

Remarks                              |_____________________________|<--------------text field

However, I would like to have:

Remarks  |___________________________________________|<--------------text field

How to achieve that?

Thank you very much.

Thanks for the method suggested by prakash. It works but the the field is now on the second page. Are there any amendments or commands to make it appear on the first page?

Frankie Chan
on 7/4/14, 1:03 AM

In my custom module version 7. I applied the same method its working without any issue.

Prakash
on 7/4/14, 1:19 AM
Hi prakash,

Thanks for your email.

It's good that we can discuss through email because I can show you the results by figure. 

How can I find the email addresses of others in the forum?

I tried your code but it appears on the second page, as shown in the figure attached.

My desired result is that the whole "text + text box" appears at the line just below title with the text box shorten to fit the page.

I am now changing the form view of existing module, not creating new module.

Does it have any problems?

Also, you see that the address text box is very small, how can I enlarge its height?

Thank you very much.

Regards,

Frankie



On Fri, Jul 4, 2014 at 1:19 PM, prakash <prakash-jain-sunarctechnologies-com@openerp.my.openerp.com> wrote:

In my custom module version 7. I applied the same method its working without any issue.

--
prakash Sent by OpenERP S.A. using OpenERP. Access your messages and documents in Odoo

Frankie Chan
on 7/4/14, 10:42 PM
Hi Frankie,

 1) I think you added "Remark" fields at the End of the </sheet> tag. so its shows in the next page (next sheet).  Add the "Remarks" after the  "Title" fields and  or In the page tag after the  "Internal Notes"  based on your need.

2) In your screen shot "Address" text box only shown. In the Openerp version 7 Customer form Address, City, State, Zip, Country text box also available. Check you settings to Enable all other fields.

Hope this will help you!

Thanks
Prakash




On Sat, Jul 5, 2014 at 8:13 AM, Frankie Chan <kwfchan@gmail.com> wrote:
Hi prakash,

Thanks for your email.

It's good that we can discuss through email because I can show you the results by figure. 

How can I find the email addresses of others in the forum?

I tried your code but it appears on the second page, as shown in the figure attached.

My desired result is that the whole "text + text box" appears at the line just below title with the text box shorten to fit the page.

I am now changing the form view of existing module, not creating new module.

Does it have any problems?

Also, you see that the address text box is very small, how can I enlarge its height?

Thank you very much.

Regards,

Frankie



On Fri, Jul 4, 2014 at 1:19 PM, prakash <prakash-jain-sunarctechnologies-com@openerp.my.openerp.com> wrote:

In my custom module version 7. I applied the same method its working without any issue.

--
prakash Sent by OpenERP S.A. using OpenERP. Access your messages and documents in Odoo

--
Frankie Chan Sent by OpenERP S.A. using OpenERP. Access your messages and documents in Odoo

Prakash
on 7/5/14, 2:01 AM

Please review http://forum.openerp.com/forum/topic24602.html for help on colspan and cols.

Bista Solutions US, Ray Carnes
on 7/5/14, 10:50 PM
Hi Ray,

Thanks.

I read it.

I wrote the code:

-------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="utf-8"?>
<openerp>
  <data>
    <record model="ir.ui.view" id="view_ct_form">
        <field name="name">res.partner.form</field>
        <field name="model">res.partner</field>
        <field name="inherit_id" ref="base.view_partner_form" />
        <field name="arch" type="xml">

       <group >
             <label for="remarks" class="custom_allign" string="Remarks"/>
                <div>     
                    <field name="remarks" colspan = "4" />
                </div>
       </group>

    </record>
  </data>
</openerp>
-------------------------------------------------------------------------------------------------

However, the text box is too short. Can you please help?

Thanks.

Regards,

Frankie



On Sun, Jul 6, 2014 at 10:50 AM, Ray Carnes <rcarnes-ursainfosystems-com@openerp.my.openerp.com> wrote:

Please review http://forum.openerp.com/forum/topic24602.html for help on colspan and cols.

--
Ray Carnes Sent by OpenERP Inc. using OpenERP. Access your messages and documents in Odoo

Frankie Chan
on 7/5/14, 11:37 PM

Check where you are anchoring your <group> tag (right now you are not anchoring it anywhere that I can see), when I do it outside the main group, I get:

 

<img width="495" height="204" id="Picture_x0020_1" src="cid:image001.jpg@01CF99F9.A00A74E0">

 

 

You need an anchor field/group and postion=”before” or “after”.

 

Ray.

 

From: Frankie Chan [mailto:kwfchan@gmail.com]
Sent: Saturday, July 05, 2014 8:37 PM
To: Followers of column-span
Subject: Re: column span

 

Hi Ray,

 

Thanks.

 

I read it.

 

I wrote the code:

 

-------------------------------------------------------------------------------------------------

<?xml version="1.0" encoding="utf-8"?>

<openerp>

  <data>

    <record model="ir.ui.view" id="view_ct_form">

        <field name="name">res.partner.form</field>

        <field name="model">res.partner</field>

        <field name="inherit_id" ref="base.view_partner_form" />

        <field name="arch" type="xml">

 

       <group >

             <label for="remarks" class="custom_allign" string="Remarks"/>

                <div>     

                    <field name="remarks" colspan = "4" />

                </div>

       </group>

 

    </record>

  </data>

</openerp>

-------------------------------------------------------------------------------------------------

 

However, the text box is too short. Can you please help?

 

Thanks.

 

Regards,

 

Frankie

 

 

On Sun, Jul 6, 2014 at 10:50 AM, Ray Carnes <rcarnes-ursainfosystems-com@openerp.my.openerp.com> wrote:

Please review http://forum.openerp.com/forum/topic24602.html for help on colspan and cols.

--
Ray Carnes Sent by OpenERP Inc. using OpenERP. Access your messages and documents in Odoo

 

--
Frankie Chan Sent by OpenERP S.A. using OpenERP. Access your messages and documents in Odoo

Bista Solutions US, Ray Carnes
on 7/7/14, 6:39 PM
2

Prakash

--Prakash--
3173
| 5 4 7
Bikaner, India
--Prakash--

OpenERP Devloper at SunARC Technology

Prakash
On 7/3/14, 6:05 AM

In __openerp__.py File add:-

                "css" : ["static/src/css/labelallign.css"],

In static/src/css/labelallign.css add:-

                .openerp .custom_allign {
                            text-align: right;
                 }

In xml file add:-

<form string="Title" version="7.0">
 <group >
    <label for="remarks" class="custom_allign" string="Remarks"/>
        <div>     
            <field name="remarks" />
        </div>
 </group>
</form>

 

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

4 follower(s)

Stats

Asked: 7/3/14, 5:29 AM
Seen: 1271 times
Last updated: 3/16/15, 8:10 AM