groovy - Grails: Facing difficulty to create list using Ajax -
I'm new in Grails. The four basic domain classes are A, B, Q, T and second transaction class Tr. The name of a controller named trinkolar is the class and the controller are as follows:
class A {string aName string aID constant constraints = {aName (nullable: false, empty: false)} static belongsTo = [tr] String B) String B (String B) String B (String S & TO = [Q: Q]} Class Q {String Q String Qtype Fixed Constraints = {} Static Attach = 1} Stent getname () {userName} string getname () {UserName} [B: B]} class T {string t static barriers = {} Fixed Hammany = [Q: Q]} class triple A.BB QQ QType TT static barriers = {}} class TrController {DEF index} {} DEP dropdown () {} DEF userlight = user.et (parameters) ID)}
Now I want to create a simple drop down list from class A in a DD GS. The page page code is as follows:
& lt; G: = "$ {userinstance.toString ()}" value = "$ {userinstance.toString ()} select name =" User_name "}" />
The change will be reflected on the drop down value from all the domain classes in the same page.
Try creating a drop-down list (on the page dd.gsp) but it shows an error:
class: groovy.lang.MissingMethodException Message: Method of No signature: practice 00008.TrController.getParams () applies for logic types: () Value: []
Please guide me to solve this problem.
def userlist = user.get (params.id)
in fixed context It is said, when Grails makes this class. Not for a request.
Do you have a dd.gsp
( / dd
what do you think? Or maybe your current dropdown
action? Enter the following code in this action), and load this data from here, like:
def dd () {def userlist = User.get (parameter.id) Render view: 'DD ', Model: [User List: Userlight]}
Or simply:
def dd () {[userlist: User.get (params. Id)]}
Comments
Post a Comment