dexterity.localroles


Namedexterity.localroles JSON
Version 1.6 PyPI version JSON
download
home_pagehttps://github.com/imio/
SummaryDefine local roles settings by dexterity type
upload_time2022-07-01 09:40:28
maintainer
docs_urlNone
authorIMIO
requires_python
licensegpl
keywords plone python
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            .. contents::

Introduction
============

Allow to define local roles settings by dexterity type.

A new configuration page is added as a new tab on a dexterity type configuration.

A configuration line has the following fields:

* the state
* the principal
* the roles
* an optional configuration as string, but evaluated as a dict: {'utility name': [roles]}. The utility implements
  ILocalRolesRelatedSearchUtility and get related objects.

You can then define for each state which principal will receive some local roles automatically on the content,
and other local roles on related content.

By example:

* on the "pending" state, the "stephen" user will receive the following role: Reviewer.
* on the "published" state, the "editors" group will receive the following roles: Editor, Reviewer.

The utility "dexterity.localroles.related_parent" get the object parent and can be used to give local roles on the content parent.

* on the "pending" state, the "stephen" user will receive on the content parent the role: Reviewer.

Those automaticaly given roles cannot be manually removed by the "sharing" tab (read only, as inherited roles).

This package is a base for dexterity.localrolesfield that adds a field to define the principal.

Installation
============

* Add dexterity.localroles to your eggs.
* Re-run buildout.
* Done.

Credits
=======

Have an idea? Found a bug? Let us know by `opening a ticket`_.

.. _`opening a ticket`: https://github.com/collective/dexterity.localroles/issues


Tests
=====

This package is tested using Travis CI. The current status of the add-on is :

.. image:: https://api.travis-ci.org/collective/dexterity.localroles.png
    :target: https://travis-ci.org/collective/dexterity.localroles
.. image:: https://coveralls.io/repos/collective/dexterity.localroles/badge.svg?branch=master&service=github
  :target: https://coveralls.io/github/collective/dexterity.localroles?branch=master

Contributors
============

- IMIO, Original Author

Changelog
=========

1.6 (2022-07-01)
----------------

- Added 'rel' (related) handling in `utils.update_roles_in_fti`
  [sgeulette]
- Added 'rem' action in `utils.update_roles_in_fti`
  [sgeulette]
- Added 'portal_type' parameter in `utils.fti_configuration`
  [sgeulette]

1.5 (2021-08-27)
----------------

- Added `update_roles_in_fti` method to update local roles in a config.
  [sgeulette]
- Added `update_security_index` method to update security index
  [sgeulette]

1.4 (2019-06-23)
----------------

- Safe dict key access
  [sgeulette]
- Added css id in configuration form.
  [sgeulette]

1.3 (2018-11-06)
----------------

- Use safely state title in unicode.
  [sgeulette]

1.2 (2017-05-30)
----------------

- Refactored utils method
  [sgeulette]
- Added method to delete related uid annotation.
  [sgeulette]

1.1 (2016-04-18)
----------------

- Useless subscriber removed.
  [sgeulette]

1.0 (2015-11-24)
----------------

- Use only local roles in vocabulary.
  [sgeulette]
- Store all configuration in one fti attribute 'localroles'.
  Useful for dexterity.localrolesfield to avoid a field name is an existing attribute
  [sgeulette]
- Add a related field to store a text configuration that will be used to set related objects local roles.
  [sgeulette]
- Add related search utility
  [sgeulette]
- Change related local roles on transition, on addition, on removal, on moving, on configuration changes
  [sgeulette]
- Add an adapter for related local roles
  [sgeulette]
- Simplify code
  [sgeulette]

0.2 (2015-06-02)
----------------

- Avoid exception on site deletion
  [sgeulette]


0.1 (2014-10-24)
----------------

- Various improvements
  [mpeeters, sgeulette]
- Added tests
  [sgeulette]
- Some improvements
  [sgeulette]
- Add validation on configuration view
  [mpeeters]
- Add localroles configuration view
  [mpeeters]
- Add an adapter for borg.localrole
  [mpeeters]




            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/imio/",
    "name": "dexterity.localroles",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "Plone Python",
    "author": "IMIO",
    "author_email": "support@imio.be",
    "download_url": "https://files.pythonhosted.org/packages/27/42/0cd9c4b5096214eb31834f4b668b50cb375237b8c4b5b4f2a2ade8276d16/dexterity.localroles-1.6.tar.gz",
    "platform": null,
    "description": ".. contents::\n\nIntroduction\n============\n\nAllow to define local roles settings by dexterity type.\n\nA new configuration page is added as a new tab on a dexterity type configuration.\n\nA configuration line has the following fields:\n\n* the state\n* the principal\n* the roles\n* an optional configuration as string, but evaluated as a dict: {'utility name': [roles]}. The utility implements\n  ILocalRolesRelatedSearchUtility and get related objects.\n\nYou can then define for each state which principal will receive some local roles automatically on the content,\nand other local roles on related content.\n\nBy example:\n\n* on the \"pending\" state, the \"stephen\" user will receive the following role: Reviewer.\n* on the \"published\" state, the \"editors\" group will receive the following roles: Editor, Reviewer.\n\nThe utility \"dexterity.localroles.related_parent\" get the object parent and can be used to give local roles on the content parent.\n\n* on the \"pending\" state, the \"stephen\" user will receive on the content parent the role: Reviewer.\n\nThose automaticaly given roles cannot be manually removed by the \"sharing\" tab (read only, as inherited roles).\n\nThis package is a base for dexterity.localrolesfield that adds a field to define the principal.\n\nInstallation\n============\n\n* Add dexterity.localroles to your eggs.\n* Re-run buildout.\n* Done.\n\nCredits\n=======\n\nHave an idea? Found a bug? Let us know by `opening a ticket`_.\n\n.. _`opening a ticket`: https://github.com/collective/dexterity.localroles/issues\n\n\nTests\n=====\n\nThis package is tested using Travis CI. The current status of the add-on is :\n\n.. image:: https://api.travis-ci.org/collective/dexterity.localroles.png\n    :target: https://travis-ci.org/collective/dexterity.localroles\n.. image:: https://coveralls.io/repos/collective/dexterity.localroles/badge.svg?branch=master&service=github\n  :target: https://coveralls.io/github/collective/dexterity.localroles?branch=master\n\nContributors\n============\n\n- IMIO, Original Author\n\nChangelog\n=========\n\n1.6 (2022-07-01)\n----------------\n\n- Added 'rel' (related) handling in `utils.update_roles_in_fti`\n  [sgeulette]\n- Added 'rem' action in `utils.update_roles_in_fti`\n  [sgeulette]\n- Added 'portal_type' parameter in `utils.fti_configuration`\n  [sgeulette]\n\n1.5 (2021-08-27)\n----------------\n\n- Added `update_roles_in_fti` method to update local roles in a config.\n  [sgeulette]\n- Added `update_security_index` method to update security index\n  [sgeulette]\n\n1.4 (2019-06-23)\n----------------\n\n- Safe dict key access\n  [sgeulette]\n- Added css id in configuration form.\n  [sgeulette]\n\n1.3 (2018-11-06)\n----------------\n\n- Use safely state title in unicode.\n  [sgeulette]\n\n1.2 (2017-05-30)\n----------------\n\n- Refactored utils method\n  [sgeulette]\n- Added method to delete related uid annotation.\n  [sgeulette]\n\n1.1 (2016-04-18)\n----------------\n\n- Useless subscriber removed.\n  [sgeulette]\n\n1.0 (2015-11-24)\n----------------\n\n- Use only local roles in vocabulary.\n  [sgeulette]\n- Store all configuration in one fti attribute 'localroles'.\n  Useful for dexterity.localrolesfield to avoid a field name is an existing attribute\n  [sgeulette]\n- Add a related field to store a text configuration that will be used to set related objects local roles.\n  [sgeulette]\n- Add related search utility\n  [sgeulette]\n- Change related local roles on transition, on addition, on removal, on moving, on configuration changes\n  [sgeulette]\n- Add an adapter for related local roles\n  [sgeulette]\n- Simplify code\n  [sgeulette]\n\n0.2 (2015-06-02)\n----------------\n\n- Avoid exception on site deletion\n  [sgeulette]\n\n\n0.1 (2014-10-24)\n----------------\n\n- Various improvements\n  [mpeeters, sgeulette]\n- Added tests\n  [sgeulette]\n- Some improvements\n  [sgeulette]\n- Add validation on configuration view\n  [mpeeters]\n- Add localroles configuration view\n  [mpeeters]\n- Add an adapter for borg.localrole\n  [mpeeters]\n\n\n\n",
    "bugtrack_url": null,
    "license": "gpl",
    "summary": "Define local roles settings by dexterity type",
    "version": "1.6",
    "project_urls": {
        "Homepage": "https://github.com/imio/"
    },
    "split_keywords": [
        "plone",
        "python"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "27420cd9c4b5096214eb31834f4b668b50cb375237b8c4b5b4f2a2ade8276d16",
                "md5": "c31f7c9822f5f8ddb368a99a3dd65faf",
                "sha256": "a8934059139dedc59de8b2781f1cbdfa30e288c475a7f27d165df5e0ff9fc2f1"
            },
            "downloads": -1,
            "filename": "dexterity.localroles-1.6.tar.gz",
            "has_sig": false,
            "md5_digest": "c31f7c9822f5f8ddb368a99a3dd65faf",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 36522,
            "upload_time": "2022-07-01T09:40:28",
            "upload_time_iso_8601": "2022-07-01T09:40:28.765056Z",
            "url": "https://files.pythonhosted.org/packages/27/42/0cd9c4b5096214eb31834f4b668b50cb375237b8c4b5b4f2a2ade8276d16/dexterity.localroles-1.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-07-01 09:40:28",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "dexterity.localroles"
}
        
Elapsed time: 0.42760s