cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to "consume" metadata extensions in SAPUI5

vulturas
Explorer
387

Hello everyone,

I learn ABAP RAP and have defined a metadata extension in my service.

 

@Metadata.layer: #CORE
@UI.headerInfo: {
  typeName: 'Handling Unit',
  title: { value: 'HandlingUnitNumber', type: #STANDARD },
  description: { value: 'HandlingUnitUsageDescription' }
}
annotate entity /#####/#####
  with 
{
  .facet: [{
    id: 'HeaderFacet',
    purpose: #HEADER,
    type: #FIELDGROUP_REFERENCE,
    targetQualifier: 'HeaderItems'
  }]
  
  .fieldGroup: [{
    qualifier: 'HeaderItems',
    position: 10
  }]
  PackagingMaterialName;
   
}

 

Is it possible to use/call/consume this metadata extension inside a SAPUI5 app as an addition? I read something about extensions points, but they didn't help me much 😕

 

Any approach or hint is appreciated. 

 

Kind regards

Jürgen

Accepted Solutions (1)

Accepted Solutions (1)

DiegoValdivia
Participant

Your can can make use of annotations on CDS views in two ways:

  • If your app is a Fiori Elements App
  • If your app is a Freestyle app and you use Smart controls
vulturas
Explorer
0 Kudos
I guess this is the right way. Do you have a small sample how to achieve this in a freestyle app using Smart Controls?
DiegoValdivia
Participant

Answers (1)

Answers (1)

junwu
Active Contributor
0 Kudos

what you are trying to get?

normally you don't need to do anything.

vulturas
Explorer
0 Kudos
I have an freestyle UI5 app. And I was told that it's possible to show Fiori Elements inside the UI5 app. This could be achieved via MDE.
junwu
Active Contributor
just put the smart control in your app, just like other control, it will consume metadata/annotation automatically if you have it.