This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Hi guys.... Im at the point in grails that I have the "hello world" application working. But now I'm wondering.... what if I don't want any of the default "CRUD" stuff.... all my CRUD is, of course, specific to my business logic.
Is there a "hello world" application out there for grails that doesnt simply autogenerate a form for every table in my domain ? I need, like most developers, the ability to build custom pages without relying on google searching for templates ! Help !
You don't customize Grails to do more than CRUD.
Grails help you to create CRUD for your domain entities but it isn't Grails only mission.
Grails after all is MVC based framework (like Stripes, Struts2 ..), do what ever you want, your keyboard is only the limit
Joined: Aug 30, 2005
Great thanks I think my weakness is that I don't know Groovy, and thus, I cannot do Grails.
I believe that, at least in my experience, you REALLY need to understand GROOVY before you can do anything regarding grails.
I am with the OP, these products that create your CRUD, while they try to say unobtrusive so you can change it, it really isn't. I have tried a few already, and I always have major customization and I get a few done, but then there is always something that can't be done, or is very tightly coupled, so changing it is a real pain and you always forget something, so it take a real long time.
I am trying Grails right now, I just finished using Spring Roo, which is really cool, but again, when I got to the web layer, I couldn't figure out how to pull it out of the basic CRUD pages, because I needed to make better one to many pages etc. However, I think that problem will be easier with Grails since I have seen some of the one to many stuff and while not perfect for how I want, seems closer.
First thing I do when/if I generate controllers and views is get rid of the pointless show view and remove the ID columns from the list views. Also, if you come up with something you like dealing with one-to-many crud screens, you can always create your own templates that Grails will use to generate your views, that way you don't have to customize them for every project.
BTW Mark, when you get to the point where you are trying to save the many side via indexed properties in your forms, ping me. I just went through a bunch of that today and got it all worked out. Planning a dzone article on the subject. The premise is I'm creating an Event and I want to add a bunch of Reminders to the event but I don't want to save them one at a time and I don't want to have to save the Event then go back and fill out Agenda forms. There's just a few gotches that I am going to write up.