title: Smart Table st-sort Angular JS - Sort Not Working on Object of Objects
body: <p>I am calling a service which returns object of objects something similar to this. userCollections is the variable that is being stored.</p>
  
  <pre><code>{
      1: {
          id: "A1",
          name: "B1"
      },
      2: {
          id: "A1",
          name: "B1"
      },
      3: {
          id: "A1",
          name: "B1"
      },
      4: {
          id: "A1",
          name: "B1"
      },
      5: {
          id: "A1",
          name: "B1"
      },
  }
  </code></pre>
  
  <p>This is how I am displaying the data in the table.</p>
  
  <pre><code>&lt;table class="table table-hover" st-table="DisplayCollection" st-safe-src="userCollections"&gt;
    &lt;thead class="thead-inverse text-uppercase"&gt;
      &lt;tr&gt;
        &lt;th st-sort="id" st-sort-default="true" class="cursor-pointer"&gt;Name&lt;/th&gt;
        &lt;th st-sort="name" class="cursor-pointer"&gt;Email&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/thead&gt;
  
    &lt;tbody ng-repeat="(cname, cdata) in DisplayCollection"&gt;
      &lt;tr class="cursor-pointer" ng-repeat="collection in cdata"&gt;
        &lt;td ng-bind="collection.full_name | ellipsis:25:false"&gt;&lt;/td&gt;
        &lt;td ng-bind="collection.email | ellipsis:25:false"&gt;&lt;/td&gt;
      &lt;/tr&gt;
    &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>st-sort is not working. How do I make it work on object of objects.</p>
  
  <p>I cannot convert the object of objects to array of objects, as I would need the object key for some operation.</p>
  
  <p>Any way to achieve the sort?</p>