Commit b30ca5c4 authored by Amos Latteier's avatar Amos Latteier

Changed helpValues to only report ProductHelps that actually have help. Also...

Changed helpValues to only report ProductHelps that actually have help. Also added support for smarter help registration.
parent b38dd699
......@@ -116,10 +116,13 @@ class HelpSystem(Acquisition.Implicit, ObjectManager, Item, Persistent):
self.id=id
def helpValues(self, spec=None):
"ProductHelp objects of all Products"
"ProductHelp objects of all Products that have help"
hv=[]
for product in self.Control_Panel.Products.objectValues():
hv.append(product.getProductHelp())
productHelp=product.getProductHelp()
# only list products that actually have help
if productHelp.helpValues():
hv.append(productHelp)
return hv
# Seaching does an aggregated search of all ProductHelp
......@@ -169,6 +172,8 @@ class ProductHelp(Acquisition.Implicit, ObjectManager, Item, Persistent):
meta_type='Product Help'
icon='p_/ProductHelp_icon'
lastRegistered=None
meta_types=({'name':'Help Topic',
'action':'addTopicForm',
'permission':'Add Documents, Images, and Files'},
......
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