Skip to Content

Select options for Sapui5 with the value help inside dialog

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/code/ValueHelpDialog.controller.js)

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?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Mar 03 at 11:14 AM

    Hi,

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

    Add comment
    10|10000 characters needed characters exceeded