Skip to content

When moving elements on nested listing, the element gets cloned on the list it moved from #29

Description

@celsomtrindade

When moving from one nested listing to another, the element move but creates a clone on the older list.

I've made this plunker to recreate the problem.

If you move, for example, one "Shirt" from the "Shirt list" into a "Shoes list", the shirt will move, but the same shirt will be recreated on the "Shirt list" again, cloning the element.

Activity

  1. samjacobclift commented on Apr 10, 2017

    @samjacobclift
    Contributor

    Is this a sortable bug or an angular sortable specific one?

  2. samjacobclift commented on Apr 10, 2017

    @samjacobclift
    Contributor

    I'm working on a simple e2e test suite so if I can get that done I can use this to write a test case if its a sortable issue

  3. celsomtrindade commented on Apr 10, 2017

    @celsomtrindade
    Author

    @samjacobclift I don't know, but it seems to be sortable issue, since it's happening only in a nested list and only when moving from one to another. If the we move in the same list, just to reorder the list, nothing happens. In the same example, if you drag the whole category list, it will move and doesn't clone. The problem only happen within the products list.

    But like I said, I'm not sure.

  4. samjacobclift commented on Apr 10, 2017

    @samjacobclift
    Contributor

    ah nest isnt officially supported by sortableJS I believe. It maybe worth raising this as an issue in the main repo

  5. celsomtrindade commented on Apr 10, 2017

    @celsomtrindade
    Author

    But did you saw the plunker i did? Because the sorting does happen and work. The problem is when you want to remove an item from one nested listing and add to another nested listing.

    It also does remove and move. But it creates a clone on the list it got removed from, duplicating the element, leaving one on the new nested listing and one in the old nested listing.

  6. ZiQiangWang commented on Apr 28, 2017

    @ZiQiangWang

    I have the same problem, have you figure it out????

  7. beazergood commented on May 8, 2017

    @beazergood

    I too appear to have this same issue. Dragging between lists the dragged item reappears: http://jsbin.com/yuvucim/edit?html,js,output

    Would love to find out why!

  8. added 2 commits that reference this issue on Jul 8, 2017
  9. nguyentrangdong commented on Feb 14, 2019

    @nguyentrangdong

    You are best, beazergood!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions