Commit 680c6b17 authored by Jérome Perrin's avatar Jérome Perrin

getCategoryChildTranslatedCompactTitleItemList was using a non existant

display_id



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@17884 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 6ca52607
......@@ -375,7 +375,7 @@ class Category(Folder):
given list of base categories. Uses translated_compact_title as default method
"""
return self.getCategoryChildItemList(recursive=recursive,
display_id='translated_compact_title',
display_id='compact_translated_title',
base=base, **kw)
security.declareProtected(Permissions.AccessContentsInformation,
......
......@@ -753,6 +753,17 @@ class TestCMFCategory(ERP5TypeTestCase):
self.assertEquals([['', ''], ['The Title (the_id)', 'the_id']],
base_cat.getCategoryChildTitleAndIdItemList())
def test_20_CategoryChildCompactTitleItemList(self):
# Tests getCategoryChildCompactTitleItemList
base_cat = self.getCategoryTool().newContent(portal_type='Base Category')
cat = base_cat.newContent(portal_type='Category',
id='the_id', title='The Title', short_title='The T.')
self.assertEquals([['', ''], ['The T.', 'the_id']],
base_cat.getCategoryChildCompactTitleItemList())
self.assertEquals([['', ''], ['The T.', 'the_id']],
base_cat.getCategoryChildTranslatedCompactTitleItemList())
def test_21_AcquiredPortalType(self, quiet=quiet, run=run_all_test):
"""Test if acquired_portal_type works correctly."""
if not run : return
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment