branch develop updated (6185a83 -> e2da9f9)
This is an automated email from the git hooks/post-receive script. New change to branch develop in repository coselmar. See http://git.codelutin.com/coselmar.git from 6185a83 fix referential search for documents new e2da9f9 on user edit, keep information if login is not a mail internal-test #6307 The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit e2da9f9d39a27a260b9d02a7bba20a7de07a6d7b Author: Yannick Martel <martel@©odelutin.com> Date: Wed Feb 18 16:46:56 2015 +0100 on user edit, keep information if login is not a mail internal-test #6307 Summary of changes: coselmar-ui/src/main/webapp/js/coselmar-controllers.js | 7 ++++++- coselmar-ui/src/main/webapp/js/coselmar-user-services.js | 6 ++---- 2 files changed, 8 insertions(+), 5 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository coselmar. See http://git.codelutin.com/coselmar.git commit e2da9f9d39a27a260b9d02a7bba20a7de07a6d7b Author: Yannick Martel <martel@©odelutin.com> Date: Wed Feb 18 16:46:56 2015 +0100 on user edit, keep information if login is not a mail internal-test #6307 --- coselmar-ui/src/main/webapp/js/coselmar-controllers.js | 7 ++++++- coselmar-ui/src/main/webapp/js/coselmar-user-services.js | 6 ++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/coselmar-ui/src/main/webapp/js/coselmar-controllers.js b/coselmar-ui/src/main/webapp/js/coselmar-controllers.js index f8b7490..64a4f00 100644 --- a/coselmar-ui/src/main/webapp/js/coselmar-controllers.js +++ b/coselmar-ui/src/main/webapp/js/coselmar-controllers.js @@ -643,7 +643,12 @@ coselmarControllers.controller("UserViewCtrl", $scope.messages = []; } - userService.getUser($routeParams.userId, $scope); + userService.getUser($routeParams.userId, function(user) { + $scope.user = user; + var emailPattern = /^[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+((\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)?)+@(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9\-]*[a-zA-Z0-9])?$/; + $scope.simpleLogin = !emailPattern.test(user.mail); + console.log($scope.simpleLogin); + }, errorService.defaultFailOnCall); $scope.deleteUser = function(userId){ diff --git a/coselmar-ui/src/main/webapp/js/coselmar-user-services.js b/coselmar-ui/src/main/webapp/js/coselmar-user-services.js index 850dcd6..1f18b3c 100644 --- a/coselmar-ui/src/main/webapp/js/coselmar-user-services.js +++ b/coselmar-ui/src/main/webapp/js/coselmar-user-services.js @@ -49,12 +49,10 @@ function User(resource, config){ userResource.save(null, param, successFunction, failFunction); } - this.getUser = function(id, scope){ + this.getUser = function(id, successFunction, failFunction){ // Load the User var userResource = resource(baseURL + '/:userId', {userId:'@userId'}); - userResource.get({userId:id}, function(user){ - scope.user = user; - }); + userResource.get({userId:id}, successFunction, failFunction); } this.deleteUser = function(id, scope, successFunction){ -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
participants (1)
-
codelutin.com scm