How to reference submodule non-java resources (templates, js, css, etc)
I have playframework application that uses my playframework module. There are some static content and views/tags in the module. My app works fine when I run it in dev mode. But when deployed to tomcat6, it results in
TemplateNotFoundException: Tem开发者_开发技巧plate not found : tags/templateFromModule.html
or tags/templateFromModule.tag
I can find such template in deployed application in: WEB-INF\application\precompiled\templates\from_module_myModuleName\app\views\tags\
Please help
In your module define your static resources on /public/MODULENAME/javascripts/foobar.js
, then from your application you can do @{'/public/MODULENAME/javascripts/foobar.js'}
. Don't forget to turn off the /public
route from your module when importing into the application.
精彩评论