Why does javascript-angular jump to the upper-and lower-level to the upper-level?

Source: Internet
Author: User
1. the col data table contains three fields: name, id, and id. As follows: horizontal bars (s) indicate the subitem of a data item. {Code...} If I retrieve a subitem through the parent id, I do not know how to return the subitem to the parent project. The general idea is that, through the... 1 in a, there is a col data table, which contains three fields: name, id, and id.
As follows: horizontal bars (s) indicate the subitem of a data item.

{'A', '3', '2'} {'a-s', '4', '3'} {'a-s', '5 ', '3'} {'a-s-s', '6', '5'} {'a-s-s', '7 ', '4'} {'B', '8', '2 '}

Now, if I retrieve a subitem using the parent id, I do not know how to return the subitem to the parent project.
The general idea is that I obtained a string of son data (such as 'A-s') through id (3) in ). The parent id (3) is recorded in the data corresponding to son ). I use this parent id (3) to find the pid (2) with id = 3 in the database, and then return son data with parent id 2 (a and B ).
But I don't know how, as if there are too many layers, it will be messy.

Reply content:

1. the col data table contains three fields: name, id, and id.
As follows: horizontal bars (s) indicate the subitem of a data item.

{'A', '3', '2'} {'a-s', '4', '3'} {'a-s', '5 ', '3'} {'a-s-s', '6', '5'} {'a-s-s', '7 ', '4'} {'B', '8', '2 '}

Now, if I retrieve a subitem using the parent id, I do not know how to return the subitem to the parent project.
The general idea is that I obtained a string of son data (such as 'A-s') through id (3) in ). The parent id (3) is recorded in the data corresponding to son ). I use this parent id (3) to find the pid (2) with id = 3 in the database, and then return son data with parent id 2 (a and B ).
But I don't know how, as if there are too many layers, it will be messy.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.