Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-1744

NotifyChange should fire on methods called from Base class ViewModel methods

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • None

      I'm trying to push some common functionality for some view models into a Base ViewModel. When the base class method is triggered (@Comamnd) it does its thing and then calls a "postProcess" method that all subclasses must implement so that they can do extra work if need be.

      The problem is ZK requires all "NotifyChange" params to be handled on the very initial Command method. This is problematic since this method is in a base class and it shouldn't have to know about every subclass field that has to be notified. (NOTE: it will also be nice in general I think if any methods that get called with @NotifyChange fire off the changes and not just the initial @Command or @GlobalCommand method's NotifyChange. It's especially problematic in the case I'm describing since it makes inheritance much more difficult.)

      I posted the question to the forums in case there is a work around and have source code there as well:
      http://forum.zkoss.org/question/86637/notifychange-in-subclass-methods-called-from-parent-will-not-fire/

            Unassigned Unassigned
            rickcr rickcr
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated: