+ Add language for repo.

This commit is contained in:
caoyanyi
2024-04-07 10:40:49 +08:00
parent 36a2a7f674
commit be062d3517
5 changed files with 25 additions and 3 deletions
+2
View File
@@ -280,9 +280,11 @@ $lang->repo->errorLang[1] = 'Branch is exists';
$lang->repo->errorLang[2] = 'branch .* already exists';
$lang->repo->errorLang[3] = 'Forbidden';
$lang->repo->errorLang[4] = 'cannot have ASCII control characters';
$lang->repo->errorLang[5] = 'Created fail';
$lang->repo->apiError[0] = "can contain only letters, digits, '_', '-' and '.'. Cannot start with '-', end in '.git' or end in '.atom'";
$lang->repo->apiError[1] = 'Branch is exists';
$lang->repo->apiError[2] = 'branch .* already exists';
$lang->repo->apiError[3] = 'Forbidden';
$lang->repo->apiError[4] = 'cannot have ASCII control characters';
$lang->repo->apiError[5] = 'Created fail';
+2
View File
@@ -280,9 +280,11 @@ $lang->repo->errorLang[1] = 'Branch is exists';
$lang->repo->errorLang[2] = 'branch .* already exists';
$lang->repo->errorLang[3] = 'Forbidden';
$lang->repo->errorLang[4] = 'cannot have ASCII control characters';
$lang->repo->errorLang[5] = 'Created fail';
$lang->repo->apiError[0] = "can contain only letters, digits, '_', '-' and '.'. Cannot start with '-', end in '.git' or end in '.atom'";
$lang->repo->apiError[1] = 'Branch is exists';
$lang->repo->apiError[2] = 'branch .* already exists';
$lang->repo->apiError[3] = 'Forbidden';
$lang->repo->apiError[4] = 'cannot have ASCII control characters';
$lang->repo->apiError[5] = 'Created fail';
+2
View File
@@ -280,9 +280,11 @@ $lang->repo->errorLang[1] = 'Branch is exists';
$lang->repo->errorLang[2] = 'branch .* already exists';
$lang->repo->errorLang[3] = 'Forbidden';
$lang->repo->errorLang[4] = 'cannot have ASCII control characters';
$lang->repo->errorLang[5] = 'Created fail';
$lang->repo->apiError[0] = "can contain only letters, digits, '_', '-' and '.'. Cannot start with '-', end in '.git' or end in '.atom'";
$lang->repo->apiError[1] = 'Branch is exists';
$lang->repo->apiError[2] = 'branch .* already exists';
$lang->repo->apiError[3] = 'Forbidden';
$lang->repo->apiError[4] = 'cannot have ASCII control characters';
$lang->repo->apiError[5] = 'Created fail';
+2
View File
@@ -280,9 +280,11 @@ $lang->repo->errorLang[1] = '分支名已存在。';
$lang->repo->errorLang[2] = '分支名已存在。';
$lang->repo->errorLang[3] = '权限不足。';
$lang->repo->errorLang[4] = "分支名不能包含 ' ', '~', '^'或':'。";
$lang->repo->errorLang[5] = '分支创建失败';
$lang->repo->apiError[0] = "can contain only letters, digits, '_', '-' and '.'. Cannot start with '-', end in '.git' or end in '.atom'";
$lang->repo->apiError[1] = 'Branch is exists';
$lang->repo->apiError[2] = 'branch .* already exists';
$lang->repo->apiError[3] = 'Forbidden';
$lang->repo->apiError[4] = 'cannot have ASCII control characters';
$lang->repo->apiError[5] = 'Created fail';
+17 -3
View File
@@ -10,9 +10,6 @@ declare(strict_types=1);
*/
namespace zin;
to::header(false);
to::main(false);
jsVar('module', $objectType);
jsVar('linkParams', "objectID={$objectID}&repoID=%s");
modalHeader
@@ -75,6 +72,23 @@ empty($linkedBranches) ? null : div
)
);
if(empty($linkedBranches) && !$canCreate)
{
div
(
setClass('canvas text-center py-2'),
p
(
setClass('py-2 my-2'),
span
(
setClass('text-gray'),
$lang->noData
)
)
);
}
$canCreate ? formPanel
(
set::title($lang->repo->createBranchAction),