Open e-cloud opened 8 years ago
The first argument passed to checklist-before-change
is the scope.
What I can do is to also pass the context as this and also add oldValue and newValue as arguments. What do you think about it.
Actually the scope
is used for the parser to evaluate the expression unexceptionally. That's not the argument passed to the function call binded to the directive.
For the design now, i think it's hard to achieve my goal. Sorry, for now, i can just state the issue but not solve it.
May be some general refactoring needed?
Now,
checklist-before-change
's behavior is evaluate an expression which perform some judge based on data outside the directive scope.But, there is a situation. before changing the model, i need to know what's the change going to be, so that i can compare the future and the current to see if let the future happen.
as the event system, no context is horrible.
Now that feature is unavailable.