Updating Django MPTT tree from JSON

I need to update Django MPTT tree from JSON data. I am setting up django-mptt using Nestable ( http://dbushell.github.com/Nestable/ ) jQuery plugin for editing tree in frontend.

jQuery Nestable provides this data after updating the tree:

[{
    "id": 1
}, {
    "id": 2,
    "children": [{
        "id": 3
    }, {
        "id": 4
    }, {
        "id": 5,
        "children": [{
            "id": 6
        }, {
            "id": 7
        }, {
            "id": 8
        }]
    }, {
        "id": 9
    }, {
        "id": 10
    }]
}, {
    "id": 11
}, {
    "id": 12
}]

      

How can I update my mptt tree from this data?

Thank!

+3
jquery django tree mptt


source to share


No one has answered this question yet

Check out similar questions:

1817
How to customize Microsoft JSON date?
1256
What are the options for storing hierarchical data in a relational database?
452
What is the most efficient / elegant way to parse a flat table into wood?
438
Java tree data structure?
389
In Django form, how do I make the readonly field (or disabled) so that it is not editable?
nine
How can I create a json tree from django-mptt?
2
Django model inheritance using mptt
1
build JSON from Django-mptt
1
Parsing Django-mptt JSON
0
Create tree editor for mptt model in django admin



All Articles
Loading...
X
Show
Funny
Dev
Pics