类 CmsDictionaryExcludeValueDirective

所有已实现的接口:
Directive, HttpDirective, freemarker.template.TemplateDirectiveModel, freemarker.template.TemplateModel

@Component public class CmsDictionaryExcludeValueDirective extends AbstractTemplateDirective
dictionaryExcludeValue 数据字典排除值查询指令

参数列表

parameter list

パラメータリスト

  • dictionaryId:数据字典id
  • excludeDictionaryId:排除的字典
  • value 字典值,结果返回objectCmsDictionaryExcludeValue
  • values 多个的字典值,逗号或空格间隔,当value为空时生效,结果返回map(id,object)

使用示例

usage example

使用例

<@cms.dictionaryExcludeValue dictionaryId='data' excludeDictionaryId='data1' value='data1'>${object.excludeValues}</@cms.dictionaryExcludeValue>

<@cms.dictionaryExcludeValue dictionaryId='data' excludeDictionaryId='data1' values='1,2'><#list map as k,v>${k}:${v.excludeValues}<#sep>,</#list></@cms.dictionaryExcludeValue>

  <script>
   $.getJSON('${site.dynamicPath}api/directive/cms/dictionaryExcludeValue?dictionaryId=data&excludeDictionaryId=data1&value=1', function(data){
     console.log(data.excludeValues);
   });
   </script>
 
  • 字段详细资料

  • 构造器详细资料

    • CmsDictionaryExcludeValueDirective

      public CmsDictionaryExcludeValueDirective()
  • 方法详细资料

    • execute

      public void execute(RenderHandler handler) throws IOException, freemarker.template.TemplateException
      参数:
      handler -
      抛出:
      IOException
      freemarker.template.TemplateException