6 // TODO Fill in these fields
9 def title
= "ZK (3.0.7) for Grails"
10 def description
= '''\
11 Derived from Flyisland ZK Grails Plugin, This plugin adds ZK Ajax framework (www.zkoss.org) support into Grails applications
14 // URL to the plugin's documentation
15 def documentation
= "http://grails.org/Zk+Plugin"
18 // TODO Implement runtime spring config (optional)
21 def doWithApplicationContext
= { applicationContext
->
25 def doWithWebDescriptor
= { xml
->
26 // quick hack for page filtering
27 def pageFilter
= xml
.filter
.find
{ it
.'filter-name' == 'sitemesh'}
28 pageFilter
.'filter-class'.replaceBody('org.zkoss.zkgrails.ZKGrailsPageFilter')
30 def listenerElements
= xml
.'listener'[0]
33 'display-name' ("ZK Session Cleaner")
34 'listener-class' ("org.zkoss.zk.ui.http.HttpSessionListener")
38 def servletElements
= xml
.'servlet'[0]
39 def mappingElements
= xml
.'servlet-mapping'[0]
43 'servlet-name' ("zkLoader")
44 'servlet-class' ("org.zkoss.zk.ui.http.DHtmlLayoutServlet")
46 'param-name' ("update-uri")
47 'param-value' ("/zkau")
53 def urls
= ["*.zul", "*.zhtml", "*.svg", "*.xml2html"]
57 'servlet-name'("zkLoader")
65 'servlet-name' ("auEngine")
66 'servlet-class' ("org.zkoss.zk.au.http.DHtmlUpdateServlet")
71 'servlet-name'("auEngine")
72 'url-pattern'("/zkau/*")
77 def doWithDynamicMethods
= { ctx
->
78 // TODO Implement registering dynamic methods to classes (optional)
81 def onChange
= { event
->
82 // TODO Implement code that is executed when any artefact that this plugin is
83 // watching is modified and reloaded. The event contains: event.source,
84 // event.application, event.manager, event.ctx, and event.plugin.
87 def onConfigChange
= { event
->
88 // TODO Implement code that is executed when the project configuration changes.
89 // The event is the same as for 'onChange'.