编辑进度RestAPI
项目描述
一个Plone扩展,通过RestAPI公开编辑进度
主要功能
RestAPI编辑进度
$ curl -H 'Accept: application/json' --user admin:admin -i http://localhost:8080/Plone/a-page/@editing.progress or $ curl -H 'Accept: application/json' --user admin:admin -i http://localhost:8080/Plone/a-page?expand=editing.progress
安装
将
eea.progress.editing
添加到您的requirements.txt
和constraints.txt
文件中,并运行pip install -r requirements.txt -c constraints.txt
或者,如果您正在使用buildout,请将
eea.progress.editing
添加到您的buildout中的eggs部分,并重新运行buildout[buildout] eggs += eea.progress.editing
或者通过docker
$ docker run --rm -p 8080:8080 -e ADDONS="eea.progress.editing" plone/plone-backend
重启Plone
在
网站设置 > 扩展
中安装eea.progress.editing
通过
控制面板 > 编辑进度设置
配置编辑进度如果您已经有针对您的内容类型编辑进度的
Plone 4
定义,您可以在/portal_progress/document/view.export
处将它们导出为XML,然后使用xml2dict.py脚本来将它们转换为Plone 6
注册表。输出应如下所示{ "Document": [ { 'condition': 'python:value', 'hideReady': 'False', 'iconEmpty': 'eea-icon eea-icon-edit', 'iconReady': 'eea-icon eea-icon-check', 'labelEmpty': 'Please set the {label} of this {context.portal_type}', 'labelReady': 'You added the {label}', 'link': 'edit#fieldsetlegend-default', 'linkLabel': 'Add {label}', 'prefix': 'title', 'states': ['all'] }, { 'condition': 'python:value', 'hideReady': 'False', 'iconEmpty': 'eea-icon eea-icon-edit', 'iconReady': 'eea-icon eea-icon-check', 'labelEmpty': 'Please set the {label} of this {context.portal_type}', 'labelReady': 'You added the {label}', 'link': 'edit#fieldsetlegend-default', 'linkLabel': 'Add {label}', 'prefix': 'description', 'states': ['all'] }, ... ] }
源代码
Eggs仓库
Plone版本
该软件已开发并测试适用于Plone 4、5和6。
如何贡献
版权和许可证
eea.progress.editing(原始代码)是自由软件;您可以在自由软件基金会发布的GNU通用公共许可证的条款下重新分发和/或修改它;许可证的第二版或(根据您的选择)任何后续版本。
分发此程序是希望它将是有用的,但没有任何保证;甚至没有对适销性或特定用途适用性的暗示性保证。有关更多详情,请参阅GNU通用公共许可证。
您应该已经随此程序收到了一份GNU通用公共许可证的副本;如果没有,请写信给自由软件基金会,Inc.,59 Temple Place,Suite 330,波士顿,MA 02111-1307 USA。
原始代码的初始所有者是欧洲环境局(EEA)。Eau de Web创建的部分版权(C)2009归欧洲环境局所有。保留所有权利。
资金
EEA - 欧洲环境局(EU)
变更日志
2.0 - (2024-06-01)
重大变更:删除Plone 4 GenericSetup配置文件[avoinea - 参考 #151690]
重大变更:重命名Editing Progress ControlPanel和注册表[avoinea - 参考 #151690]
1.5 - (2023-06-01)
功能:Plone 6增加了编辑进度控制面板[Petchesi-Iulian - 参考 #151690]
1.4 - (2021-12-16)
更改:修复包分类器和python_requires[avoinea]
1.3 - (2021-06-21)
功能:引入了@@editing.progress.status浏览器视图,用于检查当前状态是否输入了所有字段,对工作流守卫很有用[ichim-david 参考 #124587]
1.2 - (2021-06-10)
更改:将工作流状态信息也添加到REST API中,这样我们就知道字段应为哪个状态而需要[ichim-david 参考 #124587]
1.1 - (2021-05-04)
更改:以字典的形式返回字段信息[ichim-david 参考 #124588]
更改:我们现在为每个字段导出一个字典列表,而不是列表的列表,这使得它更容易阅读和理解导出的内容[ichim-david 参考 #124588]
提供字段的编辑进度完成信息[ichim-david 参考 #124588]
1.0 - (2021-05-04)
初始发布
项目详情
eea.progress.editing-2.0.zip的哈希值
算法 | 哈希摘要 | |
---|---|---|
SHA256 | ee929677ad95a6a8039221062a6219af058de79e4ca607443d0291064696c913 |
|
MD5 | d13d3f738564d2692deddb870f8ede18 |
|
BLAKE2b-256 | 9a14e8c229947b3e25c90253a9f8d07a30c800938e8647aeca330d7fd3e92eb6 |