我究竟做错了什么?我无法获得要在 Liferay 动态数据列表 portlet 中显示的值。以下是模板代码。目前,标题后没有显示任何内容。但是,我在呈现的 HTML 中看到了结束表标记。
#set ($ddlRecordService = $serviceLocator.findService('com.liferay.portlet.dynamicdatalists.service.DDLRecordLocalService'))
#set ($recordSetId = $getterUtil.getLong($reserved_record_set_id.data))
#set ($records = $ddlRecordService.getRecords($recordSetId))
<table class="table table-striped">
<caption>Audio files listing of FDR speeches</caption>
<thead>
<tr>
<th>Date</th>
<th>Description</th>
<th>Tape information</th>
</tr>
</thead>
<tbody>
#foreach($record in $records)
#set ($audioDate = $record.getField("audioDate").getValue())
#set ($audioDesc = $record.getField("audioDesc").getValue())
#set ($audioLink = $record.getField("audioLink").getValue())
<tr>
<td>$audioDate</td>
<td>$audioDesc</td>
<td>$audioLink</td>
</tr>
#end
</tbody>
</table>