[#369] remove moment.js deprecate warnings

This commit is contained in:
Alexander Machehin 2014-10-16 16:43:04 +06:00
parent cf13084d26
commit c5ea3d7c66
3 changed files with 3 additions and 3 deletions

View File

@ -27,7 +27,7 @@ RosaABF.controller('BuildListsController',
<%=BuildList::REJECTED_PUBLISH%>: 0 <%=BuildList::REJECTED_PUBLISH%>: 0
}; };
$scope.minDate = new Date(2010, 1, 1); $scope.minDate = new Date(2010, 1, 1);
$scope.maxDate = moment().add('months', 1).calendar(); $scope.maxDate = moment().add(1, 'months').calendar();
$scope.today = function() { $scope.today = function() {
$scope.dt = new Date(); $scope.dt = new Date();

View File

@ -2,7 +2,7 @@ RosaABF.controller('RosaABFController', ['$scope', 'LocalesHelper', 'SoundNotifi
function($scope, LocalesHelper, SoundNotificationsHelper) { function($scope, LocalesHelper, SoundNotificationsHelper) {
$scope.init = function(locale, sound_notifications) { $scope.init = function(locale, sound_notifications) {
LocalesHelper.setLocale(locale); LocalesHelper.setLocale(locale);
moment.lang(locale); moment.locale(locale);
SoundNotificationsHelper.enabled(sound_notifications); SoundNotificationsHelper.enabled(sound_notifications);
} }
}]); }]);

View File

@ -50,7 +50,7 @@ function weekdaysCaseReplace(m, format) {
return weekdays[nounCase][m.day()]; return weekdays[nounCase][m.day()];
} }
moment.lang('ru', { moment.locale('ru', {
months : monthsCaseReplace, months : monthsCaseReplace,
monthsShort : "янв_фев_мар_апрай_июн_июл_авг_сен_окт_ноя_дек".split("_"), monthsShort : "янв_фев_мар_апрай_июн_июл_авг_сен_окт_ноя_дек".split("_"),
weekdays : weekdaysCaseReplace, weekdays : weekdaysCaseReplace,