This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <!--[if lt IE 7 ]> <html lang="en" class="no-js ie6"> <![endif]--> | |
| <!--[if IE 7 ]> <html lang="en" class="no-js ie7"> <![endif]--> | |
| <!--[if IE 8 ]> <html lang="en" class="no-js ie8"> <![endif]--> | |
| <!--[if IE 9 ]> <html lang="en" class="no-js ie9"> <![endif]--> | |
| <!--[if (gt IE 9)|!(IE)]><!--> <html lang="en" class="no-js"> <!--<![endif]--> | |
| <head> | |
| <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
| <title>Centered column with fixed footer</title> | |
| <meta name="author" content="Rob Fletcher"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /bin/sh | |
| VERSION=$1 | |
| GRAILS_DIR=/opt/grails-$VERSION | |
| GRAILS_SYMLINK=/opt/grails | |
| if [[ ! -d $GRAILS_DIR ]]; then | |
| echo "Error: $GRAILS_DIR does not exist" | |
| exit 1 | |
| fi | |
| if [[ -e $GRAILS_SYMLINK ]]; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class GreetingController { | |
| def index = { | |
| [message: message(code: "greeting.message", args: [params.name])] | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import groovy.transform.* | |
| import org.junit.* | |
| import org.openqa.selenium.* | |
| import org.openqa.selenium.support.ui.* | |
| import org.openqa.selenium.firefox.* | |
| import static org.junit.Assert.* | |
| import static org.hamcrest.Matchers.* | |
| class AutocompleteTests { | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @artifact.package@import spock.lang.* | |
| import grails.plugin.spock.* | |
| class @artifact.name@ extends @artifact.superclass@ { | |
| def "feature method"() { | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.github.robfletcher.grails.validation | |
| import org.codehaus.groovy.grails.validation.AbstractConstraint | |
| import org.springframework.validation.Errors | |
| class AcyclicConstraint extends AbstractConstraint { | |
| static final String DEFAULT_MESSAGE_CODE = "default.acyclic.violation.message" | |
| static final String NAME = "acyclic" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @artifact.package@import grails.test.* | |
| import org.junit.* | |
| import static org.junit.Assert.* | |
| import static org.hamcrest.CoreMatchers.* | |
| import static org.junit.matchers.JUnitMatchers.* | |
| class @artifact.name@ { | |
| @Before void setUp() { | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class TagListEditor extends PropertyEditorSupport { | |
| void setAsText(String text) { | |
| value = text.split(/,\s*/).collect { | |
| Tag.findByName(it) ?: new Tag(name: it) | |
| } as Set | |
| } | |
| String getAsText() { | |
| value?.name?.join(", ") | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class TagListEditor extends PropertyEditorSupport { | |
| void setAsText(String text) { | |
| value = text.split(/,\s*/) as Set | |
| } | |
| String getAsText() { | |
| value?.join(", ") | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.beans.PropertyEditorSupport | |
| import org.apache.commons.lang.StringUtils | |
| class DomainClassLookupPropertyEditor extends PropertyEditorSupport { | |
| Class domainClass | |
| String property | |
| String getAsText() { | |
| value."$property" |