aurelia / validation

A validation plugin for Aurelia.
MIT License
132 stars 128 forks source link

Validation UI does not work when validation is abstracted to a model. #85

Closed singledigit closed 8 years ago

singledigit commented 9 years ago

Hey Jan, Before this became an official part of Aurelia, you and I had a conversation about this and you had a work around. I cannot, for the life of me, find it. Basic issue is, if I create a separate model and store my validation there. Then inject that model into my current viewmodel, tha validation works, but the UI does not. If I copy everything into the current viewmodel then it works fine. I really need the ability to be able to store validation centrally to the model and then be able to use the model anywhere.

bychkov commented 9 years ago

I came across the same issue. I tried to co-locate validation with my model and when I do this, I do not get UI prompts. Could you please post workaround OP talked about?

janvanderhaegen commented 9 years ago

Hey guys, sorry about the late reply, was ill and on holiday, not a fun combination :(

Was this it? https://github.com/aurelia/validation/blob/master/doc/Intro.md#how-are-elements-and-validation-rules-matched

plwalters commented 8 years ago

Thanks for submitting this / commenting on this. At this time we are closing this because we have completely re-written and are deprecating the previous feature set. If you feel this should be re-opened please feel free to review this blog post and submit either again on this repository, or on the new validatejs bridge repository

Thanks again!