2014-01-19 1 views
1

밑줄 템플릿 사용. 백본 컬렉션을 반복 :밑줄 템플릿이 루프 내에서 정의되지 않았습니다.

<% _.each(venues, function (venue) { %> 
    <tr> 
    <td class="text-muted"><%= venue.get('city') %></td> 
    <td class="text-muted"><%= venue.get('name') %></td> 
    <td class="text-muted"><%= venue.get('live') == true ? "Yes" : "No" %></td> 
    <td class="text-muted">$0.00</td> 
    <td class="blank controls"> 
     <a href="#"><span class="icon icon-edit"></span><span class="text-hide">Edit</span></a> 
    </td> 
    </tr> 
    <% }); %> 

내가 얻을 :. 장소는 Backbone.Collection 인 경우

Uncaught TypeError: Cannot call method 'get' of undefined 
+0

어떻게 이것을 HTML에 포함 시키시겠습니까? '

관련 문제