* Finish task#57901.

This commit is contained in:
leiyong
2022-06-22 02:58:47 +00:00
parent 0feed34baa
commit a5df9de8ad
4 changed files with 18 additions and 7 deletions
+1
View File
@@ -1,2 +1,3 @@
#notice {margin-bottom: 0px;}
#deptList {padding: 15px 0px;}
#loadPrompt {border: none;}
+2
View File
@@ -87,6 +87,8 @@ $lang->webhook->paramsList['comment'] = 'Comment';
$lang->webhook->paramsList['text'] = 'Action Description';
$lang->webhook->confirmDelete = 'Do you want to delete this hook?';
$lang->webhook->friendlyTips = 'Friendly reminder: Click on a department to expand the sub-departments under the department.';
$lang->webhook->loadPrompt = 'There is a lot of data and the loading is slow, please wait.';
$lang->webhook->trimWords = '';
+2 -1
View File
@@ -87,7 +87,8 @@ $lang->webhook->paramsList['comment'] = '备注';
$lang->webhook->paramsList['text'] = '操作内容';
$lang->webhook->confirmDelete = '您确认要删除该webhook吗?';
$lang->webhook->loadPrompt = '友情提示:当部门数据较多时,数据加载可能需要较多时间;本列表优先展示一级部门数据,您可以通过点击一级部门标题,自动加载出该部门下的子部门数。';
$lang->webhook->friendlyTips = '友情提示:点击部门,可以展开该部门下的子部门。';
$lang->webhook->loadPrompt = '数据较多,加载缓慢,请稍等。';
$lang->webhook->trimWords = '了';
+13 -6
View File
@@ -19,8 +19,9 @@
</div>
<?php if($webhookType == 'feishuuser'):?>
<div id="notice" class="alert alert-info">
<div class="content"><i class="icon-exclamation-sign"></i> <?php echo $lang->webhook->loadPrompt;?></div>
<div class="content"><i class="icon-exclamation-sign"></i> <?php echo $lang->webhook->friendlyTips;?></div>
</div>
<div id='loadPrompt' class="table-empty-tip"><p><span class="text-muted"><?php echo $lang->webhook->loadPrompt;?></span></p></div>
<?php endif;?>
<ul id='deptList' class="ztree"></ul>
<div class='actions'>
@@ -66,9 +67,10 @@ $(function()
},
callback:
{
beforeClick: beforeClick,
beforeAsync: beforeAsync,
onClick: ztreeOnAsyncSuccess
beforeClick: ztreeBeforeClick,
beforeAsync: ztreeBeforeAsync,
onClick: ztreeOnAsyncSuccess,
onAsyncSuccess: zTreeOnAsyncSuccess
}
};
@@ -82,7 +84,7 @@ $(function()
return childNodes;
}
function beforeClick(treeId, treeNode)
function ztreeBeforeClick(treeId, treeNode)
{
if(treeNode.isParent)
{
@@ -94,7 +96,7 @@ $(function()
}
}
function beforeAsync(treeId, treeNode)
function ztreeBeforeAsync(treeId, treeNode)
{
return true;
}
@@ -144,6 +146,11 @@ $(function()
});
}
function zTreeOnAsyncSuccess()
{
$("#loadPrompt").remove();
}
var ztreeObj = $.fn.zTree.init($("#deptList"), setting);
}
else