I am trying to create a simple page with shows the calender page.
What i have is a html fragment, which iterates over a days array and creates a cell for each day of the month.So i am going to pass the current day, current month,current year and weeks array to this template.
The logic worked fine when it used the global scope,but as one can have multiple calender instances within a page, i created a isolated scope and want to push the values to the fragment when the directive renders.
I am not able to bind the scope values with the html fragment .It keeps throwing me error:
'Error: Non-assignable model expression: undefined (directive: calender)'
.
Need help in understanding what needs to be done inorder to get this thing working with isolated scope.
Thanks
I was getting Error: Non-assignable model expression: undefined error because there were no bindable attributes on my directive by that name,instead those were model values.
I replaced the scope defination to
scope:{ngModel: '='} and the the linker function was then able to update the model values.