在2个动作之前,使Interceptor处于Grails。
我们可以在Grails控制器的beforeInterceptor中定义2个不同的动作吗?我有一个下面的beforeInterceptor控制器:
def beforeInterceptor = [action:this.&debug]
def trimParams() {
params?.each { it = it.toString().trim() }
}
def debug() {
log.info(\"${actionUri} with params ${params}\")
}
如何将\'trimParams \'操作与\'debug \'操作一起添加到拦截器?我不知道确切的语法。非常感谢。
没有找到相关结果
已邀请:
1 个回复
旦彤
我没有尝试过,但可能会有所帮助。