Grails Tips (Update@2011-05-13)
程序员文章站
2022-05-19 21:38:25
...
1. quartz 插件的Job必须配置一个static trigger = {}, 否则会一分钟运行一次.
2. Grails项目导入到eclipse后,提示"The project was not built since its build path is incomplete. Cannot find the class file for groovy.lang.GroovyObject. ",解决方法: Grails Tools ->Refresh Dependencies
3.Griffon项目导入eclipse的方法:
- griffon integrate-with --eclipse
- griffon install-plugin eclipse-support
- griffon eclipse-update
- eclipse --> import existing project
- 最新的插件,还需要在eclipse的buildpath中新建GRIFFON_HOME和 IVY2_CACHE这2个变量
- 并且编辑.classpath文件,替换路径为 IVY2_CACHE
- http://*.com/questions/4533954/griffon-dont-create-eclipse-project-and-classpath-files
4.Domain排序的时候要注意order只接受小写,即desc,而不能识别DESC,用extjs的同学要注意自己转小写。
5.修改插件目录为项目目录: 在BuildConfig中加入grails.project.plugins.dir="plugins"
6.测试的时候,输出prinltn到控制台: test-app integration:integration -echoOut -echoErr -Dfile.encoding=UTF-8
7.测试的时候,中文乱码:修改%GRAILS_HOME%/lib/junit-frames.xsl以及junit-noframes.xsl中<xsl:output method="html" indent="yes" encoding="UTF-8"/>
TO BE CONTINUED...