Skip to content

when adding "orderBy" filter to second collection-no item displayed #18

@shootermv

Description

@shootermv

I want both collections to be sorted by some id:
After i dragged some item to dropabble area - i want the dropped collection to be sorted too.

angular.module('ExampleApp', ['btford.dragon-drop']).
  controller('MainCtrl', function ($scope) {
    $scope.things = [{name:'one',id:3}, {name:'two',id:2}, {name:'three',id:1}];
    $scope.otherThings = [];
  });

When "orderby" filter added to first collection in the demo - its displayed correctly
but nothing displayed after adding "orderby" filter to second droparea
(after you dragged and dropped some items from the first)

< class="row">
  <div class="span6">
    <h3>Things</h3>
    <div btf-dragon="thing in things | orderBy:'id'">{{thing.name}}</div>
  </div>
  <div class="span6">
    <h3>Other Things</h3>
    <div btf-dragon="thing in otherThings  | orderBy:'id'">{{thing.name}}</div>
  </div>
</div>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions