Angular neutron controller to parent controller __angular

Source: Internet
Author: User
Angular neutron controller passing values to parent controller


Child instruction App-sheet, use sheet.html as the template.
In the sheet.html there is a click event, Selecttablist (item), where the item is in the child instruction App-sheet user click Select Item.
In Sheet.js, this method is shared with the parent by Scope:{selecttablist: ' & '}.


In the entire top-level route, search.html and Searchctrl are bound to each other.
In search.html, when using the app-sheet instruction, select-tablist= "Sclick (id,name)" is used to indicate the Selecttablist method of the parent-child sharing. is passed in by the Sclick (Id,name) in the Searchctrl of the parent.



The contents of "C1 Beijing" clicked in the child can be printed through the Sclick method in the parent Searchctrl.
In this way, the Searchctrl of the parent gets the value of the app-sheet instruction.

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.