Skip to content

Instantly share code, notes, and snippets.

@hodak
Last active August 29, 2015 14:26
Show Gist options
  • Save hodak/028a87e93f768f7a7b41 to your computer and use it in GitHub Desktop.
Save hodak/028a87e93f768f7a7b41 to your computer and use it in GitHub Desktop.
angular.module("TestApp", ["mightyDatepicker"]);
angular.module("TestApp").controller("TestCtrl", function($scope){
_callthis = function(day) {
console.log("call this: ", day);
}
_filter = function (day) {
w = day.weekday();
return w < 6 && w > 0;
}
$scope.date = null;
$scope.options = {
start: moment().add('month', -1),
months: 1,
filter: _filter,
callback: _callback
}
$scope.multi = [];
$scope.optionsM = {
months: 3,
mode: "multiple",
after: moment().add('month', -3),
before: moment().add('month', 3)
}
});
@leonardoanalista
Copy link

I think line 3 you mean '_callback', not '_callthis' as you get an undefined on line 17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment