Documentation
This is a "getter"
TopicFunction that returns a list of known
TopicTypes
in a given web. Use it to create a selection in
DataForms for the TopicType formfield.
It adds the "none" type so that you can have (temporarily) un-typed topics. The
type "TopicType" is added
hardcoded so that you don't have to rely on that type
being present in your web and to allow bootstrapping a type system in a web from
scratch on as you will be able to create an initial TopicType TopicType this way.
Parameters
- WEBS: list of webs to search for TopicTypes, defaults to BASEWEB
- EXCLUDE: expression to exclude types (optional)
- ADDITION: types that are listed additionally (optional)
Implementation
%STARTINCLUDE%none, %FORMATLIST{
"TopicType, %IF{"defined ADDITION" then="%ADDITION%, "}% %FORMATLIST{
"%WEBS{default="%BASEWEB%"}%"
format="$percntDBQUERY{\"TopicType=~'\bTopicType\b' OR@Target.TopicType=~'\bTopicType\b'\"
web=\"$1\"
hidenull=\"on\"
separator=\", \"
format=\"$dollartopic\"
}$percnt"
}%"
%IF{"defined EXCLUDE" then="exclude=\"%EXCLUDE%\""}%
format="$1"
separator=", "
sort="on"
unique="on"
}%%STOPINCLUDE%
Test
none, DataForm, DataFormAttribute, DocuTopic, FooBar, TopicFunction, TopicStub, TopicTemplate, TopicType, TopicView, WebTool, WikiApplication, WikiTopic
none, ApplicationLicense, ApplicationTopic, DataForm, DataFormAttribute, DocuTopic, TopicFunction, TopicStub, TopicTemplate, TopicType, TopicView, WebTool, WikiApplication, WikiTopic