Validate on all nested Viewmodels

Topics: Questions
Nov 18, 2014 at 6:00 AM
Hello

If I call Validate(true); not all viewmodels in the nested hierarchie are validated.
Are there any reasons why?
Coordinator
Nov 19, 2014 at 9:17 AM
Did you check if the view models are being registered as child view models?
Nov 19, 2014 at 9:33 AM
No sorry. how to check?
Coordinator
Nov 19, 2014 at 9:40 AM
See docs please on how to get child view models.
Nov 19, 2014 at 10:12 AM
Ok.

So my viewmodels are registered as childviewmodel

thats my hierearchie:

PageViewModel
-> StationViewModel
     -> BlockViewModel
          -> PlaceViewModel
I call validate in StationViewModel
  • Thats the debug output:
Validate Station 1
Validate Station 1
Validate Station 1
Validate Station 0
Validate Station 1
Validate Station 2
Validate Station 3
Validate Station 4
Validate Station 5
Validate Station 6
Validate Station 7
Validate Station 8
Validate Station 9
Validate Station 10


The BlockViewModel an PlaceViewModel is not validate!
Coordinator
Nov 19, 2014 at 10:16 AM
Interesting. Please create repro.
Nov 19, 2014 at 12:39 PM