Skip to content

Commit

Permalink
[MIG] event_min_seat: Migration to version 17.0
Browse files Browse the repository at this point in the history
TT51923
  • Loading branch information
pilarvargas-tecnativa committed Dec 9, 2024
1 parent 84b76de commit 40faea7
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 6 deletions.
1 change: 1 addition & 0 deletions event_min_seat/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ Contributors
- `Tecnativa <https://www.tecnativa.com>`__:

- Pedro M. Baeza
- Pilar Vargas

Maintainers
-----------
Expand Down
2 changes: 1 addition & 1 deletion event_min_seat/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

{
"name": "Minimum seats in events",
"version": "15.0.1.0.0",
"version": "17.0.1.0.0",
"author": "Tecnativa, Odoo Community Association (OCA)",
"license": "AGPL-3",
"website": "https://github.com/OCA/event",
Expand Down
1 change: 1 addition & 0 deletions event_min_seat/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
- [Tecnativa](https://www.tecnativa.com):

> - Pedro M. Baeza
> - Pilar Vargas
1 change: 1 addition & 0 deletions event_min_seat/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,7 @@ <h2><a class="toc-backref" href="#toc-entry-4">Contributors</a></h2>
<blockquote>
<ul class="simple">
<li>Pedro M. Baeza</li>
<li>Pilar Vargas</li>
</ul>
</blockquote>
</li>
Expand Down
2 changes: 1 addition & 1 deletion event_min_seat/tests/test_event_min_seat.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def setUpClass(cls):
cls.event = cls.env["event.event"].create(
{
"name": "Test event",
"event_type_id": cls.env.ref("event.event_type_data_ticket").id,
"event_type_id": cls.env.ref("event.event_type_0").id,
"date_begin": "2023-01-01",
"date_end": "2023-01-01",
}
Expand Down
7 changes: 4 additions & 3 deletions event_min_seat/views/event_event_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@
<field name="inherit_id" ref="event.view_event_form" />
<field name="arch" type="xml">
<field name="seats_limited" position="after">
<span
attrs="{'invisible': [('seats_limited', '=', False)], 'required': [('seats_limited', '=', True)]}"
>from <field name="seats_min" class="oe_inline" /></span>
<span invisible="not seats_limited" required="seats_limited">from <field
name="seats_min"
class="oe_inline"
/></span>
&amp;nbsp;
</field>
</field>
Expand Down
3 changes: 2 additions & 1 deletion event_min_seat/views/event_type_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
<field name="arch" type="xml">
<field name="has_seats_limitation" position="after">
<span
attrs="{'invisible': [('has_seats_limitation', '=', False)], 'required': [('has_seats_limitation', '=', False)]}"
invisible="not has_seats_limitation"
required="not has_seats_limitation"
>
from <field name="default_registration_min" class="oe_inline" />
&amp;nbsp;
Expand Down

0 comments on commit 40faea7

Please sign in to comment.