Merge pull request #1172 from wknet123/master-handle-sign-in-error

Fixed handle other errors while signing in.
NMT
This commit is contained in:
yhua123 2016-11-28 10:57:01 +08:00 committed by GitHub
commit a192ce90c6
3 changed files with 5 additions and 1 deletions

View File

@ -69,9 +69,11 @@
function signedInFailed(data, status) {
vm.signInTIP = false;
vm.hasError = true;
if(status === 401) {
vm.hasError = true;
vm.errorMessage = 'username_or_password_is_incorrect';
}else {
vm.errorMessage = 'failed_to_sign_in';
}
console.log('Failed to sign in:' + data + ', status:' + status);
}

View File

@ -269,6 +269,7 @@ var locale_messages = {
'failed_to_update_destination': 'Failed to update destination.',
'failed_to_toggle_publicity_insuffient_permissions': 'Failed to toggle project publicity, insuffient permissions.',
'failed_to_toggle_publicity': 'Failed to toggle project publicity.',
'failed_to_sign_in': 'Failed to sign in.',
'project_does_not_exist': 'Project does not exist.',
'project_admin': 'Project Admin',
'developer': 'Developer',

View File

@ -269,6 +269,7 @@ var locale_messages = {
'failed_to_update_destination': '修改目标失败。',
'failed_to_toggle_publicity_insuffient_permissions': '切换项目公开性失败,权限不足。',
'failed_to_toggle_publicity': '切换项目公开性失败。',
'failed_to_sign_in': '登录失败。',
'project_does_not_exist': '项目不存在。',
'project_admin': '项目管理员',
'developer': '开发人员',