evaluate subtype relations also for normal concepts (e.g. queries)
This commit is contained in:
parent
364a0c8c58
commit
f62a907590
3 changed files with 12 additions and 8 deletions
|
@ -387,8 +387,10 @@ class CreateConceptForm(CreateObjectForm):
|
||||||
include.remove('subtype')
|
include.remove('subtype')
|
||||||
parentType = self.target.conceptType
|
parentType = self.target.conceptType
|
||||||
subtypePred = self.conceptManager['issubtype']
|
subtypePred = self.conceptManager['issubtype']
|
||||||
|
tconcepts = (self.target.getChildren([subtypePred]) +
|
||||||
|
parentType.getChildren([subtypePred]))
|
||||||
types = [dict(token=ConceptTypeInfo(t).token, title=t.title)
|
types = [dict(token=ConceptTypeInfo(t).token, title=t.title)
|
||||||
for t in parentType.getChildren([subtypePred])]
|
for t in tconcepts]
|
||||||
if include or include is None:
|
if include or include is None:
|
||||||
return util.KeywordVocabulary(types + self.listTypes(include, ('hidden',)))
|
return util.KeywordVocabulary(types + self.listTypes(include, ('hidden',)))
|
||||||
return util.KeywordVocabulary(types)
|
return util.KeywordVocabulary(types)
|
||||||
|
|
|
@ -117,8 +117,8 @@ class NodeView(BaseView):
|
||||||
break
|
break
|
||||||
data.insert(1, dict(label=p.title,
|
data.insert(1, dict(label=p.title,
|
||||||
url=absoluteURL(p, self.request)))
|
url=absoluteURL(p, self.request)))
|
||||||
if self.virtualTarget:
|
if self.virtualTarget:
|
||||||
data.extend(self.virtualTarget.breadcrumbs())
|
data.extend(self.virtualTarget.breadcrumbs())
|
||||||
return data
|
return data
|
||||||
|
|
||||||
def viewModes(self):
|
def viewModes(self):
|
||||||
|
|
|
@ -33,11 +33,13 @@
|
||||||
<td style="white-space: nowrap; vertical-align: top; width: 10%"
|
<td style="white-space: nowrap; vertical-align: top; width: 10%"
|
||||||
i18n:translate="">You are here:</td>
|
i18n:translate="">You are here:</td>
|
||||||
<td>
|
<td>
|
||||||
<span style="white-space: nowrap"
|
<span>
|
||||||
tal:repeat="crumb crumbs">
|
<span style="white-space: nowrap"
|
||||||
<a tal:attributes="href crumb/url"
|
tal:repeat="crumb crumbs">
|
||||||
tal:content="crumb/label" />
|
<a tal:attributes="href crumb/url"
|
||||||
<span tal:condition="not:repeat/crumb/end"> > </span></span>
|
tal:content="crumb/label" />
|
||||||
|
<tal:delimiter
|
||||||
|
condition="not:repeat/crumb/end"> ></tal:delimiter></span> </span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
Loading…
Add table
Reference in a new issue