title: How group objects in array from ng-repeat with filter?
body: <p>How group objects in array from ng-repeat with filter ?</p>
  
  <p>I have an array with objects, and I would like group by this objects by their countries.</p>
  
  <p>Sample : I would like to have this result :</p>
  
  <pre><code>Free : Australia, India, United States  
  Pay : Australia
  Not Pay : Australia, India
  </code></pre>
  
  <p>from :</p>
  
  <pre><code>$scope.lists = [{
      "id": 1
      "field": [
          {
              country: "Australia",
              type: "Free"
          },
          {
              country: "Australia",
              type: "Pay"
          },
          {
              country: "Australia",
              type: "Not Pay"
          },
          {
              country: "India",
              type: "Free"
          },
          {
              country: "India",
              type: "Not Pay"
          },
          {
              country: "United States",
              type: "free"
          },
      },
      {
      "id": 2
      "field": [
          {
              country: "Australia",
              type: "Pay"
          },
          {
              country: "India",
              type: "Free"
          },
          {
              country: "India",
              type: "Not Pay"
          }
      }
  ]
  </code></pre>
  
  <p>I tried this with the code :</p>
  
  <pre><code>&lt;div ng-repeat="list in lists"&gt;
  
      &lt;ul ng-repeat="(key, value) in list.field | groupBy: 'type'"&gt;
        {{ key }}
        &lt;li ng-repeat="country in value"&gt;
          : {{ country }} 
        &lt;/li&gt;
      &lt;/ul&gt;
  
  &lt;/div&gt;
  </code></pre>
  
  <blockquote>
    <p>Solved :</p>
  </blockquote>
  
  <p>I use angular 1.4.9 and angular-filter 0.5.7</p>
  
  <pre><code>&lt;div ng-repeat="list in lists"&gt;
  
      &lt;ul ng-repeat="(key, value) in list.field | groupBy: 'type'"&gt;
        {{ key }}
        &lt;li ng-repeat="item in value"&gt;
          : {{ item.country }} 
        &lt;/li&gt;
      &lt;/ul&gt;
  
  &lt;/div&gt;
  </code></pre>