on 03-23-2020 7:21 PM
Does anyone know how to dynamically set the @UI.Hidden annotation using CDS Annotations? I can do it with XML Annotations (<Annotation Term="UI.Hidden" Path="anXfeld">) and it works perfectly. Can't figure out how to do it with CDS. Seems @UI.Hidden can't use a path?
<Annotations Target="Metadata.xDSNxC_CM_CONTType">
<Annotation Term="UI.FieldGroup" Qualifier="cont_checkboxes">
<Record Type="UI.FieldGroupType">
<PropertyValue Property="Data">
<Collection>
<Record Type="UI.DataField">
<PropertyValue Property="Value" Path="fundingcontrol"/>
<PropertyValue Property="Label" String="Funding Control"/>
</Record>
<Record Type="UI.DataField">
<PropertyValue Property="Value" Path="extfundingsource"/>
<PropertyValue Property="Label" String="Ext Funding"/>
<Annotation Term="UI.Hidden" Path="fundingcontrol"/>
</Record>
</Collection>
</PropertyValue>
</Record>
</Annotation>
</Annotations>
If you're using the CAP framework, it should look like this:
Note that it will only accept a boolean field.
FieldGroup #General : {Data : [
{
Value : AUART,
Label : '{i18n>AUART}'
},
{
Value : VKORG,
Label : '{i18n>VKORG}',
![@UI.Hidden] : IsActiveEntity
},
{
Value : VTWEG,
Label : '{i18n>VTWEG}'
},
{
Value : SPART,
Label : '{i18n>SPART}'
}
]},
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
77 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.