title: Ember.js show hasMany data in template with one or more results
body: <p>After endless trying I hope someone find the clue in what I am trying. I know there are many questions about this specific topic on stackoverflow. However I think I do not ask the same question. As I do not find the answer to my specific challenge. </p>
  
  <p>Here is my <strong>Router</strong>:</p>
  
  <pre><code>App.Router.map(function () {
      this.resource('article', {path: '/article/:id'});
      this.resource('article.new', {path: "/article/new"});
  });
  </code></pre>
  
  <p><strong>Routes</strong></p>
  
  <pre><code>App.ArticleRoute = Ember.Route.extend({
      model: function (params) {
          return this.store.find('article', params.id);
      }
  });
  
  App.ArticleNewRoute = Ember.Route.extend({
      renderTemplate: function () {
          this.render('article', {
              controller: 'article.new'
          });
      },
      model: function () {
          return this.store.createRecord('article');
      }
  });
  </code></pre>
  
  <p>The <strong>model</strong></p>
  
  <pre><code>App.Category = DS.Model.extend({
      name: DS.attr('string'),
      image: DS.attr('string'),
      categoryRelation: DS.belongsTo('category')
  });
  
  App.Article = DS.Model.extend({
      name: DS.attr('string'),
      category: DS.hasMany('category')
  )};
  </code></pre>
  
  <p>The returned <strong>JSON</strong> from server:</p>
  
  <pre><code>{
     "articles":[
        {
           "id":1,
           "name":"Car 1",
           "category":[1,2],
        {
           "id":2,
           "name":"Car 2",
           "category":2,
     ],
  
     "categorys":[ // note the added 's' when returning multiple items as per EmberJS convention
        {
           "id":1,
           "name":"Oldtimers"
        },
        {
           "id":2,
           "name":"Classic"
        }
     ],
  }
  </code></pre>
  
  <p>And now the question, because I try in my template the following:</p>
  
  <pre><code>&lt;script type="text/x-handlebars" data-template-name="article"&gt; 
      &lt;div&gt;
          {{#each category in model}}
              {{category.name}}&lt;br&gt;
              {{name}}&lt;br&gt;
          {{/each}}
      &lt;/div&gt;
  &lt;/script&gt;
  </code></pre>
  
  <p>I have tried multiple variations in the template, this is my last code which seems correct. Note: as for article with id 2, the template must also render if there is just one article.</p>
  
  <p>Edit: I translated some code for you guys. If there are misspellings, they are probably not in the original code.</p>