ICEfaces
  1. ICEfaces
  2. ICE-9995

JavaScript error in notifyAllOnElementUpdateCallbacks function

    Details

    • Assignee Priority:
      P1
    • Support Case References:
    • Workaround Exists:
      Yes
    • Workaround Description:
      Hide
      Setting the following context param helps the issue but at the risk of performance:

      <context-param>
      <param-name>org.icefaces.clientSideElementUpdateDetermination</param-name>
      <param-value>true</param-value>
      </context-param>
      Show
      Setting the following context param helps the issue but at the risk of performance: <context-param> <param-name>org.icefaces.clientSideElementUpdateDetermination</param-name> <param-value>true</param-value> </context-param>

      Description

      The following issue has been seen by one of our customers:

      "one of our pages is getting javascript error Cannot read property 'data-onElementUpdate' on undefined during an ajax request. I have debugged the page and found the problem is in namespace.notifyAllOnElementUpdateCallbacks function. The error is caused in the loop within this function because the ice.onElementUpdate function for the <ace:dateTimeEntry> component which is on this page removes the dateTimeEntry input field and associated calendar image from the DOM which also removes two tags from the elements array within notifyAllOnElementUpdateCallbacks. When the index var i of the for loop gets to the second from last entry, then the var e will be undefined (since max loop index is based on original size of elements array, defined in var l, but size of elements is now reduced by 2)."

        Activity

        Repository Revision Date User Message
        ICEsoft Public SVN Repository #40899 Tue Apr 29 13:06:48 MDT 2014 art.zambrano ICE-9995 added conditionals to ensure that the element being processed still exists in notifyAllOnElementUpdateCallbacks()
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/core/src/main/javascript/element-update.js

          People

          • Assignee:
            Arturo Zambrano
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: