Api for organizing files similar to tree structure

2

I'm developing a meeting module, which contains schedule management, the schedules are organized as follows:

1. pauta c
    1.1.pauta x
2. pauta v
    2.1. pauta b
      2.1.1. pauta y

Each staff of this is a record in the database. I tried in several ways, with Jquery, Javascript with arrays, Datatables, but I did not succeed. In this module I need to implement the option to change and delete prompts. For example, it must be possible for the user to select (click) a staff and click on another button to make it a subtopic or leave it as a topic. When modeling the system, the Agreedo was used as a model. As far as I understand this structure is tree. But I'm looking for something simpler.

The question is, I wonder if there is an Api .js to help me with this development. Preferably one that abstracts this part of tree. If you do not have it, I'd like an idea with logic.

    
asked by anonymous 06.11.2017 / 00:30

1 answer

1

One time I needed to do something like what you need. In my case I needed to make a tree from a URA to PABX and in each item of the tree I needed to trigger an onClick event. I used JSTree, I found it very basic and easy to manipulate. link

Just remembering, JSTree does not create events, etc (at least I did not create by it), that part I had to do at hand. JSTree will just take the data and display it as a tree format.
Here is an example of how my data tree was:

    
06.11.2017 / 11:35