1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-11-28 09:24:24 +01:00

migrate to angular 1.4

This commit is contained in:
Sylvain 2018-11-27 13:57:41 +01:00
parent 763f0c21a5
commit ad3105cbc9
7 changed files with 12 additions and 12 deletions

View File

@ -14,7 +14,7 @@ Application.Controllers = angular.module('application.controllers', []);
Application.Filters = angular.module('application.filters', []);
Application.Directives = angular.module('application.directives', []);
angular.module('application', ['ngCookies', 'ngResource', 'ngSanitize', 'ngCookies', 'ui.router', 'ui.bootstrap',
angular.module('application', ['ngCookies', 'ngResource', 'ngSanitize', 'ui.router', 'ui.bootstrap',
'ngUpload', 'duScroll', 'application.filters', 'application.services', 'application.directives',
'frapontillo.bootstrap-switch', 'application.constants', 'application.controllers', 'application.router',
'ui.select', 'ui.calendar', 'angularMoment', 'Devise', 'DeviseModal', 'angular-growl', 'xeditable',

View File

@ -505,7 +505,7 @@ Application.Controllers.controller('EditEventController', ['$scope', '$state', '
// List of categories for the events
$scope.categories = categoriesPromise;
// List of availables price's categories
// List of available price's categories
$scope.priceCategories = priceCategoriesPromise;
// List of events themes

View File

@ -13,7 +13,7 @@
/**
* Navigation controller. List the links availables in the left navigation pane and their icon.
*/
Application.Controllers.controller('MainNavController', ['$scope', '$location', '$cookies', function ($scope, $location, $cookies) {
Application.Controllers.controller('MainNavController', ['$scope', function ($scope) {
// Common links (public application)
$scope.navLinks = [
{

View File

@ -85,7 +85,7 @@ Application.Directives.directive('disableAnimation', ['$animate', ($animate) =>
({
restrict: 'A',
link (scope, elem, attrs) {
return attrs.$observe('disableAnimation', value => $animate.enabled(!value, elem));
return attrs.$observe('disableAnimation', value => $animate.enabled(elem, !value));
}
})
]);

View File

@ -12,9 +12,9 @@ Application.Services.service('CSRF', ['$cookies',
setMetaTags () {
if (angular.element('meta[name="csrf-param"]').length === 0) {
angular.element('head').append('<meta name="csrf-param" content="authenticity_token">');
angular.element('head').append(`<meta name=\"csrf-token\" content=\"${$cookies['XSRF-TOKEN']}\">`);
angular.element('head').append(`<meta name=\"csrf-token\" content=\"${$cookies.get('XSRF-TOKEN')}\">`);
} else {
angular.element('meta[name="csrf-token"]').replaceWith(`<meta name=\"csrf-token\" content=\"${$cookies['XSRF-TOKEN']}\">`);
angular.element('meta[name="csrf-token"]').replaceWith(`<meta name=\"csrf-token\" content=\"${$cookies.get('XSRF-TOKEN')}\">`);
}
}
})

View File

@ -1,6 +1,6 @@
{
"name": "fab-manager",
"version": "2.7.0",
"version": "2.7.1-dev",
"description": "FabManager is the FabLab management solution. It is web-based, open-source and totally free.",
"keywords": [
"fablab",
@ -27,7 +27,7 @@
"dependencies": {
"@uirouter/angularjs": "0.4",
"AngularDevise": "https://github.com/cloudspace/angular_devise.git#1.0.2",
"angular": "1.3",
"angular": "1.4",
"angular-animate": "1.3",
"angular-aside": "1.3",
"angular-base64-upload": "^0.0.9",

View File

@ -190,10 +190,10 @@ angular-xeditable@0.1:
jquery "^1.11.1"
moment "^2.5.0"
angular@1.3:
version "1.3.20"
resolved "https://registry.yarnpkg.com/angular/-/angular-1.3.20.tgz#b23a3d7c5e7f99f7d95b9b4d49b9ac355269baee"
integrity sha1-sjo9fF5/mffZW5tNSbmsNVJpuu4=
angular@1.4:
version "1.4.14"
resolved "https://registry.yarnpkg.com/angular/-/angular-1.4.14.tgz#9d0feaf60ce6e52ce50f49ee328656d1e1875c37"
integrity sha1-nQ/q9gzm5SzlD0nuMoZW0eGHXDc=
angular@^1.0.8, angular@~1.x:
version "1.7.5"