I've been trying to use this.getView()
on my controllers a couple of times but I'm always getting getView is not a function error on my console.
Is there any "trick" or something that I can do to make this work?
Heres's an example of how I'm using it (this is a function I've created in my controller):
formatIconStatus: function(status){
var view = this.getView();
if (status != null){
if (status == "YES"){
status = "sap-icon://accept";
}else{
status = "sap-icon://error";
}
return status;
}
},
Thanks in advance!