Introduction
A “view document” action implementation for collective.powertoken
How to use
Add this product to your Plone installation, then you will be able to register Power Tokens that “view” document.
>>> from collective.powertoken.core.interfaces import IPowerTokenUtility >>> utility = getUtility(IPowerTokenUtility) >>> token = utility.enablePowerToken(document, 'view.viewDocument') >>> results = utility.consumeAction(document, token) >>> print results <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" ... ... </html>
You will get the view output as result.
Parameters
- view
Call a different Zope view on the context, not the current or default ones.
- cmfcallable
Call a CMF Template/skins resource on the context
- setToRequest
A dict with additional values to set in the request. For example you can set disable_border, or (only for Plone 4) disable_plone.leftcolumn and disable_plone.rightcolumn.
Both parameter are not mandatory. Providing none of theme will call the content default view.
Use case
You can view a document, regardless of it’s review state and your roles in the site.
You can call a view on a context, overriding the user security permission.
Changelog
0.1.0 (2012-01-11)
Initial release
Metadata
Release files for collective.powertoken.view 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| collective.powertoken.view-0.1.0.tar.gz | 13.1 kB | Without provenance | Details for collective.powertoken.view-0.1.0.tar.gz |
Release files / collective.powertoken.view-0.1.0.tar.gz
| Download URL | collective.powertoken.view-0.1.0.tar.gz |
|---|---|
| Size | 13.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c4464f06ac7921455c1f7d24490177b3f9d6a31b5a05cfbc5e6316103ab0cc1e
|
|
BLAKE2b-256 checksum How to use checksums |
98d206ed951adedab47cafea2ff4fe2c26027ee957bf2440e579ca2dfe1308b6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for collective.powertoken.view 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.