webMethods Business Console Documentation 10.5 | webMethods Business Console Documentation | Developing Gadgets for Business Console | Communicating Between Gadgets | Connecting Multiple Views with Controller | Defining a View with Sub-views in Multiple XHTML Files
 
Defining a View with Sub-views in Multiple XHTML Files
1. Create the <file_name>.xhtml under the views directory.
2. Use data-ng-include attribute to tie up with the parent view.
If you have created view1.xhtml and view2.xhtml, edit view.xhtml as shown below.
<div data-ng-include="/<CONTEXT_ROOT_OF_APPLICATION/<GADGETS_DIRECTORY>
/views/view1.xhtml">
</div>
<div data-ng-include="/<CONTEXT_ROOT_OF_APPLICATION/<GADGETS_DIRECTORY>
/views/view2.xhtml">
</div>
Replace <CONTEXT_ROOT_OF_APPLICATION> and <GADGETS_DIRECTORY> accordingly. All views specified under the view.xhtml are automatically bound to the controller.
Note: You can use the data-ng-model or data-ng-bind attributes to setup two-way binding to the controller scope variables.

Copyright © 2014-2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.