Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-3647

Component#getMarkupId() throws exceptions when not added to page yet

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.5-RC3
    • 1.5-RC4
    • wicket
    • None

    Description

      When retrieving the markup ID for a component that has not yet been added to a page, Wicket currently throws an exception telling that the markup could not be found, or that the markup type (in case the component was added to a Panel) could not be determined. In 1.4, Wicket would generate a markup ID in these cases.

      Proposed solution: to first see if a markup ID has been either generated or set (using setOutputMarkupId), and then returning that, or if no ID was yet available and the component has been added to a Page: use the ID from the markup, or if the component has not been added to a Page nor a markup ID: generate the ID.

      Attachments

        Activity

          People

            jdonnerstag Juegen Donnerstag
            dashorst Martijn Dashorst
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: