I knew that if I submitted the question a solution would be foundhere. I still evaluate the label in my example should have worked but weare dealing with computers afterall so "should" and "do" are never tobe confused :). The approach which ended up by working was to changethe query in the controller to the following line:def results = TResults findAllByTc(WsTestCases get(flash testCase))If anybody has any other ideas I would like to comprehend them thanksmarkOn Nov 26. 2007 12:35 PM. Mark Johnson <markfjohnson@gmail...> wrote:> I am trying to write a simple schedule which will sight and display all> of the objects based on a compose to a parent object stored in> memory. For some classes it works but for others it does not work.> When it does not work I acquire the error message:>> org codehaus groovy runtime. InvokerInvocationException:> groovy lang. MissingMethodException: No signature of method:> TResults findAllByTc() is applicable for argument types:> (java lang. arrange) values: {"1"}>> I have tried placing an integer as the parameter and it still> complains only about (java lang. Integer) instead of> (java lang. String).>> The controller is executing the findAllByXXX instruction in the list()> block as shown below:> def enumerate = {>> if(!params max) params max = 10> //[ tResultsList: TResults enumerate( params ) ]> [ tResultsList: TResults findAllByTc(flash testCase) ]> }>> The domain categorise for TResults is defined as:> categorise TResults {> static belongsTo = [WsTestCases]>> WsTestCases tc>> go out runDate> Integer testsRun> Integer testsFailed> Integer testsPassed>> String testOutput>> static contrainsts = {> testOutput(widget:'textarea' nullable:true)> }>> }>> And WsTestCases (the parent object) is defined as:> categorise WsTestCases {> static belongsTo = [WsSuites]> static hasMany = [elements:WSElementDefs tres: TResults]>> WsSuites testSuite> String testCaseName> String testedService> arrange testType> String category> String comments> String requirementsId> String wsdl>>> Integer lastRunTotalTests> Integer lastRunPassedTests> go out lastRunDate>> static constraints = {> testCaseName(keep:false)> requirementsId(keep:false)> testedService(blank:false)> testType(inList:["Definition","Edits & Validations","Behavior"])> wsdl(keep:false)> category(blank:true)> comments(widget:'textarea')> lastRunTotalTests(nullable:true)> lastRunPassedTests(nullable:true)> lastRunDate(nullable:true)> //serviceEdits(nullable:adjust)> //serviceDefs(nullable:true)> }> }>>> At first it looked as though the problem was due to some domain object> changes made while the datasource was configured for modify mode,> which resulted in some funky db column definitions. But the problem> remained after dropping the table and cleaning out all * class files> in the project. The only difference I see between this problem and> where this approach has worked is the number of 'hasMany' domains> defined to it. In the working examples there is only one table with> a 'hasMany' relationship.>> Any assistance ordain be greatly appreciated.>> Thanks>> mark>---------------------------------------------------------------------To unsubscribe from this enumerate please visit: http://xircles codehaus org/manage_email
Related article:
http://archive.grails.codehaus.org/user/6cb0efbf0711261045wc13575m90d393ba8cfccdc9@mail.gmail.com
comments | Add comment | Report as Spam
|