I'm trying to use Smart field in my new XML view without Smart filter bar in SAPUI5. I want to display this after press F4 like it is in Smart filter bar: Printscreen
I've already initialized OData service in my controller.js:
onInit: function() {
var oModel, oView;
oModel = new sap.ui.model.odata.ODataModel("<serverURL>/sap/opu/odata/sap/ZACTIONS_SRV/", true);
oModel.setCountSupported(false);
oView = this.getView();
oView.setModel(oModel);
},
And this is my XML view:
<form:content>
<smartField:SmartLabel labelFor="Applctn"/>
<smartField:SmartField value="{Applctn}" id="Applctn"/>
</form:content>
But I get this error in Chrome and no Smart field is displayed. Error