Skip to content

Commit

Permalink
[MIG] fieldservice_activity: Migration to 18.0
Browse files Browse the repository at this point in the history
  • Loading branch information
EdgarRetes committed Nov 5, 2024
1 parent 639754e commit 4680dbe
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 25 deletions.
10 changes: 5 additions & 5 deletions fieldservice_activity/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ Field Service Activity
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Ffield--service-lightgray.png?logo=github
:target: https://github.com/OCA/field-service/tree/17.0/fieldservice_activity
:target: https://github.com/OCA/field-service/tree/18.0/fieldservice_activity
:alt: OCA/field-service
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/field-service-17-0/field-service-17-0-fieldservice_activity
:target: https://translation.odoo-community.org/projects/field-service-18-0/field-service-18-0-fieldservice_activity
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/field-service&target_branch=17.0
:target: https://runboat.odoo-community.org/builds?repo=OCA/field-service&target_branch=18.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|
Expand Down Expand Up @@ -96,7 +96,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues <https://github.com/OCA/field-service/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/field-service/issues/new?body=module:%20fieldservice_activity%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/field-service/issues/new?body=module:%20fieldservice_activity%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Expand Down Expand Up @@ -154,6 +154,6 @@ Current `maintainers <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-max3903| |maintainer-osi-scampbell|

This module is part of the `OCA/field-service <https://github.com/OCA/field-service/tree/17.0/fieldservice_activity>`_ project on GitHub.
This module is part of the `OCA/field-service <https://github.com/OCA/field-service/tree/18.0/fieldservice_activity>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
2 changes: 1 addition & 1 deletion fieldservice_activity/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"name": "Field Service Activity",
"summary": """Field Service Activities are a set of actions
that need to be performed on a service order""",
"version": "17.0.1.0.1",
"version": "18.0.1.0.0",
"category": "Field Service",
"license": "AGPL-3",
"author": "Open Source Integrators, Odoo Community Association (OCA)",
Expand Down
8 changes: 3 additions & 5 deletions fieldservice_activity/models/fsm_activity.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,18 @@ class FSMActivity(models.Model):
_description = "Field Service Activity"

name = fields.Char(
required=True, readonly=True, states={"todo": [("readonly", False)]}
required=True,
readonly=True,
)
required = fields.Boolean(
default=False,
readonly=True,
states={"todo": [("readonly", False)]},
)
sequence = fields.Integer()
completed = fields.Boolean(default=False)
completed_on = fields.Datetime(readonly=True)
completed_by = fields.Many2one("res.users", readonly=True)
ref = fields.Char(
"Reference", readonly=True, states={"todo": [("readonly", False)]}
)
ref = fields.Char("Reference", readonly=True)
fsm_order_id = fields.Many2one("fsm.order", "FSM Order")
fsm_template_id = fields.Many2one("fsm.template", "FSM Template")
state = fields.Selection(
Expand Down
6 changes: 3 additions & 3 deletions fieldservice_activity/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ <h1 class="title">Field Service Activity</h1>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:4c7e1e5b3b0e62eadf9560fd8d8d438d6381416530f22f6ac182b330e52e47bf
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/field-service/tree/17.0/fieldservice_activity"><img alt="OCA/field-service" src="https://img.shields.io/badge/github-OCA%2Ffield--service-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/field-service-17-0/field-service-17-0-fieldservice_activity"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/field-service&amp;target_branch=17.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/field-service/tree/18.0/fieldservice_activity"><img alt="OCA/field-service" src="https://img.shields.io/badge/github-OCA%2Ffield--service-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/field-service-18-0/field-service-18-0-fieldservice_activity"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/field-service&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p>A Field Service Activity gives the user the ability to define a list of
tasks/activities on a service order</p>
<p>The user can add tasks/activities to the FSM order to the ones created
Expand Down Expand Up @@ -451,7 +451,7 @@ <h1><a class="toc-backref" href="#toc-entry-6">Bug Tracker</a></h1>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/field-service/issues">GitHub Issues</a>.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
<a class="reference external" href="https://github.com/OCA/field-service/issues/new?body=module:%20fieldservice_activity%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<a class="reference external" href="https://github.com/OCA/field-service/issues/new?body=module:%20fieldservice_activity%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
Expand Down Expand Up @@ -493,7 +493,7 @@ <h2><a class="toc-backref" href="#toc-entry-11">Maintainers</a></h2>
promote its widespread use.</p>
<p>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainers</a>:</p>
<p><a class="reference external image-reference" href="https://github.com/max3903"><img alt="max3903" src="https://github.com/max3903.png?size=40px" /></a> <a class="reference external image-reference" href="https://github.com/osi-scampbell"><img alt="osi-scampbell" src="https://github.com/osi-scampbell.png?size=40px" /></a></p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/field-service/tree/17.0/fieldservice_activity">OCA/field-service</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/field-service/tree/18.0/fieldservice_activity">OCA/field-service</a> project on GitHub.</p>
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
</div>
</div>
Expand Down
3 changes: 2 additions & 1 deletion fieldservice_activity/tests/test_fsm_activity.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
from datetime import datetime

from odoo.exceptions import ValidationError
from odoo.tests.common import Form, TransactionCase
from odoo.tests import Form
from odoo.tests.common import TransactionCase


class TestFSMActivity(TransactionCase):
Expand Down
10 changes: 5 additions & 5 deletions fieldservice_activity/views/fsm_order.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
<xpath expr="//notebook/page[1]" position="after">
<page string="Activities">
<field name="order_activity_ids" nolabel="1">
<tree editable="bottom">
<list editable="bottom">
<field name="sequence" widget="handle" />
<field name="name" />
<field name="required" />
<field name="ref" />
<field name="name" readonly="state != 'todo'" />
<field name="required" readonly="state != 'todo'" />
<field name="ref" readonly="state != 'todo'" />
<field name="completed" column_invisible="1" />
<field name="completed_on" />
<field name="completed_by" />
Expand All @@ -30,7 +30,7 @@
invisible="state not in ['todo']"
/>
<field name="state" readonly="1" />
</tree>
</list>
</field>
</page>
</xpath>
Expand Down
10 changes: 5 additions & 5 deletions fieldservice_activity/views/fsm_template.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
<xpath expr="//notebook/page[1]" position="after">
<page string="Activities">
<field name="temp_activity_ids" nolabel="1">
<tree editable="bottom">
<list editable="bottom">
<field name="sequence" widget="handle" />
<field name="name" />
<field name="required" />
<field name="ref" />
<field name="name" readonly="state != 'todo'" />
<field name="required" readonly="state != 'todo'" />
<field name="ref" readonly="state != 'todo'" />
<field name="completed" invisible="1" />
<field name="completed_on" invisible="1" />
<field name="completed_by" invisible="1" />
Expand All @@ -30,7 +30,7 @@
invisible="1"
/>
<field name="state" readonly="1" />
</tree>
</list>
</field>
</page>
</xpath>
Expand Down

0 comments on commit 4680dbe

Please sign in to comment.