随笔分类 - FreeMarker
摘要:GridFS是MongoDB提供的用于持久化存储文件的模块 其中fs.chunks中放块文件 代码示例 @Autowired GridFsTemplate gridFsTemplate; //将一个模板文件存到GridFS中 @Test public void GridFsTemplate() th
阅读全文
摘要:两种方法 一、<#if></if> 判断是否为空 例子: FTL文件代码 <#-- 空值处理 判断某值为空用 ?? 存在变量返回true --> <#if stus ??> <#list stus as stu > <tr> <td>${stu_index + 1}</td> <td>${stu.n
阅读全文
摘要:题记:初步写了下感觉和JSP差不多,不过好像功能要强一些 1. 首先我是在springBoot项目里写的,最开始在yml文件中配置一下 freemarker: cache: false #关闭模板缓存,方便测试 template_update_dalay: 0 #检查模板更新延迟时间,设置为0表示立
阅读全文