From a075d641fa43cd479aa5865b665e48706e2c116c Mon Sep 17 00:00:00 2001 From: OldHawk Date: Sat, 18 Nov 2017 10:57:39 +0800 Subject: [PATCH] fix(core): fixed server returned message translate 'SCORE_NOT_ENOUGH' --- modules/core/client/app/trans-string-en.js | 3 ++- modules/core/client/app/trans-string-zh.js | 3 ++- .../client/controllers/forums-topic.client.controller.js | 2 +- .../client/controllers/torrent-info.client.controller.js | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/modules/core/client/app/trans-string-en.js b/modules/core/client/app/trans-string-en.js index 5ac8b7b1..36284938 100644 --- a/modules/core/client/app/trans-string-en.js +++ b/modules/core/client/app/trans-string-en.js @@ -1182,7 +1182,8 @@ //server returned string SERVER: { - SENDING_ACTIVE_MAIL_SUCCESSFULLY: 'Welcome join {{site}}, We`ve sent you an email to {{mail}}, please check you mail box and click the active url to verify you mail address and active you account in {{hours}} hours, thanks!' + SENDING_ACTIVE_MAIL_SUCCESSFULLY: 'Welcome join {{site}}, We`ve sent you an email to {{mail}}, please check you mail box and click the active url to verify you mail address and active you account in {{hours}} hours, thanks!', + SCORE_NOT_ENOUGH: 'you don`t have enough score for this operation' } }; diff --git a/modules/core/client/app/trans-string-zh.js b/modules/core/client/app/trans-string-zh.js index b69b18af..5f786115 100644 --- a/modules/core/client/app/trans-string-zh.js +++ b/modules/core/client/app/trans-string-zh.js @@ -1182,7 +1182,8 @@ //server returned string SERVER: { - SENDING_ACTIVE_MAIL_SUCCESSFULLY: '欢迎加入 {{site}}, 我们已向你的邮箱 {{mail}} 发送了一封电子邮件, 请在 {{hours}} 小时内检查您的邮箱并点击邮件中的链接地址来验证您的邮箱地址并激您的帐号,谢谢!' + SENDING_ACTIVE_MAIL_SUCCESSFULLY: '欢迎加入 {{site}}, 我们已向你的邮箱 {{mail}} 发送了一封电子邮件, 请在 {{hours}} 小时内检查您的邮箱并点击邮件中的链接地址来验证您的邮箱地址并激您的帐号,谢谢!', + SCORE_NOT_ENOUGH: '您没有足够的积分进行此操作' } }; diff --git a/modules/forums/client/controllers/forums-topic.client.controller.js b/modules/forums/client/controllers/forums-topic.client.controller.js index abaa61f6..cfdf0fde 100644 --- a/modules/forums/client/controllers/forums-topic.client.controller.js +++ b/modules/forums/client/controllers/forums-topic.client.controller.js @@ -525,7 +525,7 @@ $compile(ele)($scope); }, 10); }, function (res) { - NotifycationService.showErrorNotify(res.data.message, 'ERROR'); + NotifycationService.showErrorNotify($translate.instant(res.data.message), 'ERROR'); }); }; diff --git a/modules/torrents/client/controllers/torrent-info.client.controller.js b/modules/torrents/client/controllers/torrent-info.client.controller.js index 7133fdf5..333c7869 100644 --- a/modules/torrents/client/controllers/torrent-info.client.controller.js +++ b/modules/torrents/client/controllers/torrent-info.client.controller.js @@ -1025,7 +1025,7 @@ }); }, function (res) { Notification.error({ - message: res.data.message, + message: $translate.instant(res.data.message), title: ' ' + $translate.instant('TORRENT_THUMBS_FAILED') }); });