2016-09-13 5 views
1

저는 Material Design Lite에서 Aurelia 프레임 워크를 플러그인 "aurelia-mdl-plugin"을 사용하여 사용하고 있습니다. - 그들 각각의 선택 능력을 가진 체크 박스를 가져 + 목록은 체크 상자 "모두 선택"도착이 마크 업이 선택할 수있는 항목의 목록을 나타냅니다Material Design Lite Lists - 선택한 요소에 액세스하는 방법?

<table class="mdl-data-table mdl-js-data-table mdl-data-table--selectable mdl-shadow--2dp"> 
    <thead> 
     <tr> 
      <th class="mdl-data-table__cell--non-numeric">Name</th> 
      <th>Col2</th> 
      <th>Actions</th> 
     </tr> 
    </thead> 
    <tbody> 
     <tr repeat.for="s of items"> 
      <td class="mdl-data-table__cell--non-numeric">${s.name}</td> 
      <td>${s.someothercol}</td> 
      <td><a href="/import/${s._id}">View</a></td> 
     </tr> 

    </tbody> 
</table> 

:

나는 다음과 같은 마크 업을 머리글.

문제는이 추가 마크 업이 MDL에 의해 생성되었으므로 실제로 바인딩 할 수 없다는 것입니다. 이 문제를 해결하기 위해 어떤 방법이 있나요

<input type="checkbox" checked.bind="s.IsChecked" />

:

은 체크 박스는 수동으로 내가 좋아하는 뭔가를 할 것 삽입 내가했다면?

추신 : 나는 그것이 반드시 Aurelia에 고유하다고 생각하지 않습니다. 대부분 Angular 또는 다른 라이브러리에서 같은 문제가 발생합니다.

답변

관련 문제