diff --git a/project_required_field_by_stage/README.rst b/project_required_field_by_stage/README.rst new file mode 100644 index 0000000000..636d546dda --- /dev/null +++ b/project_required_field_by_stage/README.rst @@ -0,0 +1,214 @@ +=============================== +Project Required Field By Stage +=============================== + +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:f79e2a80b9d910fee41985b78ab214ea48cf1891bfddd0bc0d59da8248fa40d4 + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fproject-lightgray.png?logo=github + :target: https://github.com/OCA/project/tree/16.0/project_required_field_by_stage + :alt: OCA/project +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/project-16-0/project-16-0-project_required_field_by_stage + :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/project&target_branch=16.0 + :alt: Try me on Runboat + +|badge1| |badge2| |badge3| |badge4| |badge5| + +[ This file must be max 2-3 paragraphs, and is required. + +The goal of this document is to explain quickly the features of this +module: “what” this module does and “what” it is for. ] + +Example: + +This module extends the functionality of ... to support ... and to allow +users to ... + +**Table of contents** + +.. contents:: + :local: + +Use Cases / Context +=================== + +[ This file is optional but strongly suggested to allow end-users to +evaluate the module's usefulness in their context. ] + +BUSINESS NEED: It should explain the “why” of the module: + +- what is the business requirement that generated the need to develop + this module +- in which context or use cases this module can be useful (practical + examples are welcome!). + +APPROACH: It could also explain the approach to address the mentioned +need. + +USEFUL INFORMATION: It can also inform on related modules: + +- modules it depends on and their features +- other modules that can work well together with this one +- suggested setups where the module is useful (eg: multicompany, + multi-website) + +Installation +============ + +[ This file must only be present if there are very specific installation +instructions, such as installing non-python dependencies. The audience +is systems administrators. ] + +To install this module, you need to: + +1. Do this ... + +Configuration +============= + +[ This file is not always required; it should explain **how to configure +the module before using it**; it is aimed at users with administration +privileges. + +Please be detailed on the path to configuration (eg: do you need to +activate developer mode?), describe step by step configurations and the +use of screenshots is strongly recommended.] + +To configure this module, you need to: + +- Go to *App* > Menu > Menu item +- Activate boolean… > save +- … + +Usage +===== + +[ This file is required and contains the instructions on **“how”** to +use the module for end-users. + +If the module does not have a visible impact on the user interface, just +add the following sentence: + + This module does not impact the user interface. + +If that’s not the case, please make sure that every usage step is +covered and remember that images speak more than words!] + +To use this module, you need to: + +- Go to *App* > Menu > Menu item + + *insert screenshot!* + +- In “Contact” form, add a value to field *xyz* > save + + *insert screenshot!* + +- The value of *xyz* is now displayed in the list view. + + *insert screenshot!* + +Known issues / Roadmap +====================== + +[ Enumerate known caveats and future potential improvements. It is +mostly intended for end-users, and can also help potential new +contributors discovering new features to implement. ] + +- ... + +Changelog +========= + +[ The change log. The goal of this file is to help readers understand +changes between version. The primary audience is end users and +integrators. Purely technical changes such as code refactoring must not +be mentioned here. + +This file may contain ONE level of section titles, underlined with the ~ +(tilde) character. Other section markers are forbidden and will likely +break the structure of the README.rst or other documents where this +fragment is included. ] + +11.0.x.y.z (YYYY-MM-DD) +----------------------- + +- [BREAKING] Breaking changes come first. + (`#70 `__) +- [ADD] New feature. (`#74 `__) +- [FIX] Correct this. (`#71 `__) + +.. _x.y.z-yyyy-mm-dd-1: + +11.0.x.y.z (YYYY-MM-DD) +----------------------- + +- ... + +Bug Tracker +=========== + +Bugs are tracked on `GitHub 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 `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +------- + +* KMEE + +Contributors +------------ + +- Firstname Lastname email.address@example.org (optional company + website url) +- Second Person second.person@example.org (optional company website + url) + +Other credits +------------- + +[ This file is optional and contains additional credits, other than +authors, contributors, and maintainers. ] + +The development of this module has been financially supported by: + +- Company 1 name +- Company 2 name + +Maintainers +----------- + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +This module is part of the `OCA/project `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/project_required_field_by_stage/__init__.py b/project_required_field_by_stage/__init__.py new file mode 100644 index 0000000000..0650744f6b --- /dev/null +++ b/project_required_field_by_stage/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/project_required_field_by_stage/__manifest__.py b/project_required_field_by_stage/__manifest__.py new file mode 100644 index 0000000000..3948f277ed --- /dev/null +++ b/project_required_field_by_stage/__manifest__.py @@ -0,0 +1,17 @@ +# Copyright 2024 KMEE +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +{ + "name": "Project Required Field By Stage", + "summary": """ + KMEE""", + "version": "16.0.1.0.0", + "license": "AGPL-3", + "author": "KMEE,Odoo Community Association (OCA)", + "website": "https://github.com/OCA/project", + "depends": ["project"], + "data": [ + "views/project_task_type.xml", + ], + "demo": [], +} diff --git a/project_required_field_by_stage/models/__init__.py b/project_required_field_by_stage/models/__init__.py new file mode 100644 index 0000000000..62f8791bdc --- /dev/null +++ b/project_required_field_by_stage/models/__init__.py @@ -0,0 +1,2 @@ +from . import project_task +from . import project_task_type diff --git a/project_required_field_by_stage/models/project_task.py b/project_required_field_by_stage/models/project_task.py new file mode 100644 index 0000000000..e1ae00765f --- /dev/null +++ b/project_required_field_by_stage/models/project_task.py @@ -0,0 +1,77 @@ +# Copyright 2024 KMEE +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +import ast +import json as simplejson + +from odoo import _, api, models +from odoo.exceptions import UserError + + +class ProjectTask(models.Model): + + _inherit = "project.task" + + @api.model + def _get_view(self, view_id=None, view_type="form", **options): + arch, view = super()._get_view(view_id, view_type, **options) + stages = self.env["project.task.type"].search( + [("required_field_ids", "!=", False)] + ) + if view.type == "form" and stages: + for field in stages.mapped("required_field_ids"): + stages_with_field = stages.filtered( + lambda stage, field=field: field in stage.required_field_ids + ) + for node in arch.xpath("//field[@name='%s']" % field.name): + attrs = ast.literal_eval(node.attrib.get("attrs", "{}")) + if attrs: + if attrs.get("required"): + attrs["required"] = [ + "|", + ("stage_id", "in", stages_with_field.ids), + ] + attrs["required"] + else: + attrs["required"] = [ + ("stage_id", "in", stages_with_field.ids) + ] + else: + attrs["required"] = [("stage_id", "in", stages_with_field.ids)] + node.set("attrs", simplejson.dumps(attrs)) + return arch, view + + @api.model + def _get_view_cache_key(self, view_id=None, view_type="form", **options): + """The override of _get_view changing the required fields labels according + to the stage makes the view cache dependent on the stages with required fields.""" + key = super()._get_view_cache_key(view_id, view_type, **options) + return key + tuple( + self.env["project.task.type"] + .search([("required_field_ids", "!=", False)]) + .mapped("required_field_ids.name") + ) + + @api.constrains("stage_id") + def _check_stage_id_(self): + for rec in self: + stage = self.env["project.task.type"].search([("id", "=", rec.stage_id.id)]) + for s in stage: + fields = ( + self.env["ir.model.fields"] + .sudo() + .search([("id", "in", s.required_field_ids.ids)]) + ) + for field in fields: + if hasattr(self, "%s" % field.name): + if not getattr(self, "%s" % field.name): + raise UserError( + _( + "Field '%(field)s' is mandatory in stage '%(stage)s'." + ) + % ( + { + "field": field.display_name.split(" (")[0], + "stage": s.display_name, + } + ) + ) diff --git a/project_required_field_by_stage/models/project_task_type.py b/project_required_field_by_stage/models/project_task_type.py new file mode 100644 index 0000000000..58bbc01339 --- /dev/null +++ b/project_required_field_by_stage/models/project_task_type.py @@ -0,0 +1,15 @@ +# Copyright 2024 KMEE +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import fields, models + + +class ProjectTaskType(models.Model): + + _inherit = "project.task.type" + + required_field_ids = fields.Many2many( + comodel_name="ir.model.fields", + domain=[("model", "=", "project.task")], + help="Fields that are required when the task is in this stage.", + ) diff --git a/project_required_field_by_stage/readme/CONFIGURE.md b/project_required_field_by_stage/readme/CONFIGURE.md new file mode 100644 index 0000000000..2fdb0e64a6 --- /dev/null +++ b/project_required_field_by_stage/readme/CONFIGURE.md @@ -0,0 +1,10 @@ +[ This file is not always required; it should explain **how to configure the module before using it**; it is aimed at users with administration privileges. + +Please be detailed on the path to configuration (eg: do you need to activate developer mode?), describe step by step configurations and the use of screenshots is strongly recommended.] + + +To configure this module, you need to: + +- Go to *App* > Menu > Menu item +- Activate boolean… > save +- … diff --git a/project_required_field_by_stage/readme/CONTEXT.md b/project_required_field_by_stage/readme/CONTEXT.md new file mode 100644 index 0000000000..096235a2f3 --- /dev/null +++ b/project_required_field_by_stage/readme/CONTEXT.md @@ -0,0 +1,16 @@ +[ This file is optional but strongly suggested to allow end-users to evaluate the +module's usefulness in their context. ] + +BUSINESS NEED: +It should explain the “why” of the module: +- what is the business requirement that generated the need to develop this module +- in which context or use cases this module can be useful (practical examples are welcome!). + +APPROACH: +It could also explain the approach to address the mentioned need. + +USEFUL INFORMATION: +It can also inform on related modules: +- modules it depends on and their features +- other modules that can work well together with this one +- suggested setups where the module is useful (eg: multicompany, multi-website) diff --git a/project_required_field_by_stage/readme/CONTRIBUTORS.md b/project_required_field_by_stage/readme/CONTRIBUTORS.md new file mode 100644 index 0000000000..7be72fb967 --- /dev/null +++ b/project_required_field_by_stage/readme/CONTRIBUTORS.md @@ -0,0 +1,2 @@ +- Firstname Lastname (optional company website url) +- Second Person (optional company website url) diff --git a/project_required_field_by_stage/readme/CREDITS.md b/project_required_field_by_stage/readme/CREDITS.md new file mode 100644 index 0000000000..9c2b025b50 --- /dev/null +++ b/project_required_field_by_stage/readme/CREDITS.md @@ -0,0 +1,7 @@ +[ This file is optional and contains additional credits, other than + authors, contributors, and maintainers. ] + +The development of this module has been financially supported by: + +- Company 1 name +- Company 2 name diff --git a/project_required_field_by_stage/readme/DESCRIPTION.md b/project_required_field_by_stage/readme/DESCRIPTION.md new file mode 100644 index 0000000000..2371a1464a --- /dev/null +++ b/project_required_field_by_stage/readme/DESCRIPTION.md @@ -0,0 +1,7 @@ +[ This file must be max 2-3 paragraphs, and is required. + +The goal of this document is to explain quickly the features of this module: “what” this module does and “what” it is for. ] + +Example: + +This module extends the functionality of ... to support ... and to allow users to ... diff --git a/project_required_field_by_stage/readme/HISTORY.md b/project_required_field_by_stage/readme/HISTORY.md new file mode 100644 index 0000000000..a6daf58cc9 --- /dev/null +++ b/project_required_field_by_stage/readme/HISTORY.md @@ -0,0 +1,22 @@ +[ The change log. The goal of this file is to help readers + understand changes between version. The primary audience is + end users and integrators. Purely technical changes such as + code refactoring must not be mentioned here. + + This file may contain ONE level of section titles, underlined + with the ~ (tilde) character. Other section markers are + forbidden and will likely break the structure of the README.rst + or other documents where this fragment is included. ] + +## 11.0.x.y.z (YYYY-MM-DD) + +- [BREAKING] Breaking changes come first. + ([#70](https://github.com/OCA/repo/issues/70)) +- [ADD] New feature. + ([#74](https://github.com/OCA/repo/issues/74)) +- [FIX] Correct this. + ([#71](https://github.com/OCA/repo/issues/71)) + +## 11.0.x.y.z (YYYY-MM-DD) + +- ... diff --git a/project_required_field_by_stage/readme/INSTALL.md b/project_required_field_by_stage/readme/INSTALL.md new file mode 100644 index 0000000000..77b98e7aa2 --- /dev/null +++ b/project_required_field_by_stage/readme/INSTALL.md @@ -0,0 +1,7 @@ +[ This file must only be present if there are very specific + installation instructions, such as installing non-python + dependencies. The audience is systems administrators. ] + +To install this module, you need to: + +1. Do this ... diff --git a/project_required_field_by_stage/readme/ROADMAP.md b/project_required_field_by_stage/readme/ROADMAP.md new file mode 100644 index 0000000000..446840cfb9 --- /dev/null +++ b/project_required_field_by_stage/readme/ROADMAP.md @@ -0,0 +1,5 @@ +[ Enumerate known caveats and future potential improvements. + It is mostly intended for end-users, and can also help + potential new contributors discovering new features to implement. ] + +- ... diff --git a/project_required_field_by_stage/readme/USAGE.md b/project_required_field_by_stage/readme/USAGE.md new file mode 100644 index 0000000000..2cf127584b --- /dev/null +++ b/project_required_field_by_stage/readme/USAGE.md @@ -0,0 +1,21 @@ +[ This file is required and contains the instructions on **“how”** to use the module for end-users. + +If the module does not have a visible impact on the user interface, just add the following sentence: + +> This module does not impact the user interface. + +If that’s not the case, please make sure that every usage step is covered and remember that images speak more than words!] + +To use this module, you need to: + +- Go to *App* > Menu > Menu item + + *insert screenshot!* + +- In “Contact” form, add a value to field *xyz* > save + + *insert screenshot!* + +- The value of *xyz* is now displayed in the list view. + + *insert screenshot!* diff --git a/project_required_field_by_stage/static/description/icon.png b/project_required_field_by_stage/static/description/icon.png new file mode 100644 index 0000000000..3a0328b516 Binary files /dev/null and b/project_required_field_by_stage/static/description/icon.png differ diff --git a/project_required_field_by_stage/static/description/index.html b/project_required_field_by_stage/static/description/index.html new file mode 100644 index 0000000000..008010b84c --- /dev/null +++ b/project_required_field_by_stage/static/description/index.html @@ -0,0 +1,556 @@ + + + + + +Project Required Field By Stage + + + +
+

Project Required Field By Stage

+ + +

Beta License: AGPL-3 OCA/project Translate me on Weblate Try me on Runboat

+

[ This file must be max 2-3 paragraphs, and is required.

+

The goal of this document is to explain quickly the features of this +module: “what” this module does and “what” it is for. ]

+

Example:

+

This module extends the functionality of … to support … and to allow +users to …

+

Table of contents

+ +
+

Use Cases / Context

+

[ This file is optional but strongly suggested to allow end-users to +evaluate the module’s usefulness in their context. ]

+

BUSINESS NEED: It should explain the “why” of the module:

+
    +
  • what is the business requirement that generated the need to develop +this module
  • +
  • in which context or use cases this module can be useful (practical +examples are welcome!).
  • +
+

APPROACH: It could also explain the approach to address the mentioned +need.

+

USEFUL INFORMATION: It can also inform on related modules:

+
    +
  • modules it depends on and their features
  • +
  • other modules that can work well together with this one
  • +
  • suggested setups where the module is useful (eg: multicompany, +multi-website)
  • +
+
+
+

Installation

+

[ This file must only be present if there are very specific installation +instructions, such as installing non-python dependencies. The audience +is systems administrators. ]

+

To install this module, you need to:

+
    +
  1. Do this …
  2. +
+
+
+

Configuration

+

[ This file is not always required; it should explain how to configure +the module before using it; it is aimed at users with administration +privileges.

+

Please be detailed on the path to configuration (eg: do you need to +activate developer mode?), describe step by step configurations and the +use of screenshots is strongly recommended.]

+

To configure this module, you need to:

+
    +
  • Go to App > Menu > Menu item
  • +
  • Activate boolean… > save
  • +
  • +
+
+
+

Usage

+

[ This file is required and contains the instructions on “how” to +use the module for end-users.

+

If the module does not have a visible impact on the user interface, just +add the following sentence:

+
+This module does not impact the user interface.
+

If that’s not the case, please make sure that every usage step is +covered and remember that images speak more than words!]

+

To use this module, you need to:

+
    +
  • Go to App > Menu > Menu item

    +

    insert screenshot!

    +
  • +
  • In “Contact” form, add a value to field xyz > save

    +

    insert screenshot!

    +
  • +
  • The value of xyz is now displayed in the list view.

    +

    insert screenshot!

    +
  • +
+
+
+

Known issues / Roadmap

+

[ Enumerate known caveats and future potential improvements. It is +mostly intended for end-users, and can also help potential new +contributors discovering new features to implement. ]

+
    +
  • +
+
+
+

Changelog

+

[ The change log. The goal of this file is to help readers understand +changes between version. The primary audience is end users and +integrators. Purely technical changes such as code refactoring must not +be mentioned here.

+

This file may contain ONE level of section titles, underlined with the ~ +(tilde) character. Other section markers are forbidden and will likely +break the structure of the README.rst or other documents where this +fragment is included. ]

+
+

11.0.x.y.z (YYYY-MM-DD)

+
    +
  • [BREAKING] Breaking changes come first. +(#70)
  • +
  • [ADD] New feature. (#74)
  • +
  • [FIX] Correct this. (#71)
  • +
+
+ +
+
+

Bug Tracker

+

Bugs are tracked on GitHub 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.

+

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

+
+
+

Credits

+
+

Authors

+
    +
  • KMEE
  • +
+
+
+

Contributors

+ +
+
+

Other credits

+

[ This file is optional and contains additional credits, other than +authors, contributors, and maintainers. ]

+

The development of this module has been financially supported by:

+
    +
  • Company 1 name
  • +
  • Company 2 name
  • +
+
+
+

Maintainers

+

This module is maintained by the OCA.

+ +Odoo Community Association + +

OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use.

+

This module is part of the OCA/project project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/project_required_field_by_stage/tests/__init__.py b/project_required_field_by_stage/tests/__init__.py new file mode 100644 index 0000000000..afa0d01d72 --- /dev/null +++ b/project_required_field_by_stage/tests/__init__.py @@ -0,0 +1 @@ +from . import test_project_required_field_by_stage diff --git a/project_required_field_by_stage/tests/test_project_required_field_by_stage.py b/project_required_field_by_stage/tests/test_project_required_field_by_stage.py new file mode 100644 index 0000000000..829cf17dc5 --- /dev/null +++ b/project_required_field_by_stage/tests/test_project_required_field_by_stage.py @@ -0,0 +1,84 @@ +# Copyright 2024 KMEE +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +import ast + +from odoo.exceptions import UserError +from odoo.tests.common import TransactionCase + + +class TestProjectRequiredFieldByStage(TransactionCase): + def setUp(self): + super().setUp() + + self.project_project_model = self.env["project.project"] + self.project_task_type_model = self.env["project.task.type"] + self.project_task_model = self.env["project.task"] + self.res_users_model = self.env["res.users"] + self.project_project_1 = self.project_project_model.create( + { + "name": "Project 1", + } + ) + self.project_task_type_1 = self.project_task_type_model.create( + { + "name": "Project Stage 1", + "project_ids": [(4, self.project_project_1.id)], + } + ) + self.project_task_type_2 = self.project_task_type_model.create( + { + "name": "Project Stage 2", + "required_field_ids": [ + (4, self.env.ref("project.field_project_task__user_ids").id) + ], + "project_ids": [(4, self.project_project_1.id)], + } + ) + + self.project_task_1 = self.project_task_model.create( + { + "name": "Project Task 1", + "project_id": self.project_project_1.id, + "user_ids": False, + "stage_id": self.project_task_type_1.id, + } + ) + self.res_users_1 = self.res_users_model.create( + { + "name": "User 1", + "login": "user@example.com", + "email": "user@example.com", + "active": True, + } + ) + + def test_locking(self): + with self.assertRaises(UserError): + self.project_task_1.write( + { + "stage_id": self.project_task_type_2.id, + } + ) + self.project_task_1.write( + { + "user_ids": [(4, self.res_users_1.id)], + } + ) + self.project_task_1.write( + { + "stage_id": self.project_task_type_2.id, + } + ) + self.assertEqual(self.project_task_1.stage_id.id, self.project_task_type_2.id) + + def test_get_view_required_fields(self): + arch, view = self.project_task_1._get_view(view_type="form") + node = arch.xpath("//field[@name='user_ids']") + self.assertTrue(node) + attrs = ast.literal_eval(node[0].attrib.get("attrs", "{}")) + self.assertIn("required", attrs) + self.assertIn(self.project_task_type_2.id, attrs["required"][0][2]) + + arch, view = self.project_task_1._get_view(view_id=view.id, view_type="form") + self.assertIn(self.project_task_type_2.id, attrs["required"][0][2]) diff --git a/project_required_field_by_stage/views/project_task_type.xml b/project_required_field_by_stage/views/project_task_type.xml new file mode 100644 index 0000000000..0e36f90e32 --- /dev/null +++ b/project_required_field_by_stage/views/project_task_type.xml @@ -0,0 +1,21 @@ + + + + + project.task.type.form in (project_required_field_by_stage) + project.task.type + + + + + + + + + diff --git a/setup/project_required_field_by_stage/odoo/addons/project_required_field_by_stage b/setup/project_required_field_by_stage/odoo/addons/project_required_field_by_stage new file mode 120000 index 0000000000..5d31c58873 --- /dev/null +++ b/setup/project_required_field_by_stage/odoo/addons/project_required_field_by_stage @@ -0,0 +1 @@ +../../../../project_required_field_by_stage \ No newline at end of file diff --git a/setup/project_required_field_by_stage/setup.py b/setup/project_required_field_by_stage/setup.py new file mode 100644 index 0000000000..28c57bb640 --- /dev/null +++ b/setup/project_required_field_by_stage/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +)