Skip to main content

This is documentation for Caché & Ensemble.

For information on converting to InterSystems IRIS, see the InterSystems IRIS Adoption Guide and the InterSystems IRIS In-Place Conversion Guide, both available on the WRC Distributions page (login required).

Previous sectionNext section

Exercises

The following exercises guide you through adding functionality to the Zen Contacts application built in Part II and Part III of this tutorial (see the note below for the location of the solution file). The added functionality allows users to view, create, edit, and delete phone number information for the contacts. More specifically, the new functionality includes the following:

  • A table to display the set of phone numbers for a selected contact. When the user clicks the view phones link on the contact table, a table displaying the phone numbers (number and type) for that contact appears on the page.

  • An edit form for the phone numbers. Each row of the phone table contains an edit link. When the user clicks the link, an edit form (analogous to the contact edit form) is displayed. This form allows the user to update the information for the selected phone number.

  • A new phone link. When the user clicks this link the page displays the phone edit form. The user can then use the form to create a new phone number and add it to the set of phone numbers belonging to the contact currently selected on the contact table.

Here is how the application appears in a browser with both the phone table and the phone edit form displayed:

generated description: exercise1 20131

Note:

Contacts.xml, ZenContacts.xml, and CustomComponents.xml contain the complete Zen Contacts application through Part III of the tutorial. The files are in <cachesys>\Dev\tutorial\zen. Contacts.xml contains the data classes. CustomComponents.xml contains the custom composite menu component. ZenContacts.xml contains the remaining Zen classes. Import CustomComponents.xml and compile MenuComposite before importing and compiling the remaining Zen classes. Follow the procedure described in Part II: Getting Started to load the solution classes into Caché. ZenContactsExerciseSolution.xml contains the exercise solutions. Load this instead of ZenContacts.xml to see the completed exercises.

Note:

Click here to begin.

Feedback