feat(users): use displayName alternative first name and last name

This commit is contained in:
OldHawk
2017-11-09 16:36:40 +08:00
parent 8de65c386c
commit 22343353bd
12 changed files with 24 additions and 65 deletions

View File

@@ -22,15 +22,16 @@
return false;
}
vm.user.lastName = '';
var user = new UsersService(vm.user);
user.$update(function (response) {
$scope.$broadcast('show-errors-reset', 'vm.userForm');
Notification.success({ message: '<i class="glyphicon glyphicon-ok"></i> Edit profile successful!' });
Notification.success({message: '<i class="glyphicon glyphicon-ok"></i> Edit profile successful!'});
Authentication.user = response;
}, function (response) {
Notification.error({ message: response.data.message, title: '<i class="glyphicon glyphicon-remove"></i> Edit profile failed!' });
Notification.error({message: response.data.message, title: '<i class="glyphicon glyphicon-remove"></i> Edit profile failed!'});
});
}
}