grails service class not recognized

Hi all,
I have a grails application, everything runs fine.  I just went to create my first service class and Intellij doesn't recognize it when I create an instance of it.  It works, created a test method to do so.  Is there any fix for this to let it recognize service classes?  Thanks.  

7 comments

What do you mean by the word "to recognize"?

0

so I do the code

def test = new MyMethod()
test.testme();

This works however MyMethod gives an intellij error (not a grails error) of "Cannot resolve symbol MyMethod" and similarly for testme  

0

Do you have MyMethod in the imports?
Sorry for the delay.

0

No, but if the import wasn't there shouldn't it error out?  (which it didn't)

0

The service class and test class are in same package?

0

No, the service class is being called from a controller.  

0

Please, attach a small sample project.
I don't understand how you can access to the service from a controller when service and controller are in different packages and service class is not declared in imports.

0

Please sign in to leave a comment.