DictItemInfo GetDictItem(int intDictID[/string strDictName], string strItemKey)

定义和用法

获取字典信息

语法

${cms.GetDictItem(int intDictID[/string strDictName], string strItemKey)}
参数 描述
int intDictID[/string strDictName] 字典ID或者字典名称
strItemKey 子项键

返回值

返回指定字典某个子项信息信息。

提示和注释

提示:需要在后台管理中设置系统配置-数据字典。
注释:子项键是唯一的。

例子

            #set($dictitem=$cms.GetDictItem(2,"Beijing"))
            字典子项键 : $dictitem.KeyName <br />
            字典子项值 : $dictitem.KeyValue
        

输出:

            字典子项键 : Beijing 
            字典子项值 : 北京