나는이 같은 서버에서 개체를 들고 배열이 있습니다핸들 찾아 다른 개체를 기반으로 개체를 검색 반복
[Object, Object, Object, Object, Object]
그래서 내가 그 배열에 #each
을하고 있어요, 그리고 내가 표시 할 시작 했어 예를 들어 this
키워드를 사용하여 현재의 오브젝트의 각 값 :
object : { id: "someid" ,
recommendations_received: [
{
recommendation_id: "some_ID",
giver: {
giver_id: "the_giver_id",
name: "the_giver_name"
}
}
]}
,745 :
{{#if this.recommendations_received}}
{{this.recommendations_received.length}} recommendations
{{else}}
No recommendations
{{/if}}
각 오브젝트 ID는 다음처럼 갖는다
{{#each this.recommendations_received}}
{{this.giver.name}}
{{/each}}
을하지만 지금은주는 사람의 범주 배열을 반복하는 것이 필요
는 그래서 난과 같이 각 권장을 보여 또 다른 반복을하고 있어요. 이는 단순히 내가 이름과 제목이 부문에서 각 개체 내부의이
categories : [object, object, object]
처럼 보인다.
나는 고유 한주는 사람의 ID를 기반으로 recommendation_received을 위해 내가했던 #each 도우미 내부 제시하는 권고의 범주를 싶어.