Metadata-Version: 2.1
Name: odoo14-addon-base-action-visibility-restriction-domain
Version: 14.0.1.0.1.dev2
Summary: Restrict with groups and domain action access
Home-page: https://github.com/OCA/server-ux
Author: Ilyas, Ooops404, Odoo Community Association (OCA)
Author-email: support@odoo-community.org
License: AGPL-3
Platform: UNKNOWN
Classifier: Programming Language :: Python
Classifier: Framework :: Odoo
Classifier: Framework :: Odoo :: 14.0
Classifier: License :: OSI Approved :: GNU Affero General Public License v3
Requires-Python: >=3.6
Requires-Dist: odoo14-addon-base-action-visibility-restriction
Requires-Dist: odoo <14.1dev,>=14.0a

=========================================
Base Action Visibility Restriction Domain
=========================================

.. 
   !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
   !! This file is generated by oca-gen-addon-readme !!
   !! changes will be overwritten.                   !!
   !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
   !! source digest: sha256:b568cdcf3e853f03943d820820ac5b2df8b6a1d19dc6c6760613c3b4b93d99d4
   !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |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%2Fserver--ux-lightgray.png?logo=github
    :target: https://github.com/OCA/server-ux/tree/14.0/base_action_visibility_restriction_domain
    :alt: OCA/server-ux
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
    :target: https://translation.odoo-community.org/projects/server-ux-14-0/server-ux-14-0-base_action_visibility_restriction_domain
    :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/server-ux&target_branch=14.0
    :alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

Using restriction records you can create domains for different groups. Domain will allow/deny action run on specific target model records.

If all restrictions of an action are without domain - action is hidden based on group (base_action_visibility_restriction behaviour).

If at least one restriction with domain - action is shown. Access will be defined once user run action.

If restriction record without domain - user can't run action. If with domain - domain defines for which records user (users group) can run action.

**Table of contents**

.. contents::
   :local:

Usage
=====

Restrict access to a **Window Action**.

Window actions normally have a wizard - window that opens after you run action.

Window actions have as Destination Model a model of the wizard. Not a target model.

Lets say you want to limit access to the window action Create Invoices for Sale Order.

#. Enable debug mode.
#. Select multiple records in the Sale Orders list view.
#. Action -> Create Invoices.
#. Click bug symbol. Click Edit Action.
#. Go to Security tab.
#. Create restrictions lines and save.

Restrict access to a **Server Action**.

Server actions dont have a wizard. They are linked directly to a target model. They are performed right away after you click action.

Lets say you want to limit access to the server action Mark Quotation as Sent for Sale Order.

#. Enable debug mode.
#. Go to Settings -> Technical -> Server Actions.
#. Search for  Mark Quotation as Sent. You can see in the Model field it is Sale Order.
#. Go to Security tab.
#. Create restrictions lines and save.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/server-ux/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/server-ux/issues/new?body=module:%20base_action_visibility_restriction_domain%0Aversion:%2014.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.

Credits
=======

Authors
~~~~~~~

* Ilyas
* Ooops404

Contributors
~~~~~~~~~~~~

* `Ooops404 <https://www.ooops404.com>`_:

  * Ilyas <irazor147@gmail.com>

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.

.. |maintainer-ilyasprogrammer| image:: https://github.com/ilyasprogrammer.png?size=40px
    :target: https://github.com/ilyasprogrammer
    :alt: ilyasprogrammer

Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-ilyasprogrammer| 

This module is part of the `OCA/server-ux <https://github.com/OCA/server-ux/tree/14.0/base_action_visibility_restriction_domain>`_ project on GitHub.

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


