Skip to main content

A set of basic information needed to expose any kind of record in your CMS.

Project description

Beta License: LGPL-3 OCA/website-cms Translate me on Weblate Try me on Runboat

Provide basic information for website records / models via website.published.mixin. This module is meant to be used as a base to build your own CMS.

Table of contents

Usage

New attributes

  • cms_create_url: lead to create view. By default /cms/create/my.model

  • cms_search_url: lead to search view. By default /cms/search/my.model

  • cms_edit_url (computed field): lead to edit view. By default /cms/edit/my.model/model_id

Permission and extra information

  • record.cms_is_owner(): current user is the owner of the record?

  • record.cms_can_edit(): current user can edit this record?

  • record.cms_can_publish(): current user can publish this record?

  • record.cms_can_delete(): current user can delete this record?

  • model.cms_can_create(): current user can create a new record?

Info all in one

When you build CMS UIs you need all those info at once. This module provides also an helper method cms_info() that gives you back a dictionary containing:

  • is_owner: True/False,

  • can_edit: True/False,

  • can_create: True/False,

  • can_publish: True/False,

  • can_delete: True/False,

  • create_url

  • edit_url

  • delete_url

Known issues / Roadmap

Get rid of website dependency and move website.published.mixin integration to a glue module.

Changelog

16.0.1.0.0 (2023-05-13)

Features

  • Migration to v16 (#127)

13.0.1.0.1 (2021-08-23)

Features

  • Migration to v13 (#111)

11.0.1.0.1 (2019-01-18)

Fixes

  • Info dict default to None values

  • Test coverage 100%

11.0.1.0.0 (2018-04-27)

Improvements

  • Initial release

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

  • Camptocamp

Contributors

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/website-cms project on GitHub.

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

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

odoo_addon_cms_info-16.0.1.2.0.1-py3-none-any.whl (28.5 kB view details)

Uploaded Python 3

File details

Details for the file odoo_addon_cms_info-16.0.1.2.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for odoo_addon_cms_info-16.0.1.2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4062051135effeff74a689142fb97f72e9f97a2e7fdafa26ff7f1469cce95665
MD5 3493ed97a8ca2c7cd0f009972461d15f
BLAKE2b-256 f2445704a715261c06dfc9654a6d34fa98d9b1719fffe5a429f3099e492714a4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page