14.01.2020 Views

ABAP_to_the_Future

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Frontend Tasks: Creating the View and Controller Using SAPUI5 13.4

<Text text="{Age}" />

<Label text="Number of Heads" />

<Text text="{NoOfHeads}" />

</f:content>

</f:SimpleForm>

Listing 13.14 Defining Layout and Field Texts for the Pop-Up Box

Figure 13.34 Dialog Box Header Details

Next, in Listing 13.15 you’ll define a table that shows all the items for the monster

you’re drilling into: how many ar ms, heads, tails, and so on. The way to

define such a table is exactly the same as the way you did this for the table of

header details in Listing 13.10 and Listing 13.11. First, declare a path so that the

controller can ask the model to get some monster item data. Then, there’s a title

at the top. Finally, define the column names and their widths, and say what values

need to go in the columns at runtime. The result is shown in Figure 13.35.

<Table inset="false" items="{path: 'Monster_ItemSet'}">

<headerToolbar>

<Toolbar>

<Label text="Monster Items" />

</Toolbar>

</headerToolbar>

<columns>

<Column width="100px">

<Text text="Item" />

</Column>

<Column width="100px">

<Text text="Part Category" />

</Column>

<Column width="100px">

<Text text="Part Category Description" />

</Column>

<Column width="100px">

<Text text="Part Qty" />

</Column>

</columns>

605

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!