diff --git a/partner_employee_quantity/README.rst b/partner_employee_quantity/README.rst index b150d673c..1be9e5e91 100644 --- a/partner_employee_quantity/README.rst +++ b/partner_employee_quantity/README.rst @@ -1,20 +1,45 @@ -.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg - :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html - :alt: License: AGPL-3 - ============================= Employee quantity in partners ============================= +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Mature-brightgreen.png + :target: https://odoo-community.org/page/development-status + :alt: Mature +.. |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%2Fpartner--contact-lightgray.png?logo=github + :target: https://github.com/OCA/partner-contact/tree/11.0/partner_employee_quantity + :alt: OCA/partner-contact +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/partner-contact-11-0/partner-contact-11-0-partner_employee_quantity + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/134/11.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + This module allows to set employee quantity for partners, and categorize them by ranges. +**Table of contents** + +.. contents:: + :local: + Configuration ============= To manage available ranges, you need to: -* Go to *Sales > Configuration > Contacts > Ranges by quantity of employees*. +#. Go to *Contacts > Configuration > Ranges by quantity of employees*. +#. Add or edit any range naming it. Usage ===== @@ -25,44 +50,63 @@ To use this module, you need to: * Enable *Is company?*. * You will see a new group of fields called *Employee quantity*. -.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas - :alt: Try me on Runbot - :target: https://runbot.odoo-community.org/runbot/134/10.0 +Known issues / Roadmap +====================== + +* Put in employee ranges numbers for low and upper limit for having a numerical + reference. +* Don't allow to overlap ranges. 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 smashing it by providing a detailed and welcomed `feedback -`_. +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 smashing it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. Credits ======= +Authors +~~~~~~~ + +* Tecnativa + Contributors ------------- +~~~~~~~~~~~~ + +* `Tecnativa `__: -* Antonio Espinosa -* Rafael Blasco -* Jairo Llopis -* David Vidal + * Antonio Espinosa + * Rafael Blasco + * Jairo Llopis + * David Vidal + * Pedro M. Baeza -Maintainer ----------- +Maintainers +~~~~~~~~~~~ + +This module is maintained by the OCA. .. image:: https://odoo-community.org/logo.png :alt: Odoo Community Association :target: https://odoo-community.org -This module is maintained by the OCA. - 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. -To contribute to this module, please visit https://odoo-community.org. +.. |maintainer-pedrobaeza| image:: https://github.com/pedrobaeza.png?size=40px + :target: https://github.com/pedrobaeza + :alt: pedrobaeza + +Current `maintainer `__: + +|maintainer-pedrobaeza| + +This module is part of the `OCA/partner-contact `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/partner_employee_quantity/__init__.py b/partner_employee_quantity/__init__.py index cde864bae..83e553ac4 100644 --- a/partner_employee_quantity/__init__.py +++ b/partner_employee_quantity/__init__.py @@ -1,3 +1,3 @@ -# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). from . import models diff --git a/partner_employee_quantity/__manifest__.py b/partner_employee_quantity/__manifest__.py index dc473087d..d14068b5f 100644 --- a/partner_employee_quantity/__manifest__.py +++ b/partner_employee_quantity/__manifest__.py @@ -1,27 +1,30 @@ -# -*- coding: utf-8 -*- # Copyright 2015 Antonio Espinosa # Copyright 2015 Jairo Llopis # Copyright 2017 David Vidal +# Copyright 2018 Tecnativa - Pedro M. Baeza # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). { 'name': 'Employee quantity in partners', 'summary': 'Know how many employees a partner has', - 'version': '10.0.1.0.0', + 'version': '11.0.1.0.0', 'category': 'Customer Relationship Management', - "author": 'Antiun Ingeniería S.L., ' - 'Tecnativa, ' + "author": 'Tecnativa, ' 'Odoo Community Association (OCA)', "license": "AGPL-3", "application": False, - 'website': 'http://www.tecnativa.com', + 'website': 'https://github.com/OCA/partner-contact', 'depends': [ - 'sale', + 'contacts', ], 'data': [ 'security/ir.model.access.csv', 'views/res_partner_employee_quantity_range_view.xml', 'views/res_partner_view.xml', ], + 'development_status': 'Mature', + 'maintainers': [ + 'pedrobaeza', + ], "installable": True, } diff --git a/partner_employee_quantity/models/__init__.py b/partner_employee_quantity/models/__init__.py index f261da797..ccebc7247 100644 --- a/partner_employee_quantity/models/__init__.py +++ b/partner_employee_quantity/models/__init__.py @@ -1,3 +1,3 @@ -# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). from . import res_partner diff --git a/partner_employee_quantity/models/res_partner.py b/partner_employee_quantity/models/res_partner.py index 39f5310cf..d9fd5e1c4 100644 --- a/partner_employee_quantity/models/res_partner.py +++ b/partner_employee_quantity/models/res_partner.py @@ -1,6 +1,6 @@ -# -*- coding: utf-8 -*- # Copyright 2015 Antonio Espinosa # Copyright 2015 Jairo Llopis +# Copyright 2018 Tecnativa - Pedro M. Baeza # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). from odoo import models, fields @@ -9,13 +9,12 @@ from odoo import models, fields class ResPartner(models.Model): _inherit = 'res.partner' - employee_quantity = fields.Integer( - oldname="employees_number") + employee_quantity = fields.Integer() employee_quantity_range_id = fields.Many2one( - "res.partner.employee_quantity_range", - "Employee quantity range", + comodel_name="res.partner.employee_quantity_range", + string="Employee quantity range", help="Range of this partner depending on the employee quantity.", - oldname="employees_range") + ) class ResPartnerEmployeeQuantityRange(models.Model): diff --git a/partner_employee_quantity/readme/CONFIGURE.rst b/partner_employee_quantity/readme/CONFIGURE.rst new file mode 100644 index 000000000..28c3285c7 --- /dev/null +++ b/partner_employee_quantity/readme/CONFIGURE.rst @@ -0,0 +1,4 @@ +To manage available ranges, you need to: + +#. Go to *Contacts > Configuration > Ranges by quantity of employees*. +#. Add or edit any range naming it. diff --git a/partner_employee_quantity/readme/CONTRIBUTORS.rst b/partner_employee_quantity/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..24ea36ad0 --- /dev/null +++ b/partner_employee_quantity/readme/CONTRIBUTORS.rst @@ -0,0 +1,7 @@ +* `Tecnativa `__: + + * Antonio Espinosa + * Rafael Blasco + * Jairo Llopis + * David Vidal + * Pedro M. Baeza diff --git a/partner_employee_quantity/readme/DESCRIPTION.rst b/partner_employee_quantity/readme/DESCRIPTION.rst new file mode 100644 index 000000000..87a15b6ba --- /dev/null +++ b/partner_employee_quantity/readme/DESCRIPTION.rst @@ -0,0 +1,2 @@ +This module allows to set employee quantity for partners, and categorize them +by ranges. diff --git a/partner_employee_quantity/readme/ROADMAP.rst b/partner_employee_quantity/readme/ROADMAP.rst new file mode 100644 index 000000000..d10f1de17 --- /dev/null +++ b/partner_employee_quantity/readme/ROADMAP.rst @@ -0,0 +1,3 @@ +* Put in employee ranges numbers for low and upper limit for having a numerical + reference. +* Don't allow to overlap ranges. diff --git a/partner_employee_quantity/readme/USAGE.rst b/partner_employee_quantity/readme/USAGE.rst new file mode 100644 index 000000000..c55077954 --- /dev/null +++ b/partner_employee_quantity/readme/USAGE.rst @@ -0,0 +1,5 @@ +To use this module, you need to: + +* Go to any partner's form. +* Enable *Is company?*. +* You will see a new group of fields called *Employee quantity*. diff --git a/partner_employee_quantity/static/description/index.html b/partner_employee_quantity/static/description/index.html new file mode 100644 index 000000000..7cd9857bf --- /dev/null +++ b/partner_employee_quantity/static/description/index.html @@ -0,0 +1,457 @@ + + + + + + +Employee quantity in partners + + + +
+

Employee quantity in partners

+ + +

Mature License: AGPL-3 OCA/partner-contact Translate me on Weblate Try me on Runbot

+

This module allows to set employee quantity for partners, and categorize them +by ranges.

+

Table of contents

+ +
+

Configuration

+

To manage available ranges, you need to:

+
    +
  1. Go to Contacts > Configuration > Ranges by quantity of employees.
  2. +
  3. Add or edit any range naming it.
  4. +
+
+
+

Usage

+

To use this module, you need to:

+
    +
  • Go to any partner’s form.
  • +
  • Enable Is company?.
  • +
  • You will see a new group of fields called Employee quantity.
  • +
+
+
+

Known issues / Roadmap

+
    +
  • Put in employee ranges numbers for low and upper limit for having a numerical +reference.
  • +
  • Don’t allow to overlap ranges.
  • +
+
+
+

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 smashing it by providing a detailed and welcomed +feedback.

+

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

+
+
+

Credits

+
+

Authors

+
    +
  • Tecnativa
  • +
+
+
+

Contributors

+
    +
  • Tecnativa:
      +
    • Antonio Espinosa
    • +
    • Rafael Blasco
    • +
    • Jairo Llopis
    • +
    • David Vidal
    • +
    • Pedro M. Baeza
    • +
    +
  • +
+
+
+

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.

+

Current maintainer:

+

pedrobaeza

+

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

+

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

+
+
+
+ + diff --git a/partner_employee_quantity/views/res_partner_employee_quantity_range_view.xml b/partner_employee_quantity/views/res_partner_employee_quantity_range_view.xml index 5883b90d3..990f21129 100644 --- a/partner_employee_quantity/views/res_partner_employee_quantity_range_view.xml +++ b/partner_employee_quantity/views/res_partner_employee_quantity_range_view.xml @@ -20,6 +20,8 @@ + parent="contacts.res_partner_menu_config" + sequence="0" +/> diff --git a/partner_employee_quantity/views/res_partner_view.xml b/partner_employee_quantity/views/res_partner_view.xml index 0fdb44506..d6f29282d 100644 --- a/partner_employee_quantity/views/res_partner_view.xml +++ b/partner_employee_quantity/views/res_partner_view.xml @@ -6,14 +6,16 @@ res.partner - - - - + + + + + + - +