grails

Grails Weceem CMS Plugin

Hi , My Problem is that I am using grails Weceem CMS Plugin . I want to combine Jsecurity plugin with this weceem cms plugin. how to do it ? Please help me to find the solution. Regards DINESH T ...

Grails many-to-many relationship

Hi, I'm trying to do a many-to-many relationship on Grails 1.3.4 and I'm getting this exception: Caused by: org.codehaus.groovy.grails.exceptions.GrailsDomainException: No owner defined between domain classes [class gblog.Post] and [class gblog.Comentario] in a many-to-many relationship. Example: static belongsTo = gblog.Comentario ...

Handling parameters from dynamic form for one-to-many relationships in grails

My main question here is dealing with the pramas map when having a one-to-many relationship managed within one dynamic form, as well as best practices for dealing with one-to-many when editing/updating a domain object through the dynamic form. The inputs for my questions are as follows. I have managed to hack away a form that allows me ...

Why is Grails not returning what I'm looking for?

Here's the domain classes I'm working with: class Foo { String name, type static hasMany = [ bars: Bar ] List bars static mapping = { bars lazy:false } } class Bar { String value static belongsTo = Foo } I've written some Criteria queries in order to give the users an interface to que...

GrailsUI Datatable .. Criteria Plugin ... Groovy ...

I'm converting a table with the Criteria plugin to filter it to a GrailsUI datatable .. My plan was to try and utilize the Criteria builder as a kind of engine and supply the HQL it generates as a filter to my datatable .. It's going okay BUT i'm now left with a string which looks like .. filterOn={member.list={members={criteria={pro...

Using Pre/Post Spring-Security Annotations with Grails

I'm developing a Grails (Version 1.3.3) Web-Application using the Grails Spring-Security Plugin, Spring-Security-Core-1.0.1 (which, in turn, uses spring-security-3.0.2.RELEASE). I would like to provide Spring-Security annotation-based access control on actions within a controller. I have been able to successfully do basic authenticatio...

Grails IncompatibleClassChangeError

I deploy a war made with "grails war" to a jetty server. As far as I can determine, Grails builds with Sun JDK 1.6.0_17-b04 and jetty runs on Sun JDK 1.6.0.16 (both on linux). 2010-08-18 07:33:47.018:WARN::Nested in org.springframework.beans.factory.access.BootstrapException: Error executing bootstraps; nested exception is org.codehaus...

Reinstall grails plugin from a simple HTTP location

I installed a plugin using 'grails install-plugin http://blahblah/blah.zip'. The location does not follow the grailsRepo standard or maven standard. It's a simple zip file on a remote server. How do I configure grails so that it finds the plugin? ...

are polymorphic join tables possible in Grails

Does anybody know if it is possible create and write to polymorphic join tables using grails. Are there any drawbacks from doing this ...

How can I clear the database (domains) between easyb scenarios in Grails Integration Testing?

I am running an Integration Test for a Grails application. I am using the easyb plugin. The problem is that the database doesn't seem to get cleared out between Scenarios. My When I run standard Grails Integration Tests, the persistence context is cleared between each test. The easyb Stories are in the Integration folder, but the Gr...

jquery and jquery-ui not working in Springsource Tool Suite 2.3.3.M1

Hi, I installed the jquery and jquery-ui plugins for grails into SpringSource Tool Suite (STS-Eclipse) following the documentation located at http://www.grails.org/plugin/jquery and using the grails command-line tool included with STS-Eclipse as follows: grails> install-plugin jquery grails> install-plugin jquery-ui According to the d...

Grails - testing custom validator on domain class issue

I'm learning grails from Grails - getting started by Jason Rudolph book. My domain class looks like that: class Race { String name; Date startDateTime String city String state Float distance Float cost Integer maxRunners = 10000 static hasMany = [registrations: Registration] static constraints = { name(maxSize: ...

In Grails, how can I get a ConfigObject of messages.properties for locale?

In Grails, I would like to get a ConfigObject reference to the loaded messages properties file for the current locale. Or some way to easily read in the messages properties (for the current locale) in it's entirety. I want to convert it to JSON and send it back to the client to be used to lookup strings via javascript. In essence I want...

Need help resolving a java.net.ConnectException using webtest-plugin for grails

I'm trying to setup a webtest plugin with an existing grails app that's already pretty far along... I'm using grails 1.2.2, groovy version 1.6.4, webtest-plugin 2.0.4 I have one functional web test, which has a single call to invoke("http://localhost:8080/myApp/") I've overridden the existing URLMappings.groovy file so that "/" map...

Grails 'scale' dropping decimal digits

Question using Grails 1.3.4 - the 'scale' constraint does not seem to keep my decimals. I have a field defined as: Float latitude I have a constraint: latitude(blank: false, range:-360.0f..360.0f, scale:6) The Oracle 10g field is defined as: NUMBER(10,6) When I enter a value in Create or Edit, the correct value gets to the database. How...

debug grails integration tests in spring STS

Does anybody know if there is a way to debug integration tets using the built in functionality of Spring STS ? ...

(Groovy/Grails) What to do about URLs in JavaScript module that need to change per environment (dev/prod/qa/etc)

I’ve punted on this before, and/or hacked around it, but I’d like to solve it properly once and for all. The question is what to do if I need a URL that changes per environment in a JavaScript module that's part of a Groovy/Grails project For example, I have a JavaScript module that contains this function: function init() { dojox....

Using JSP tags in grails

Hi .. I'm still new to grails and i kind of stuck in a problem where i can't use the Jsp tags that i put in the /WEB-INF/tags if i create a tag file called text.tag and put in it the normal HTML input text tag and i go to the GSP and make the taglib < %@ taglib prefix="myTags" tagdir="/WEB-INF/tags"%> then trying to call it by < myT...

grails integration test case preserve data for investigation

We were used to running our grails integration test against in memory HSQLDB database, but at the failure point it was difficult to investigate as the data was lost. We migrated to running the test against the physical database(postgres) and all is well when the tests passes. At any point if the tests fail we want the data to be committe...

Grails: User evaluator for Commentable with Spring Security plugin

I am trying to use the commentable plugin with Spring Security. I can't manage to write the right grails.commentable.poster.evaluator I tried {User.get(springSecurityService.principal.id)}, but from the CommentController, both User and springSecurity seems unaccessible. What should I do? ...