Checkbox ng-model value doesn't check the box


#1

I’m trying to use ng-model to check a list of checkboxes. The values are true, false, and null. But the boxes never get checked. I’ve printed out the values of activeTasks[key].finished near the list item.

plnkr http://plnkr.co/edit/3WRDCv?p=preview

<ion-view title="{{ activeProject.title }}">
  <ion-nav-buttons side="left">
    <button menu-toggle="left" class="button button-icon icon ion-navicon"></button>
  </ion-nav-buttons>
  <ion-nav-buttons side="right">
    <button ng-click="newTask()" class="button button-icon icon ion-compose"></button>
  </ion-nav-buttons>
  <ion-content class="has-header">
    <ul class="list">
      <li class="item item-checkbox"
        ng-repeat="key in taskKeys"
        ng-class="{finished: activeTasks[key].finished === true}">
        <label class="checkbox checkbox-assertive">
          <input type="checkbox" ng-model="activeTasks[key].finshed" ng-click="toggleTask(key)">
          {{ activeTasks[key].finished }}
        </label>
        {{ activeTasks[key].title }}
      </li>
    </ul>
  </ion-content>
</ion-view>

#2

typo on line centercontent.html line 21. ‘finshed’ -> ‘finished’