diff --git a/module/gitlab/control.php b/module/gitlab/control.php index ac4196625f..b7a6107482 100644 --- a/module/gitlab/control.php +++ b/module/gitlab/control.php @@ -245,7 +245,7 @@ class gitlab extends control $gitlabURL = trim($this->post->url); $token = trim($this->post->token); - if(strpos($gitlabURL, 'http') !== 0) return $this->send(array('result' => 'fail', 'message' => array('url' => array($this->lang->gitlab->hostError)))); + if(strpos($gitlabURL, 'http') !== 0) return $this->send(array('result' => 'fail', 'message' => array('url' => array(sprintf($this->lang->gitlab->hostError, $this->config->gitlab->minCompatibleVersion))))); if(!$token) return $this->send(array('result' => 'fail', 'message' => array('token' => array($this->lang->gitlab->tokenError)))); $user = $this->gitlab->apiGetCurrentUser($gitlabURL, $token, true); diff --git a/module/gitlab/lang/en.php b/module/gitlab/lang/en.php index 99fcdfb616..f34d82488e 100644 --- a/module/gitlab/lang/en.php +++ b/module/gitlab/lang/en.php @@ -86,7 +86,7 @@ $lang->gitlab->placeholder->projectPath = "It should contain only letters, digit $lang->gitlab->noImportableIssues = "There are currently no issues available for import."; $lang->gitlab->tokenError = "The current token is not root rights."; $lang->gitlab->tokenLimit = "The current token has no admin privilege. Please regenerate one with root user in GitLab."; -$lang->gitlab->hostError = "Invalid GitLab service address."; +$lang->gitlab->hostError = "So the current GitLab server address is invalid or the current GitLab version is not compatible with ZenTao, please confirm that the current server can be accessed or contact the administrator to upgrade the GitLab version to %s and try again."; $lang->gitlab->bindUserError = "Can not bind users repeatedly %s"; $lang->gitlab->importIssueError = "The execution to which this issue belongs is not selected."; $lang->gitlab->importIssueWarn = "There is a problem of import failure, you can try to import again."; diff --git a/module/gitlab/lang/zh-cn.php b/module/gitlab/lang/zh-cn.php index 23af32006e..595e3b8b48 100644 --- a/module/gitlab/lang/zh-cn.php +++ b/module/gitlab/lang/zh-cn.php @@ -86,7 +86,7 @@ $lang->gitlab->placeholder->projectPath = "项目标识串只能包含字母、 $lang->gitlab->noImportableIssues = "目前没有可供导入的issue。"; $lang->gitlab->tokenError = "当前token非root权限。"; $lang->gitlab->tokenLimit = "GitLab Token权限不足。请更换为有root权限的GitLab Token。"; -$lang->gitlab->hostError = "无效的GitLab服务地址。"; +$lang->gitlab->hostError = "当前GitLab服务器地址无效或当前GitLab版本与禅道不兼容,请确认当前服务器可被访问或联系管理员升级GitLab版本至%s后重试"; $lang->gitlab->bindUserError = "不能重复绑定用户 %s"; $lang->gitlab->importIssueError = "未选择该issue所属的执行。"; $lang->gitlab->importIssueWarn = "存在导入失败的issue,可再次尝试导入。";