cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Extend Reuse Component in Adaptation Project

riya1
Explorer
0 Kudos
564

Hi All,

I have a requirement to add variant management in reuse component used in adaptation of manage sourcing application

To describe it in detail:

I have created an adaptation project from manage sourcing application which uses reuse component container "sap.cus.sd.lib.item.cndn.forSmartElements::SrcgProjItmCndnAmount::ComponentContainer" to show condition data.

In the smart table used in this container there is not variant management used. However I have requirement to add smartVaraint property of smart table .

I have added below code in object Page Controller extension method attachBatchRequestCompleted

if (!this.oConditionsComponent) {
                            var sComponentId = "s2p.mm.pur.srcgproj.maintains1::sap.suite.ui.generic.template.ObjectPage.view.Details::SourcingProjectItem--sap.cus.sd.lib.item.cndn.forSmartElements::SrcgProjItmCndnAmount::ComponentContainer";
                            this.oConditionsComponent = sap.ui.getCore().byId(sComponentId);
                            this.oConditionTable =  this.oConditionsComponent.getComponentInstance().mAggregations.rootControl.mAggregations.content[0].mAggregations.items[3]
                            this.oConditionTable.setProperty("useVariantManagement",true);
                            this.oConditionTable.setProperty("showVariantManagement",true);
                        this.oConditionsComponent.getComponentInstance().load(true);
                     

Still the default standard variant is not shown in smart table. While checking on console both the properties are set to true. 

So I have a question that can we extend or change any property of reuse Component in Adaptation Project?

Thanks in Advance.

Regards,

Riya 

Accepted Solutions (0)

Answers (0)