art-template语法

可以在模板引擎中加入自定义的函数;

template.defaults.imports.LocalShortDate = LocalShortDate;

在模板引擎中的用法:

{{rec.add_time|LocalShortDate}}

这样就可以在模板引擎中使用函数了

相关文章:

  • 2022-12-23
  • 2021-04-18
  • 2021-07-26
  • 2022-12-23
  • 2022-12-23
  • 2022-01-08
  • 2021-11-09
  • 2021-04-07
猜你喜欢
  • 2021-04-22
  • 2021-11-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-15
  • 2022-12-23
相关资源
相似解决方案