on 09-10-2015 8:53 AM
Hi All,
I am trying to add some filters and sorting buttons to the sap.m.table,so I landed up using new sap.m.ViewSettingsDialog.
But while in process I came to know my code is not working for Popover. I have even tried the basic Popover as shown below.
none of the elements explained under popup section in below link is getting displayed during compiling.
new sap.m.Button( {
icon: "sap-icon://action-settings",
text:"dialog",
tap: function(){
console.log("BUTTON PRESSED"),
new sap.m.Popover({ title:"sort and filter"})
}
}),
Could you please explain if I am missing some thing.do i need to add any sources in the index file specially for Popup's
Note:In above code while compiling "dialog" Button is getting displayed and "BUTTON PRESSED" is getting displayed in log but not popover and its not showing any error as well.
Hi Abhiram,
Which version of UI5 are you using? Since 1.20.0 version, tap event is deprecated for sap.m.Button.
API - JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.m.Button
Try using press event, instead of tap and check whether that works.
Regards,
Sai Vellanki.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are declared the popover but you are not opened. that's the reson you are not getting popover
var oPopOver = new sap.m.Popover({ title:"sort and filter"})
};
oPopOver.openBy();
JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.m.Popover
example- openui5/src/sap.m/test/sap/m/demokit/sample/Popover at master · SAP/openui5 · GitHub
thank you very much santosh and indrajith,
Now its working after providing popup.openBy(button);
but I am facing the same issue with ViewSettingsDialog as well and the issue still persist even after placing popup.openBy(button)...could you please say where I am going wrong
button=new sap.m.Button( {
icon: "sap-icon://action-settings",
text:"dialog",
press: function(){
oPopOver=new sap.m.ViewSettingsDialog({ title:"sort and filter"})
oPopOver.openBy(button);
}
}),
In your code you are using sap.m.popover but now you changed?
okey sap.m.ViewSettingsDialog not having OpenBy method.use open() method,
API- JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.m.ViewSettingsDialog
Working example- openui5/ViewSettingsDialog.html at master · SAP/openui5 · GitHub
explored-SAPUI5 Explored
Use this.
new sap.m.Button( {
icon: "sap-icon://action-settings",
text:"dialog",
press: function(){ //press instead of tap
console.log("BUTTON PRESSED"),
new sap.m.Popover({ title:"sort and filter"})
}
}),
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.