cancel
Showing results for 
Search instead for 
Did you mean: 

Select options for Sapui5 with the value help inside dialog

0 Kudos

I am trying to implement the select options in sapui5 as similar to the web dynpro but unable to give value help inside the dialog.

Here is my sample code as same as demo kit code (link https://sapui5.hana.ondemand.com/explored.html#/sample/sap.ui.comp.sample.valuehelpdialog.example3/c...

My code:-

var that = this; var oValueHelpDialog = new sap.ui.comp.valuehelpdialog.ValueHelpDialog( {

basicSearchText : this.theTokenInput.getValue(),

title : "Material",

supportRanges : true,

supportRangesOnly : true,

key : this.aKeys[0],

descriptionKey : this.aKeys[1],

stretch : sap.ui.Device.system.phone,

ok : function(oControlEvent) { that.aTokens = oControlEvent.getParameter("tokens"); that.theTokenInput.setTokens(that.aTokens); oValueHelpDialog.close(); },

cancel : function(oControlEvent) { sap.m.MessageToast.show("Cancel pressed!"); oValueHelpDialog.close(); },

afterClose : function() { oValueHelpDialog.destroy(); } }); oValueHelpDialog.setRangeKeyFields([ { label : "Material", key : "Material" }, ]); oValueHelpDialog.setTokens(this.theTokenInput.getTokens()); if (this.theTokenInput.$().closest(".sapUiSizeCompact").length > 0) { // check // if // the // Token // field // runs // in // Compact // mode oValueHelpDialog.addStyleClass("sapUiSizeCompact"); } else { oValueHelpDialog.addStyleClass("sapUiSizeCozy"); } oValueHelpDialog.open();

After clicking on value help the dialog opens where i can give ranges but in the value input of the dialog i need to open another popup to show available materials so that user can first search materials and then choose a range.

Is there any way to achieve exact select option implementation in ui5 like it is in web dynpro or else i need to start from scratch creating new custom dialog?

Accepted Solutions (0)

Answers (1)

Answers (1)

iftah_peretz
Active Contributor
0 Kudos

Hi,

First of all, the link you provided is broken. Second, take a look here.