Grails
  1. Grails
  2. GRAILS-9895 Improve Data Binding
  3. GRAILS-9220

Binding JSON request data doesn't work for nested properties

    Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.4
    • Fix Version/s: 2.3-M1
    • Component/s: Data binding
    • Labels:
      None
    • Testcase included:
      yes

      Description

      Binding request.JSON to a domain class does not work beyond the top level properties. I've attached an example where I attempt to bind to an embedded property and a collection relationship, neither of which works.

      The same behaviour is exhibited even if you ensure the embedded property is non-null before binding.

        Issue Links

          Activity

          Hide
          Graeme Rocher added a comment -

          Part of the data binding rework

          Show
          Graeme Rocher added a comment - Part of the data binding rework
          Hide
          Travis Webb added a comment -

          This does not work in 2.3.0.RC1

          Show
          Travis Webb added a comment - This does not work in 2.3.0.RC1
          Hide
          Jeff Scott Brown added a comment -

          Travis,

          I will take a look at this. Thanks for the note.

          Show
          Jeff Scott Brown added a comment - Travis, I will take a look at this. Thanks for the note.
          Hide
          Jeff Scott Brown added a comment -

          Travis,

          I upgraded the attached app to 2.3.0.RC1 and the unit test passes. I have attached that app to this JIRA. Are you seeing something different?

          Show
          Jeff Scott Brown added a comment - Travis, I upgraded the attached app to 2.3.0.RC1 and the unit test passes. I have attached that app to this JIRA. Are you seeing something different?

            People

            • Assignee:
              Jeff Scott Brown
              Reporter:
              Robert Fletcher
            • Votes:
              23 Vote for this issue
              Watchers:
              19 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development