[Checkins] SVN: GenericSetup/trunk/ - fixed 'indexed_attr' import
(http://www.zope.org/Collectors/CMF/436)
Yvo Schubbe
y.2006_ at wcm-solutions.de
Fri May 19 07:27:25 EDT 2006
Log message for revision 68186:
- fixed 'indexed_attr' import (http://www.zope.org/Collectors/CMF/436)
Changed:
U GenericSetup/trunk/CHANGES.txt
U GenericSetup/trunk/ZCTextIndex/exportimport.py
U GenericSetup/trunk/ZCTextIndex/tests/test_exportimport.py
-=-
Modified: GenericSetup/trunk/CHANGES.txt
===================================================================
--- GenericSetup/trunk/CHANGES.txt 2006-05-19 08:05:54 UTC (rev 68185)
+++ GenericSetup/trunk/CHANGES.txt 2006-05-19 11:27:24 UTC (rev 68186)
@@ -2,6 +2,9 @@
GenericSetup 1.2 (unreleased)
+ - ZCTextIndex handler: Fixed 'indexed_attr' import.
+ (http://www.zope.org/Collectors/CMF/436)
+
- docs: Added 'Registering Profiles' section to profiles.txt.
- Added support for PageTemplate import/export, modeled closely after
Modified: GenericSetup/trunk/ZCTextIndex/exportimport.py
===================================================================
--- GenericSetup/trunk/ZCTextIndex/exportimport.py 2006-05-19 08:05:54 UTC (rev 68185)
+++ GenericSetup/trunk/ZCTextIndex/exportimport.py 2006-05-19 11:27:24 UTC (rev 68186)
@@ -107,7 +107,7 @@
if child.nodeName == 'indexed_attr':
indexed_attrs.append(
child.getAttribute('value').encode('utf-8'))
- self.context.indexed_attrs = indexed_attrs
+ self.context._indexed_attrs = indexed_attrs
self.context.clear()
node = property(_exportNode, _importNode)
Modified: GenericSetup/trunk/ZCTextIndex/tests/test_exportimport.py
===================================================================
--- GenericSetup/trunk/ZCTextIndex/tests/test_exportimport.py 2006-05-19 08:05:54 UTC (rev 68185)
+++ GenericSetup/trunk/ZCTextIndex/tests/test_exportimport.py 2006-05-19 11:27:24 UTC (rev 68186)
@@ -34,6 +34,7 @@
_ZCTEXT_XML = """\
<index name="foo_zctext" meta_type="ZCTextIndex">
<indexed_attr value="foo_zctext"/>
+ <indexed_attr value="baz_zctext"/>
<extra name="index_type" value="Okapi BM25 Rank"/>
<extra name="lexicon_id" value="foo_plexicon"/>
</index>
@@ -83,6 +84,9 @@
return ZCTextIndexNodeAdapter
+ def _populate(self, obj):
+ obj._indexed_attrs = ['foo_zctext', 'baz_zctext']
+
def setUp(self):
import Products.GenericSetup.ZCTextIndex
from Products.ZCTextIndex.ZCTextIndex import PLexicon
More information about the Checkins
mailing list