# How to use group in view

**URL:** <https://discuss.tryton.org/t/how-to-use-group-in-view/8082>\
**Category:** Developer\
**Created:** [December 2, 2024, 8:59am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082 "2024-12-02T08:59:43Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![herve\_02](https://discuss-cdn.tryton.org/letter_avatar_proxy/v4/letter/h/7ea924/32.png) [@herve\_02](https://discuss.tryton.org/u/herve_02)\
**Post date:** [December 2, 2024, 8:59am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082/1 "2024-12-02T08:59:43Z")

</div>

i am searching a way that explain the views with colspan, group…

it comes from party, and is inside in a notebook colspan=6

```auto
<page string="General" id="general">
   <field name="addresses" mode="form,tree" colspan="4"
     view_ids="party.address_view_form,party.address_view_tree_sequence"/>
   <group colspan="2" id="new_cat">
	<field name="categories" 
	      view_ids="party.category_view_list"/>
	<newline/> 
	<field name="interets" />
	</group>  

```

i would like something like

```auto
|------------------|-------------|
| | categories |
| adresses |-------------|
| | Interests |
|------------------|-------------|

```

but i did not find the place in documentation that explain group in views and how to do that

the result is

```auto
|--------------------------------|
| adresses |
|--------------------------------|
| categories |
|--------------------------------|
| interets |
|--------------------------------|

```

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [December 2, 2024, 9:36am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082/2 "2024-12-02T09:36:48Z")

</div>

We do not support row span, so at best you can make a group with a single col.

---

<div class="post-metadata">

**Author:** ![herve\_02](https://discuss-cdn.tryton.org/letter_avatar_proxy/v4/letter/h/7ea924/32.png) [@herve\_02](https://discuss.tryton.org/u/herve_02)\
**Post date:** [December 2, 2024, 10:09am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082/3 "2024-12-02T10:09:12Z")

</div>

i would like something like

```auto
|------------------|-------------|
| adresses | contact |
|------------------|-------------|
| categories | Interests |
|--------------------------------|

```

and i am trying :

```auto
<field name="addresses" mode="form,tree" colspan="3"
  view_ids="party.address_view_form,party.address_view_tree_sequence"/>
<field name="contact_mechanisms" colspan="3"
     view_ids="party.contact_mechanism_view_tree_sequence"/>     
<field name="categories" colspan="2" view_ids="party.category_view_list"/> 
field name="interets" colspan="2"/>		
<group col="2" colspan="2" id="lang">
    <label name="lang"/>
    <field name="lang" widget="selection" xexpand="0"/>
</group>

```

but contact still come under adresses…

ok i FOUND (perhaps) the arty.address\_view\_form as a colspan 4

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [December 2, 2024, 10:16am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082/4 "2024-12-02T10:16:09Z")

</div>

> [@herve\_02](#):
>
> ```auto
> <field name="addresses" mode="form,tree" colspan="3"
> view_ids="party.address_view_form,party.address_view_tree_sequence"/>
> <field name="contact_mechanisms" colspan="3"
> view_ids="party.contact_mechanism_view_tree_sequence"/>
> 
> ```

Both fields have a colspan of 3 so they can not fit in a single row in a container with a col of 4.  
See [`col`](https://docs.tryton.org/latest/server/topics/views/index.html#common-attributes-col) and [`colspan`](https://docs.tryton.org/latest/server/topics/views/index.html#common-attributes-colspan).

---

<div class="post-metadata">

**Author:** ![system](https://discuss-cdn.tryton.org/uploads/default/original/1X/c6f8ec0a40525cdcd50058c734283450a4b3d38b.png) [@system](https://discuss.tryton.org/u/system)\
**Post date:** [December 13, 2024, 7:20am UTC](https://discuss.tryton.org/t/how-to-use-group-in-view/8082/5 "2024-12-13T07:20:46Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
