absolutely...
Widget.js:
dojo.provide("StaffRota.widget.StaffRota");
mendix.dom.insertCss(mx.moduleUrl("StaffRota", "widget/ui/staffrota.css"));
dojo.require("StaffRota.widget.jquery");
dojo.require("StaffRota.widget.jquery-ui");
dojo.require("StaffRota.widget.mlv-utils");
mendix.widget.declare("StaffRota.widget.StaffRota", {
......
initSaveRotaButton: function() {
this.saveButton.value = "Save";
this.connect(this.saveButton, "onclick", dojo.hitch(this, this.saveStaff));
}
initSaveRotaButton() is called in postCreate function.
saveStaff: function() {
TableController.xxx();
},
mlv-utils.js:
dojo.provide("StaffRota.widget.mlv-utils");
var TableController = {
xxx:function() { alert('test');};
when i have my main widget file:
and i have three functions
f1: function() {... this.f2();....}, f2: function() {... this.f3();....}, f3: function() {....} can i in another function do this?
anotherFunction() { this.f1(); }
Because it looks like he cant call nested function. Because first function is called, but after that he say i dont know function f2.
Can anybody help?