关系允许为原型引用的验证、创建和生存期定义规则集。

Products.Relations的Python项目详细描述


relations readme

overview


relations允许为原型引用的验证、创建和生存期定义规则集。
包含在每个规则集中的组件构成了实际的规则逻辑。


通过Web(TTW)创建和编辑。
易于添加实现自定义行为的组件。

安装


在Plone中,单击Plone设置中的"添加/删除产品"。然后从可用产品列表中选择
关系,然后单击"安装"。


库中的"ruleset"。现在选择一个合理的身份证明。注意
标识必须在
门户中的规则集之间是唯一的。


注意:通过规则集创建引用时,引用的
关系属性设置为规则集的
ID。没有什么不同查询引用对象时如何使用
原型引用api。
(但是,创建和删除引用的方式不同;即
通过函数"processor.process"。)

单击"添加新项"并添加基数
约束。输入"正好两个"作为标题,并选择"2"作为
最小和最大目标数。


此时,我们仍然需要另一个组件,以便我们可以实际
使用"是"规则集的子级。添加"portal type
constraint"并选择"unrestricted"作为标题。单击
"保存"按钮,然后单击刚刚出现的"关系"选项卡。
表单显示"编辑不受限制的关系",这意味着我们可以从这里添加和删除"是"引用的子项,从
门户类型约束"无限制"到任何可引用门户
对象。

需求

archetypes>;=1.4.0
python 2.4


另请参阅


其他文档位于
文件系统上的产品文档/目录中。


credits

此代码是为zuccaro项目创建的。zuccaro是马克斯·普朗克艺术史研究所hertziana图书馆为人文学科开发的数据库框架。有关进一步的
信息,请访问http://zuccaro.biblhertz.it/

2008-09-10 cris ewing(cewing at u dot washington dot edu)



门户目录编目的左共享对象(关联类)。这导致plone的共享ui中调用的
方法抛出属性错误。(有关详细的
讨论,请参见
https://weblion.psu.edu/trac/weblion/ticket/531)


taged 0.8.1 Bugfix release,将鸡蛋贴到芝士店。

2008-05-28亚历克斯·克拉克(aclark at aclark dot net)



2007-06-25詹斯·克莱因(jens at bluedynamics dot com)

我们在每个连接和断开连接的关系中添加了事件。
在这个实现中,一些清理是完成。
这些事件由关系索引用作示例,但您也可以订阅它们以完成连接或断开连接时需要完成的任务。


2007-02-25 Philipp Auersperg(Bluedynamics的Phil)。com)

allowedtypesbyinterface现在还支持zope3接口

<2006-03-30 daniel nouri<;daniel(dot)nouri at gmail(dot)com>;

utils.py(adddelete vocab):我将"adddelete"vocab"脚本
放到文件系统中,同时在上下文中添加对
``modifyportalcontent`的检查。python脚本仍然存在,但它现在只是一个别名。还添加了
脚本没有的测试。


2006-03-01 jens klein<;jens@bluedynamics.com>;


field.py:i18n在archetypes 1.4中移动到
products.archetypes.generator.i18n


2006-02-04 daniel nouri<;dpunktnpunkt at web.de>;


测试:添加更多的测试检查每三个
(即相同的源、目标、关系)是否有多个ref工作。(请注意,
这当前需要
原型的dpunktnpunkt multipleref分支,并且默认情况下是不允许的。

2006-01-28 daniel nouri<;dpunktnpunkt at web.de>;

components/inverse.py(inverseimplicator.implyondisconnect):
改进实现。


2006-01-26 daniel nouri<;dpunktnpunkt at web.de>;

components/inverse.py(inverseimplicator):不再假设两个对象之间只有一个具有相同关系的引用的新实现。已经存在(源、目标、
关系)的三元组。

config.py(每个三元组允许多个引用):为
referenceengine.addreference的updatereferences参数添加了配置选项。默认情况下,它处于关闭状态。

(iprimaryincipator.connect):添加了元数据关键字参数,该参数允许您为引用提供属性。请注意,这是
可能会更改的,并且可能会从公共的
api中移出。


interfaces.py(irereferenceconnectionprocessor.process)"`disconnect`"的元素
也可能是引用对象的uid。

2005-11-22 jens klein<;jens@bluedynamics.com>;

fixed隐藏导航和选项卡中的工具

<2005-08-10 daniel nouri<;dpunktnpunkt at web.de>;


ruleset.py(library.\u implements\uu):修复了错误的
iactionprovider库实现。

<2005-07-20 daniel nouri<;dpunktnpunkt at web.de>;

components/cardinality.py:david baehrens应用的修补程序,它允许我们用cardinalityconstraint定义源基数。

<2005-07-07 daniel nouri<;dpunktnpunkt at web.de>;

ruleset.py(xmlImportExport.schema):使用访问器作为默认方法。


utils.py(allowedTypesByface.\u verifyobjectPaste):使用PortalFolderBase的验证对象Paste,因为我们实际上没有从PortalFolder继承。(testruleset.testrenamerulesetinlibrary):
导入事务而不是使用全局get-u事务。


<2005-06-03 daniel nouri<;dpunktnpunkt at web.de>;

components/contentreference.py(contentreferencefinalizer):
添加了crf的主要属性。

<2005-05-28 daniel nouri<;dpunktnpunkt at web.de>;


extensions/install.py(install_tools):不要将库添加到
metatypesnotolist。

<2005-05-18 danielnouri<;dpunktnpunkt at web.de>;


skins/relations/relations_adddelete_vocab.py,model/*,tests/relations_sample.xml,
tests/testxmlimportexport.py,doc/overview.txt,interfaces.py,ruleset.py,field.py:
合并的关系_xml_导入导出分支。将导入/导出功能添加到规则、规则集、库和规则集集合。

<2005-02-21 daniel nouri<;dpunktnpunkt at web.de>;

interfaces.py(iruleset.getcomponents):这将替换以前的
private\u filterbyinterface。



components/types.py(portalTypeConstraint.getSearchTerms):
遵守ivarableProvider.getSearchTerms。


2005-02-16 daniel nouri<;dpunktnpunkt at web.de>;

doc/overview.txt:doctest示例。

2005-02-06 daniel nouri<;dpunktnpunkt at web.de>;



interfaces.py:清理了一点。

<2005-02-02 daniel nouri<;dpunktnpunkt at web.de>;


field.py:通过删除referencefield的重新实现的方法来精简field.py。这个领域的目的仍然需要明确。见XXX评论。

2005-01-27 daniel nouri<;dpunktnpunkt at web.de>;

ruleset.py(ruleset collection):实现了"ruleset collection"
类型,该类型允许对库中的规则集进行分类。


ruleset.py(rulesetawarecontainer):分解方法类
rulesetawerencainer。

2005-01-25 daniel nouri<;dpunktnpunkt at web.de>;

*:大规模重命名。jig'变为'ruleset',
'referencejigregistry'变为'library'等。这些更改不仅影响门户类型名称,还影响类和变量。
这些更改不向后兼容(即,无法迁移),而且未经彻底测试。

2005-01-13daniel nouri<;dpunktnpunkt at web.de>;




skins/relations/relations\u listrefs.py:为
"relations\u form"添加了帮助程序脚本,该脚本现在列出了现有的ref及其
操作。"关系表单"仍需改进。

interfaces.py(irereferenceactionprovider):添加了
ijigcomponent的子类型。

<2005-01-08 daniel nouri<;dpunktnpunkt at web.de>;

skins/relations/relations\u form.cpt:添加了一个将
列出现有引用的概述表单。


skins/relations/relations\u adddelete.cpt:从relations\u form重命名。


extensions/install.py(install_tools):安装时的固定元类型列表功能,它没有使用正确的元类型。

<2005-01-02 daniel nouri<;dpunktnpunkt at web.de>;

components/contentreference.py,tests/testcomponents.py:添加了
组件"contentreferencefinalizer",它将门户对象
与引用关联起来。



2005-01-01 daniel nouri<;dpunktnpunkt at web.de>;

extensions/install.py(install_tools):修复了隐藏在navtree中的问题;检查"portal_properties.navtree_properties"是否存在,以确保不中断所有测试。:-)

br a in.py(makebrainaggrfrombrain):当在源中找不到元数据时,会有更详细的异常消息


2004-10-21 daniel nouri<;dpunktnpunkt@web.de>;

tests/*:删除对cmftestcase.setupcmfsite()的调用,这些都做得太早了。


2004-10-15 daniel nouri<;dpunktnpunkt@web.de>;

许可证:添加了版权信息。

jig.py(referencejigregistry.\u setobject):复制的引用jig现在已正确注册。


2004-10-05 daniel nouri<;dpunktnpunkt@web.de>;

schema.py(referencejigschema):将"about"字段添加到referencejig的
架构中。

<2004-10-04 daniel nouri<;dpunktnpunkt@web.de>;

索引似乎已损坏。


这修复了重命名jig将导致查找失败的错误。

readme.txt:已修改的自述文件。另外,一些小的代码会根据新的术语进行更改。


2004-10-02 daniel nouri<;dpunktnpunkt@web.de>;



jig.py(referencejig.\u afterrename):为在重命名时属于我们的引用设置关系属性。


jig.py(referencejig registry.\u setobject):仅添加函数
以帮助查找何时重命名的reference jig。

jig.py(referencejig.implyonconnect):在连接时,我们现在在jig和ref之间建立一个引用。


tests/testjig.py(testreferencejig.testrenamejiginregistry):test
ref relationship attrs change'
行为。

ref catalog search修复错误。


2004-09-25 daniel nouri<;dpunktnpunkt@web.de>;

tests/test jig.py(test jig registry.testrenameregistry):添加了test
以确保不重命名jig注册表。


,而不是setattr。这将再次修复夹具和组件的重命名。


2004-09-24 daniel nouri<;dpunktnpunkt@web.de>;


components/types.py(portaltypeconstraint.makevocabulary):修复了筛选词汇的行为将不同于创建词汇的错误。daniel nouri<;dpunktnpunkt@web.de>;

utils.py(allowedtypesbyiface.\u verifyobjectpaste):一个临时的、相当粗糙的解决方案,可以解决阻碍重命名jig
和组件的错误。
allowedtypesbyiface感觉越来越像一个黑客。

tests/testjig.py(testreferencejig.testrenamejiginregistry):添加了
测试jig/组件重命名错误。


"参考目录"。

2004-09-20丹尼尔·努里<;dpunktnpunkt@web.de>;

skins/relations/relations_form_security.vpy:在使用"relations_form"时添加了对
"修改门户内容"权限的检查。


skins/relations/relations_form_vocab.py:删除了pt之外的词汇逻辑。结果是这个脚本有些臃肿。

brain.py(makebrainaggregate):公开了函数。

"modify portal content"权限。

utils.py(isreferenceable):添加了新的TTW方法来帮助
"关系"窗体"vocab"。


2004-09-19 daniel nouri<;dpunktnpunkt@web.de>;

"允许访问未受保护的子对象",使用
"relations_form_validate"修复严重错误。


skins/relations/relations_form.cpt:在
橙色框中显示错误消息。

<2004-09-16 daniel nouri<;dpunktnpunkt@web.de>;

jig.py(referencejigRegistry.listActions):使referencejigRegistry成为行动提供者。所有可引用对象都有一个"relations"操作
现在。


processor.py(process):将函数公开。


skins/relations/*,todo:添加了用于通过
"processor.process"创建引用的表单。已删除此类窗体的TOdo项,为i18n添加了一个


jig.py(referencejigregistry.invokefactory):将jig的自动注册从setobject移到invokefactory。

错误,如果允许目标类型,此方法将返回[]是
空列表。

2004-09-10 daniel nouri<;dpunktnpunkt@web.de>;


components/cardinality.py(cardinalityconstraint.dovalidate):重命名为
validate to dovalidate以避免与"baseobject.validate"发生名称冲突。

2004-09-07 daniel nouri<;dpunktnpunkt@web.de>;

jig.py(referencejig,referencejigregistry):添加了类docstring。
zope因此返回404s。

todo,jig.py(referencejig,referencejigregistry):reference jig的
和referencejigregistry的类型标题现在分别是"reference rulebook"和
"rulebook library"。

2004-09-06 daniel nouri<;dpunktnpunkt@web.de>;

interfaces.py,jig.py,components/*:从
all中删除了"jig"参数调用ijigcomponents。扩展ijigcomponent并添加了一个新的超类jigcomponentbase,它提供了一个"getjig"方法。

jig.py,interfaces.py(irereferencejig):irereferencejig.makevocabulary
现在接受一个可选的"targets"参数。目标,其默认值为none,被转发到第一个ivocarableprovider。
不需要对ivocarableprovider进行任何更改。

和invokeFactory行为。方法"allowedcontenttypes"以前是一个模块级函数。我不得不添加invokefactory。

jig.py(jigcomponentbase):添加了global_allow=0。默认情况下,子类现在只能在referencejigs中添加。


todo:添加了两项。


2004-08-22 daniel nouri<;dpunktnpunkt@web.de>;

processor.py(process):用可选的connect和disconnect参数将处理器的接口从单独的
processconnection和processdisconnection更改为一个进程函数



更改了7个测试以反映这些更改。

2004-08-19 daniel nouri<;dpunktnpunkt@web.de>;

components/inverse.py:添加了"inverse隐式"组件。

inverse implicator。


2004-08-17 daniel nouri<;dpunktnpunkt@web.de>;

components/cardinality.py(cardinalityconstraint):添加了
cardinalityconstraint。

cardinalityconstraint。

components/types.py(interfaceconstraint):添加了interfaceconstraint:
a validator/vocab基于PortalTypeConstraint的提供程序,它检查
接口而不是类型。



2004-08-16 daniel nouri<;dpunktnpunkt@web.de>;

processor.py:如果抛出异常,则使用子事务并中止它以同时用于
processconnection和processdisconnection。


components/types.py:限制
源和目标类型的验证器和vocab提供程序。

tests/testcomponents.py:test模块组件中的组件。

2004-08-15 daniel nouri<;dpunktnpunkt@web.de>;


tests/common.py(createobjects,createjig):从
testjig.py中分解出来。


tests/testprocess.py:测试processconnection和
processdisconnect打开。

2004-08-11 daniel nouri<;dpunktnpunkt@web.de>;

todo:添加文件。

相应地更新了接口和测试。


2004-08-10 daniel nouri<;dpunktnpunkt@web.de>;

tests/testjig.py(testjig registry.testallowedcontenttypes):已添加。

ireferencejig接口。




extensions/install.py,extensions/utils.py:将referencejigregistry添加到plone configlets。


2004-08-03 daniel nouri<;dpunktnpunkt@web.de>;


接口。py:修改了iprimaryincialator的connect
和disconnect方法的行为。如果没有添加或删除引用,则返回none,因为引用已经存在或已分别删除了



tests/testjig.py(testreferencejig.testDefaultPrimaryImplicator):
已添加。


2004-08-01 daniel nouri<;dpunktnpunkt@web.de>;

jig.py(referencejigRegistry):将referencejigRegistry设置为at
basefolder而不是ofs.folder。referencejigregistry将用作添加jig的folderish ui。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java JetXcel在关闭可写工作簿之前修改多个单元格   java saveMyProfile计算false 2次   java在安卓系统中如何在长时间内让现在和时间变得不同   java生成大小写字母   java set MainClass标头,带有来自mainClassName的渐变   java无法仅为此网站拖放selenium   java如何使HttpURLConnection从servlet响应中获取标头?   java如何将cachecontrol添加到@RestController servlet路径?   java如何在jasper report中调用实体方法?   java中的“<<”运算符   java在Android应用程序中添加按位置搜索功能   使用<%@page isaligned=“false”%%时,java静态属性必须是字符串文字