IList<DictItemInfo> GetItemsByDictID(int intDictID[/string strDictName])

定义和用法

获取指定字典的子项列表

语法

${cms.GetItemsByDictID(int intDictID[/string strDictName])}
参数 描述
int intDictID[/string strDictName] 字典ID或者字典名称

返回值

返回指定字典的子项列表。

提示和注释

提示:需要在后台管理中设置系统配置-数据字典。

例子

            #foreach($item in ${cms.GetItemsByDictID(1)})
                键值对:${item.KeyName} - ${item.KeyValue} <br />
            #end
        

输出:

            键值对:China - 中国
            键值对:American - 美国