Code Monkey home page Code Monkey logo

joergrech / kickstartwithbootstrap Goto Github PK

View Code? Open in Web Editor NEW
65.0 17.0 52.0 3.69 MB

Kickstart is an extension for Grails in order to start your project with a good looking frontend. It is intended to be used in rapid application scenarios such as a Startup Weekend or a prototyping session with a customer. This plugin provides adapted scaffolding templates for standard CRUD pages using Twitter's CSS Framework Bootstrap and offers some basic pages for a web site.

Groovy 16.60% CSS 54.21% JavaScript 29.19%

kickstartwithbootstrap's Introduction

Home on Grails.org

Introduction

Kickstart is a plugin for Grails in order to start your project with a good looking frontend. It is intended to be used in rapid application scenarios such as a Startup Weekend or a prototyping session with a customer. This plugin provides the following feature:

  • Adapted scaffolding templates for standard CRUD pages using the Bootstrap web page template by Twitter.
  • Initial set of webpages to describe the website (e.g., about.gsp, contact.gsp, and systeminfo.gsp)
  • A language picker that adapts to the available property files in the i18n directory. Using the FamFamFam flag icons.
  • A minimal console logging filter (KickstartFilter.groovy) to help understand which actions are called and params are transmitted

Technologies

Bootstrap

Browser Support

Tech Foundation

Bootstrap Browser Support Technologies Used
Kickstart uses Bootstrap to render web pages. Bootstrap is made by Mark Otto (@mdo) and Billy Gates (@fat). Bootstrap is designed to help people of all skill levels as a complete kit or to start something more complex. Bootstrap is tested and supported in major modern browsers like Chrome 14, Safari 5+, Opera 11, Internet Explorer 7, and Firefox 5. Bootstrap is based on elements of HTML 5, CSS 3, Javascript 1.8, and jQuery 1.7 with progressively enhanced components to enable a responsive design of the website. Kickstart is built using Groovy 2.0 and Java 7 integrated into the Grails 2.1 framework.

Usage

After installation you must call the kickstart script "grails kickstart", which will copy several files into your project.

  grails kickstart

Afterwards create your domain classes (or copy them into the project) and generate controllers and views - they will now use the Bootstrap framework!

Consequences!

The Kickstart script will (after asking you) overwrite a few files in the conf, src, and views directories of your project - you should use it only on fresh new Grails projects.

Affected files and directories (as of version 0.8.0; see script/Kickstart.groovy for current procedure):

  • conf/UrlMappings.groovy
  • conf/Config.groovy (will only get one line appended)
  • src/templates
  • /views/_common (contains common GSP entries such as buttons or modals)
  • /views/_errors (contains error GSP for 404, 500, etc.)
  • /views/_menu (contains menus or submenus)
  • /views/home (contains the index.gsp)
  • /views/layouts (contains layout files)
  • /views/siteinfo (contains separated or static pages such as about.gsp)
  • /views/index.gsp will be deleted!
  • /views/error.gsp will be deleted!

Configuration

Since version 0.9 two config variables are available and can be set in Config.groovy:

  • kickstart.build.calculate can be used to disable the calculation of build numbers and defaults to true
  • kickstart.metrics.calculate can be used to disable the calculation of metrics and defaults to true
Furthermore, the views can be configured using the following settings / variables, which have to be defined in the <head></head> section with the scope "request". An exemplary use of this can be found in the file login/auth.gsp.

Currently, the following settings for the views are supported:

  • layout_nomainmenu to remove the main menu (e.g., containing "Home") in the file "_content_grid.gsp"
  • layout_nosecondarymenu to remove the secondary menu (e.g., containing "List") in the file "_content_grid.gsp"
  • layout_noflashmessage to hide the general presentation of the flash message in the file "_content_grid.gsp"
Similarily, the footer and header can be overwritten (or removed) using sitemesh's pageProperties
  • page.header to define the header by inserting <content tag="page.header'">...</content> in the view (gsp)
  • page.footer to define the footer by inserting <content tag="page.footer'">...</content> in the view (gsp)

Developer Notes

Please note that the datepicker can handle dates after the year 9999 while most databases (e.g., mysql) handle dates with 4-number years. This might result in date that cannot be stored (such as "01/02/20135") and in Exceptions such as "MysqlDataTruncation: Data truncation: Incorrect datetime value: '20135-02-01 00:00:00'" (@see issue #31). If you want to change this behaviour please have a look in the file "src/groovy/CustomDateEditorRegistrar.groovy" and set lenient to false (However, this will also invalidate years before 1000)

Terms of Use

  • Web Layout: Bootstrap 3.0.2, from Twitter Licensed under the Apache License v2.0. Documentation licensed under CC BY 3.0. (@TwBootstrap , http://twitter.github.com/bootstrap/)
  • Datepicker: Datepicker for Bootstrap, Copyright 2012 Stefan Petre, Improvements by Andrew Rowls, Licensed under the Apache License v2.0
  • Flag Icons: FamFamFam Flag Icons by Mark James. They are "available for free use for any purpose with no requirement for attribution".
  • Kickstart Plugins: Code licensed under the Apache License v2.0. Documentation licensed under CC BY 3.0.

Backlog: Work required / Problems

1.x.1 Fix for Date binding (currently, the date binding does not work)
1.x.2 Fix for DatePicker (currently, the datepicker requires jQuery 1.8.3)
1.x.3 Fix for index vs list actions (currently, both are supported)

Changelog

1.1.0 Fresh setup on a newly created Grail 2.3.5 plugin project. Update to Grails 2.3.5.
1.0.5 Removed dependency for Font-Awesome (Bootstrap uses Glyphicon's Icon-Font now)
1.0.4 Correction of "alert-error" into "alert-danger" - changed in Bootstrap 3 (Tip by Leo Bartoloni)
1.0.3 Fix for display:none in scaffolding (Merged by "stlhrt")
1.0.0 Upgrade to Grail 2.3.4
0.9.9.1 Fixed missing search view. Integrated cleanup by Burt Beckwith.
0.9.9 Upgraded to Bootstrap 3.0.2.
0.9.8 Upgraded to Grails 2.2.4. Updated several plugin dependencies. Added Flag for China (zh.png). Updated Datepicker plugin.
0.9.7 Integrated fixes by Craig Sherstan (csherstan)
0.9.6 Updated to Bootstrap 2.3.1 with lesscss 1.3.3
0.9.5 Reduced to the max: removed skin/layout switching. Removed build and metrics calculation. Works on PAAS with less files.
0.9.4 Integrated Font Awesome using the Grails Font Awesome Resources Plugin by Eamonn O'Connell
0.9.3 Upgrade to patched Bootstrap 2.3.0 (had to partially downgrade mixins.less to 2.2.2). Fixed problem with hibernate plugin dependency when using Grails versions less than 2.2.0.
0.9.2 Fixed problem with less file handling if resource plugin is disabled.
0.9.1 Added views for security (prepared for spring security: auth.gsp and denied.gsp). Integrated configuration settings for views. Updated several missing I18N codes.
0.9.0 Added config switches to calculate build numbers and metrics. Updated to Bootstrap 2.2.2 (2.3 has currently compilation errors with lesscss).
0.8.9 Fixed Bug with CloudFoundry and Tomcat which (now) need references to the plugin containing resources (e.g., images)
0.8.8 Fixed Bug with i18n directory when deploying. Removed domain Object for demo page.
0.8.7 Improved the date binding to use default.date.datepicker.format or default.date.format (removing non-Date items).
0.8.6 Changed solution for Less compilation problem (Switch is now in KickstartResources.groovy only). Fixed problem of SkinA alternative in responsive mode. In production mode only one skin is used.
0.8.5 Fixed a problem with CloudFoundry & Less: running in production will not compile less anymore but switch to files directly.
0.8.3 Introduced a demo page with all fields used by the scaffolding mechanism.
0.8.2 Corrected missing copy of resources.groovy.
0.8.1 Fixed error when copying UrlMappings.groovy, which was not packaged into the plugin.
0.8.0 Integrated less templates of two Bootstrap based designs. Corrected links in language selector and config menus.
0.7.2 Integrated a Bootstrap-based checkbox in the taglib and scaffolding templates.
0.7.1 Corrected datepicker problem with Java representation with month. Corrected missing ID in links to edit-actions.
0.7.0 Updated to Bootstrap 2.1.1 and Grails 2.1. Included FamFamFam icons for flags in language selector. Reorganized file structure for views.
0.6.1 Minor bug fix in _Events.gsp script.
0.6.0 Integration of Bootstrap DatePicker. Uses Grails 2.0 files as base for scaffolding, etc. Cleanup of code and scripts.
0.5.7 Added script to calculate or retrieve build numbers.
0.5.6 Empty commit to test Grails plugin publish mechanism
0.5.5 Minor bugfix (missing import) and correction of KickstartWithBootstrapGrailsPlugin.groovy
0.5.4 Added measurement of time to simple console logging in KickstartFilters
0.5.3 Improvement of error.gsp
0.5.2 Cleanup of code and scripts. Improvement of I18N
0.5.1 Minor bugfixes in Bootstrap and layout files
0.5.0 Initial shared version (February 11, 2012)
0.1.0 Initial version (September 21, 2011)

kickstartwithbootstrap's People

Contributors

burtbeckwith avatar duergner avatar joergrech avatar mukhanov avatar stlhrt avatar thomasbittermann avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kickstartwithbootstrap's Issues

jQuery conflict

I see you have updated the plugin to use Bootstrap 3.0.2. This requires jQuery 1.9 or greater as seen here:

https://github.com/twbs/bootstrap/blob/v3.0.2/bower.json

which was referenced here:

http://getbootstrap.com/getting-started/#whats-included

I added to BuildConfig:

runtime ":jquery:1.10.2"

to take care of this. However, when combined with Kickstart:

compile ":kickstart-with-bootstrap:0.9.9"

I get an error during compilation:

| Installing zip jquery-1.8.3.zip.....
| Installed plugin jquery-1.8.3.....
| Error Fatal error during compilation org.apache.tools.ant.BuildException: srcdir "C:\Users\phil.grails\2.2.4\projects\test-grails-224\plugins\jquery-1.10.2\grails-app\taglib" does not exist! (Use --stacktrace to see the full trace)

It appears there's a hard dependency on jQuery 1.8.3, which according to the Bootstrap authors is incompatible. I'm not sure if there's a way to specify a dependency in Grails in terms of a minimum level (in this case 1.9), but that would be best. Otherwise, maybe leave out the dependency and instruct users to add it themselves like Spring Security UI does.

For reference, I'm using Grails 2.2.4 and testing with a brand new project generated by GGTS 3.4.

Grails 2.0.0-console errors

Environment

Win7 Home Premium
jdk1.7.0_01
Grails 2.0.0

Symptoms

When starting a new application (here called: bootstripper) and installing the KickstartWithBootstrap Plugin, the following errors are shown when pulling up the homepage of the application:

Console Output

'''
E:\Grails\workspace\bootstripper>grails run-app
| Server running. Browse to http://localhost:8080/bootstripper
home.index: [controller:home, action:index]
| Error 2012-02-09 22:37:48,490 ["http-bio-8080"-exec-1] ERROR resource.ResourceMeta - Resource not found: /bootstrap/js/bootstrap-transition.js
| Error 2012-02-09 22:37:49,702 ["http-bio-8080"-exec-1] ERROR [/bootstripper].[gsp] - Servlet.service() for servlet [gsp] in context with path [/boo
tstripper] threw exception
Message: It looks like you are missing some calls to the r:layoutResources tag. After rendering your page the following have not been rendered: [defer
]
Line | Method
->> 1110 | runWorker in java.util.concurrent.ThreadPoolExecutor


| 603 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 722 | run . . . in java.lang.Thread
'''

Stacktrace:

'''
2012-02-09 22:37:49,709 ["http-bio-8080"-exec-1] ERROR StackTrace - Full Stack Trace:
java.lang.RuntimeException: It looks like you are missing some calls to the r:layoutResources tag. After rendering your page the following have not been rendered: [defer]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
at com.springsource.loaded.ri.ReflectiveInterceptor.jlrConstructorNewInstance(ReflectiveInterceptor.java:963)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:102)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:54)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:182)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:190)
at org.grails.plugin.resource.DevModeSanityFilter.doFilter(DevModeSanityFilter.groovy:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.codehaus.groovy.grails.web.servlet.mvc.GrailsWebRequestFilter.doFilterInternal(GrailsWebRequestFilter.java:69)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.codehaus.groovy.grails.web.filters.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:69)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)
at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:259)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:240)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:164)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:462)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:403)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:301)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:162)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:140)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:309)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
2012-02-09 22:37:49,713 ["http-bio-8080"-exec-1] ERROR StackTrace - Full Stack Trace:
java.lang.RuntimeException: It looks like you are missing some calls to the r:layoutResources tag. After rendering your page the following have not been rendered: [defer]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
'''

Fixes / Workarounds found

The first error can be fixed by copying bootstrap-transition.js found at
https://github.com/twitter/bootstrap/blob/master/js/bootstrap-transition.js

Weblogic Deploy error

Fresh projects fail to deploy on Weblogic container.

java.io.FileNotFoundException: C:\bwl\user_projects\domains\WLSDomain.\grails-a
pp\i18n

plugins/resources-1.2/src/java" does not exist!

Hi,

I just tried to install ":kickstart-with-bootstrap:0.9.6" on grails 2.2.4 but I get this exception:

| Error Fatal error during compilation org.apache.tools.ant.BuildException: srcdir "/Volumes/hdd2/Users/devusr/.grails/2.2.4/projects/Kickstart1/plugins/resources-1.2/src/java" does not exist! (Use --stacktrace to see the full trace)
| Error org.codehaus.groovy.grails.cli.ScriptExitException
| Error at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
| Error at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
| Error at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
| Error at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
| Error at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:77)
| Error at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:102)
| Error at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:57)

Is this plugin compatible with 2.2.4?

Regards
Serano

How to add additional params in the pagination tag?

Hi joergrech,

I have a search page for some domain. I hope the pagination can embed additional params, say keyword for query, in the pagination url.

For example, the key is "test", I hope the url be something like http://XXX/domain/search?q=test&max=10&offset=20 for page 3.

I tried <bs:paginate q="test" total="${domainInstanceTotal}" />, but it doesn't work, only generates url like http://XXX/domain/search?max=10&offset=20, missing the additional param.

Versions 0.9.0 and 0.9.2 incompatible with grails 2.1.3

when I try to install the plugin I get the following error:

Error Plugin hibernate-2.2.0 requires version [2.2 > *] of Grails which your current Grails installation does not meet. Please try install a different version of the plugin or Grails.

Datepicker broken on grails 2.3.0

I'm using 0.9.6 and upgraded an app to grails 2.3.0, I managed to use jquery 1.8.3 as 1.10 is not working.

Datepicker is broken and dates are not parsed. Maybe new data binding in grails 2.3.0 ?

Kickstart hardcoded in _navbar

${meta(name:'app.name')}

Kickstart v${meta(name:'app.version')}

In grails-app/views/_menu/_navbar.gsp Should be

${meta(name:'app.name')}

${meta(name:'app.name')} v${meta(name:'app.version')}

Stuck at "Retrieving stats about the application"

When I run my GRAILS application for the first time with Kickstart, it runs fine. The WAR gets loaded, the web site pops up, everything's great.
If I shut it down and try to run it again, it gets stuck at "Retrieving stats about the application"

i.e.
Listening for transport dt_socket at address: 5005
| Loading Grails 2.2.0
| Configuring classpath
| Configuring classpath.
| Environment set to development
| Environment set to development.
| Environment set to development..
| Environment set to development...
| Environment set to development....
| Environment set to development.....
| Packaging Grails application
| Retrieving stats about the application

Unable to load beans from resources

Hi. I have next issue with 0.9.8 version and grails 2.2.4

| Error 2013-10-03 15:38:17,465 [localhost-startStop-1] ERROR spring.GrailsRuntimeConfigurator  - [RuntimeConfiguration] Unable to load beans from resources.groovy
Message: No such property: CustomDateEditorRegistrar for class: resources
    Line | Method
->>    3 | doCall                    in resources$_run_closure1
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|    757 | invokeBeanDefiningClosure in grails.spring.BeanBuilder
|    584 | beans . . . . . . . . . . in     ''
|    757 | invokeBeanDefiningClosure in     ''
|    584 | beans . . . . . . . . . . in     ''
|    527 | invokeMethod              in     ''
|    334 | innerRun . . . . . . . .  in java.util.concurrent.FutureTask$Sync
|    166 | run                       in java.util.concurrent.FutureTask
|   1145 | runWorker . . . . . . . . in java.util.concurrent.ThreadPoolExecutor
|    615 | run                       in java.util.concurrent.ThreadPoolExecutor$Worker
^    722 | run . . . . . . . . . . . in java.lang.Thread

Any ideas, how can I fix it?

Bootstrap CSS not applied when i deploy to Tomcat 6 and 7 on Openshift PaaS

Hi,

i am deploying my Grails application on openshift cloud which provides Tomcat 6 and 7.
The application deploys and starts fine but when i display the page , the page doesn't look like it's expected ( Boostrap style and classes are not applied ).
I checked the head to verify if all css are there and it seems that's OK.
I am not sure, but i suspect the Less process.

Trailing space in CustomDateEditorRegistrar

There is a blank space after the filename, just before the extension in CustomDateEditorRegistrar .groovy. I've checked the repository and it seems to have been there forever but my application won't run complaining that it cannot find the class. If I rename the file (wipe the blank space) it works perfectly. Is there a reason for the space being there?

Suggestion - Rather than an issue

I think excellent work has gone into this plugin but just extending the though, how good it will be to provide an option for the logged in user to change the theme to suit their preferences and color tone?

Looking forward to this, whenever it is incorporated.

Caused by IllegalArgumentException: No module found with name [bootstrap]

Con la nueva versión del plugin, hay que mantenerlo instalado. Como hago para no depender del plugin y que la aplicación funcione? Gracias.

| Running Grails application
| Error 2012-10-23 10:26:43,604 [localhost-startStop-1] ERROR resource.ResourceProcessor - Unable to load resources
Message: Cannot create resource /less/bootstrap/bootstrap.less, is not a supported type
Line | Method
->> 107 | newResourceFromArgs in org.grails.plugin.resource.ResourceModule


| 64 | doCall in org.grails.plugin.resource.ResourceModule$_closure1
| 58 | . . . . . . . . in org.grails.plugin.resource.ResourceModule
| 681 | defineModuleFromBuilder in org.grails.plugin.resource.ResourceProcessor
| 802 | doCall . . . . . . . . in org.grails.plugin.resource.ResourceProcessor$_loadModules_closure19
| 1075 | reloadAll in org.grails.plugin.resource.ResourceProcessor
| 172 | doCall . . . . . . . . in ResourcesGrailsPlugin$_closure3
| 303 | innerRun in java.util.concurrent.FutureTask$Sync
| 138 | run . . . . . . . . . . in java.util.concurrent.FutureTask
| 886 | runTask in java.util.concurrent.ThreadPoolExecutor$Worker
| 908 | run . . . . . . . . . . in ''
^ 662 | run in java.lang.Thread
| Server running. Browse to http://localhost:8080/GrailsApplication6
| Error 2012-10-23 10:26:46,688 [http-bio-8080-exec-2] ERROR [/GrailsApplication6].[grails-errorhandler] - Servlet.service() for servlet grails-errorhandler threw exception
Message: Error applying layout : kickstart
Line | Method
->> 886 | runTask in \grails-app\views\layouts\kickstart.gsp


| 908 | run in ''
^ 662 | run . . in ''

Caused by GroovyPagesException: Error processing GroovyPageView: Error executing tag <r:layoutResources>: No module found with name [bootstrap]
->> 464 | runTask in \grails-app\views\layouts\kickstart.gsp


Caused by GrailsTagException: Error executing tag <r:layoutResources>: No module found with name [bootstrap]
->> 17 | doCall in C:/Users/globalr/Documents/NetBeansProjects/GrailsApplication6/grails-app/views/layouts/kickstart.gsp


Caused by IllegalArgumentException: No module found with name [bootstrap]
->> 1132 | getAllModuleNamesRequired in org.grails.plugin.resource.ResourceProcessor


| 398 | doCall in org.grails.plugin.resource.ResourceTagLib$_closure6
| 39 | doCall in C__Users_globalr_Documents_NetBeansProjects_GrailsApplication6_grails_app_views_layouts_kickstart_gsp$_run_closure2
| 44 | run in C__Users_globalr_Documents_NetBeansProjects_GrailsApplication6_grails_app_views_layouts_kickstart_gsp
| 886 | runTask in java.util.concurrent.ThreadPoolExecutor$Worker
| 908 | run in ''
^ 662 | run . . in java.lang.Thread
| Error 2012-10-23 10:26:46,826 [http-bio-8080-exec-2] ERROR [Tomcat].[localhost] - Exception Processing ErrorPage[errorCode=404, location=/grails-errorhandler]
Message: Error applying layout : kickstart
Line | Method
->> 886 | runTask in \grails-app\views\layouts\kickstart.gsp


| 908 | run in ''
^ 662 | run . . in ''

Caused by GroovyPagesException: Error processing GroovyPageView: Error executing tag <r:layoutResources>: No module found with name [bootstrap]
->> 464 | runTask in \grails-app\views\layouts\kickstart.gsp


Caused by GrailsTagException: Error executing tag <r:layoutResources>: No module found with name [bootstrap]
->> 17 | doCall in C:/Users/globalr/Documents/NetBeansProjects/GrailsApplication6/grails-app/views/layouts/kickstart.gsp


Caused by IllegalArgumentException: No module found with name [bootstrap]
->> 1132 | getAllModuleNamesRequired in org.grails.plugin.resource.ResourceProcessor


| 398 | doCall in org.grails.plugin.resource.ResourceTagLib$_closure6
| 39 | doCall in C__Users_globalr_Documents_NetBeansProjects_GrailsApplication6_grails_app_views_layouts_kickstart_gsp$_run_closure2
| 44 | run in C__Users_globalr_Documents_NetBeansProjects_GrailsApplication6_grails_app_views_layouts_kickstart_gsp
| 886 | runTask in java.util.concurrent.ThreadPoolExecutor$Worker
| 908 | run in ''
^ 662 | run . . in java.lang.Thread

java.io.IOException

On running the generate-all for a domain class, we get this exception in the console.

"java.io.IOException: Cannot run program "git": CreateProcess error=2, The system cannot find the file specified"

Let me know, if you need any more details.

On a side note, great plugin! i was just looking for something to kickstart

problems with grails-2.3.RC1.

I create a new app with grails-2.3.RC1 then install kickstartWithBootstrap.
Create a new domain class, a new controller and then run generate-views mypackage.Mydomain.
The error:

Error Error running script generate-views supplierregister.Sector : groovy.lang.MissingMethodException: No signature of method: static org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.getMapping() is applicable for argument types: (org.codehaus.groovy.grails.commons.DefaultGrailsDomainClass) values: [Artefact > Sector]
Possible solutions: getMapping(java.lang.Class), getMapping(org.codehaus.groovy.grails.commons.GrailsDomainClass) (Use --stacktrace to see the full trace)

I have no problems without kickstartWithBootstrap.

No templates ?

Hello

I have created a new Grails 2.3.4 project.

I have used the version 1.0.0 of kickstart, refreshed the dependencies and ran "kickstart".

I was surprised to see that no templates have been installed in my project.

In addition, the views added with Spring Security Core (1.2.7.3) have not been replaced by kickstart.

Is it a known issues or did I missed something ?

Thanks

Said

Unable to get the right national flag for zh_CN

I'm a Chinese and my locale is zh_CN. When the application starts, I get an error message in console.
| Error 2013-08-15 10:24:13,945 [http-bio-8080-exec-4] ERROR resource.ResourceMeta - Resource not found: /plugins/kickstart-with-bootstrap-0.9.6/images/flags/zh.png

I find that there's only cn.png under /plugins/kickstart-with-bootstrap-0.9.6/images/flags.

kickstart.js does not work with jQuery.noConflict()

Hi
In my project I am using a Prototype.js based modal dialog plugin. In order to get this to work jQuery has to be in no conflict mode which means it won't be accessible via '$' but will only be available as 'jQuery'.
To enable the kickstart.js to work in this case you need to wrap your call to $(document.ready) in a function call that has $ as parameter and immediately call the function, passing it jQuery:
(function($) {
$(document.ready(function(){
//code here
}));
}(jQuery);

The code inside function($) can then use $ to refer to jQuery.
You can see examples of this pattern in the Bootstap javascript.

use of less

it would be good if this used the less versions of the stylesheets

Resources not working in PROD mode

image resources are not working with PROD mode or PAAS deployment (clound foundry). If I comment out KickstartResources.groovy skin definitions without less, then it works in PROD with run-war, but not in PAAS. Prod tries to load images from /APP/images/frontpage/bs-docs-twitter-github.png and PAAS /images/frontpage/bs-docs-twitter-github.png (cloud foundry install apps in ROOT context, so it works right).
If you can point out problem, I can make the fix.

grails.resources.processing.enabled=false in development

When I deactivate the resources processing (grails.resources.processing.enabled=false) in order to be able to test my css changes without having to restart the app, the kickstart css resources are not loaded at all. The ones I have defined in my app are OK.

This seems to be linked to the use of less skins definitions: When I force the use of those resources:

'bootstrap' {
dependsOn 'jquery'
resource url: [dir: 'bootstrap/js', file: 'bootstrap.min.js']
resource url: [dir: 'bootstrap/css', file: 'bootstrap.css']
resource url: [dir: 'bootstrap/css', file: 'bootstrap-responsive.css']
}
// TODO: link a second static/compiled skin or remove the switch entries in layouts/Kickstart.gsp and /_menu/_config.gsp
'bootstrap_skinA' {
dependsOn 'jquery'
resource url: [dir: 'bootstrap/js', file: 'bootstrap.min.js']
resource url: [dir: 'bootstrap/css', file: 'bootstrap.css']
resource url: [dir: 'bootstrap/css', file: 'bootstrap-responsive.css']
}

Everything works fine.

Not sure why the less css is used in development and not in production.

HTTPS Mixed Content Warnings IE

If plugin's host application uses SSL, IE will warn of mixed content on each page load.

This is caused by the following unsecure resource in kickstart.gsp:

<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
    <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->

<%-- For Javascript see end of body --%>

My proposed solution is to use the https version of the js by default(there should be no adversie side-effects to non-ssl pages.

<!--[if lt IE 9]>
    <script src="https://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->

<%-- For Javascript see end of body --%>

Error: Script 'Kickstart' not found, did you mean:

Hi,

I am a beginner of programmin and also Groovy/Grails. Now I have installed a Grails 2.3.4 version and Groovy/Grails Tool Suite Version: 3.4.0 .

Now I am trying to install a Kickstart plug-in and I did set a dependency in BuildConfig.groovy like this: compile ": kickstart-with-bootstrap: 1.0.0"

However when I trying to call the script "kickstart" I get an error message:

Loading Grails 2.3.4
|Configuring classpath
|Running pre-compiled script

|Script 'Kickstart' not found, did you mean:

  1. Stats
  2. DbmListLocks
  3. TestApp
  4. DbmClearChecksums
  5. War
    Please make a selection or enter Q to quit:

Am I calling the script correctly or what might be the error reason?

Kind regards,

Sophie

Pure grails 2.0 support

I would love to see a version based on pure grails 2.0 scaffolding templates and support for the resource framework.
And I think the plugin would benefit a lot if it is kept simpler. Adding filters, changing UrlMappings, changing the way _form.gsp works etc. should be adressed elsewhere, I think.

StructuredDateEditor accepts 5-digit years

Hi Joerg,

This is more a request than a bug.
The registered StructuredDateEditor accepts this date 01/02/20135
even if the specified default.date.format is dd/MM/yyyy.
Validation goes well but when I save the instance holding this date I get the following exception:

MysqlDataTruncation: Data truncation: Incorrect datetime value: '20135-02-01 00:00:00'

I would either add this to the documentation so developers can decide how to handle it and avoid surprises or change the code to use StructuredDateEditor(DateFormat dateFormat, boolean allowEmpty, int exactDateLength) instead of StructuredDateEditor(DateFormat dateFormat, boolean allowEmpty) :

String dateFormat = messageSource.getMessage("default.date.format",null, 'dd/MM/yyyy', LocaleContextHolder.locale)
// do more logic here
SimpleDateFormat simpleDateFormat = new SimpleDateFormat(dateFormat)
simpleDateFormat.setLenient(false);
// Use StructuredDateEditor(DateFormat dateFormat, boolean allowEmpty, int exactDateLength)
// to give the exact date format length 
registry.registerCustomEditor(Date, new StructuredDateEditor(simpleDateFormat, true, dateFormat.length()))

For more on this issue check:
https://jira.springsource.org/browse/SPR-1049

Note that I am using version 0.6.1b (though i don't think is makes a difference if I update to the latest version)

Thank you.

0.8.6 i18n not found

When deploy it in tomcat 6 and 7, the next error arise:

caused by: java.io.FileNotFoundException: /Users/sfhynx/Desarrollo/apache-tomcat-6.0.35/bin/./grails-app/i18n
at org.codehaus.groovy.runtime.DefaultGroovyMethods.checkDir(DefaultGroovyMethods.java:15537)
at org.codehaus.groovy.runtime.DefaultGroovyMethods.eachFileRecurse(DefaultGroovyMethods.java:15616)
at org.codehaus.groovy.runtime.DefaultGroovyMethods.eachFileRecurse(DefaultGroovyMethods.java:15855)
at org.codehaus.groovy.runtime.dgm$179.invoke(Unknown Source)
at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite$PojoMetaMethodSiteNoUnwrapNoCoerce.invoke(PojoMetaMethodSite.java:271)
at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite.call(PojoMetaMethodSite.java:53)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at KickstartWithBootstrapGrailsPlugin$_closure1.doCall(KickstartWithBootstrapGrailsPlugin.groovy:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
... 37 more

I thing the problem is in./KickstartWithBootstrapGrailsPlugin.groovy: new File("./grails-app/i18n").eachFileRecurse

Edit: if you comment the "doWithApplicationContext" it works.

Missing UrlMappings.groovy in the plugin zip file - version 0.8.0

When executing the grails kickstart command, the script try to copy the file UrlMappings.groovy from the plugins source folder but the file is missing.

It's look like when releasing the plugin the file was skipped from the plugin zip file.

It will be very interesing that you put the github link from your grails plugins page, this way it will be more faster to everyone to get the missing file or to be able to look more closely the plugin code.

A big thank you for your work! I like the idea :-)

Register modal form: display issues

Hello

I have set Kickstart on a brand new Grails 2.2.4 projet.
I noticed that when I select "Sign in > Register", the modal form looks weird.
The entry fields and the register button are outside the modal form.

Any idea how to fix that ?

Thanks.

Said

IE Compatability Mode Issues

Using does not seem to work when using kickstart with bootstrap. This is for an intranet site in internet explorer. It seems like for that line to work it needs to be the first line in the head tag, and all the pages rendered through kickstart seem to always put a style tag before it, which causes it to fail. Anyway I can work around this and get the compatibility line first in the head?

Navbar brand alignment

The brand does not align with other items in the navbar due to a bug in the kickstart.css

Current:
.navbar .brand { padding: 2px 20px 10px 20px; }

Should change to:
.navbar .brand { padding: 7px 20px 10px 20px; }

No such property: TimeCategory (minor, suggested fix)

Environment

Win7 Home Premium
JDK 1.7.0_01
Grails 2.0.0
KickstartWithBootstrap Plugin 0.5.4

Symptoms

When starting a new application (here called: boot3) and installing the KickstartWithBootstrap Plugin, the following errors are shown (homepage and console) when calling the homepage of the application:

Console Output

home.index: [controller:home, action:index]
| Error 2012-02-15 00:11:17,720 ["http-bio-8080"-exec-2] ERROR errors.GrailsExceptionResolver - MissingPropertyException occurred when processing req
uest: [GET] /boot3/
No such property: TimeCategory for class: kickstart.KickstartFilters. Stacktrace follows:
Message: No such property: TimeCategory for class: kickstart.KickstartFilters
Line | Method
->> 16 | doCall in kickstart.KickstartFilters$_closure1_closure2_closure4$$ENOv49Kf
| 1110 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 603 | run . . . in java.util.concurrent.ThreadPoolExecutor$Worker
^ 722 | run in java.lang.Thread

Suggested Fix

(already tested, seems to work fine)
in file \grails-app\conf\kickstart.groovy
insert the following after line 1:
import groovy.time.*

Kickstart 0.9.8 availability

Hi

Do you when the version 0.9.8 of Kickstart will be available from the Grails Plugins repository?

Thanks

Said

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.