【发布时间】:2014-02-01 02:47:17
【问题描述】:
I'm uploading files 通过动态数据列表Document 字段。现在我想允许匿名用户下载这些文件,但目前他们只看到文件名而没有文件链接:
您对如何实现这一目标有任何建议吗?
编辑:
正如@Mark 建议的那样,我创建了 Display Templated 并在 freemarker 编辑器中选择了Display and Media 字段。它在我的 .ftl 文件中生成了以下代码:
<a href="${ddmUtil.getDisplayFieldValue(themeDisplay, cur_record.getFieldValue("Documents_and_Media1422", locale), cur_record.getFieldType("Documents_and_Media1422"))}">
${languageUtil.format(locale, "download-x", "Documents and Media")}
</a>
我已保存更改并刷新了页面。它给了我以下错误:
Expression cur_record is undefined on line 9, column 3 in 10157#10197#16569.
cur_record 不应该由 liferay 填充吗?
【问题讨论】:
标签: java api download liferay portal