The last step is to add a content
element to link the new fragment file to the Details Icon Tab Filter. Open Detail.view.xml
, replace the text within the items
element with the text below, Beautify and save your changes.
<IconTabFilter icon="sap-icon://supplier" key="Supplier" text="{i18n>tab_supplier_short_title}">
<content>
<core:Fragment fragmentName="com.test.northwind.view.DetailInfoForm" type="XML"/>
</content>
</IconTabFilter>
<IconTabFilter count="" icon="sap-icon://product" iconColor="Default" id="__filter3" text="{i18n>tab_product_short_title}">
<content>
<core:Fragment fragmentName="com.test.northwind.view.ProductDetailInfoForm" type="XML"/>
</content>
</IconTabFilter>
The XML you pasted in did a few things:
- Changed the label on the Supplier tab to a string in the messageBundle.properties
file (but otherwise that IconTabFilter
tag was unchanged)
- Changed the Product IconTabFilter
from a self-closing element to a multi-line element (this is necessary to add in the content
element) and set the label string
- Added a content
element for the Product tab with a reference to the new fragment you created