Skip to content

How to fetch corresponding data from table in grails using dropdown? IMPORTANT #45

@AdithyaPM

Description

@AdithyaPM

I have a table consisting of 2 parameters(name and calendar).I have created the dropdown using <g:select> tag that consists list of names from the table,on selection I want to fetch the corresponding calendar and display it.Any idea how can I fetch the calendar related to name?

this is my gsp code which gives list of names as dropdown

<g:select class="form-control" id="savedCalendar" name="savedCalendar.id" noSelection="['null':'']" from="${globalCalendar?.name}" onchange="return showcal()"/>

what should I do in function so that I can fetch calendar and display it

`
function showcal(){

       ????

}
`
Can anyone please guide me on this?
Thanks in advance

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions