This commit is contained in:
zhaoke
2023-08-15 15:04:02 +08:00
parent c9e7351098
commit ccc2514810
4 changed files with 8 additions and 4 deletions
+3 -1
View File
@@ -95,7 +95,9 @@ window.checkedChange = function(changes)
*/
window.diffClick = function()
{
var checkedIds = getCurrentCheckedIds();
var checkedIds = getCurrentCheckedIds();
if(checkedIds.length < 2) return;
var newDiffLink = diffLink.replace('{oldRevision}', revisionMap[checkedIds[1]]);
newDiffLink = newDiffLink.replace('{newRevision}', revisionMap[checkedIds[0]]);
+3 -1
View File
@@ -74,7 +74,9 @@ function initRevisionMap(data)
*/
window.diffClick = function()
{
var checkedIds = getCurrentCheckedIds();
var checkedIds = getCurrentCheckedIds();
if(checkedIds.length < 2) return;
var newDiffLink = diffLink.replace('{oldRevision}', revisionMap[checkedIds[1]]);
newDiffLink = newDiffLink.replace('{newRevision}', revisionMap[checkedIds[0]]);
+1 -1
View File
@@ -236,7 +236,7 @@ $commentsTableData = initTableData($revisions, $config->repo->commentDtable->fie
$readAllLink = $this->repo->createLink('log', "repoID=$repoID&objectID=$objectID&entry=" . $encodePath . "&revision=HEAD&type=$logType");
$footToolbar['items'][] = array('text' => $lang->repo->diff, 'class' => "btn primary size-sm btn-diff", 'btnType' => 'primary', 'onClick' => jsRaw('window.diffClick'));
$footToolbar['items'][] = array('text' => $lang->repo->diff, 'className' => "btn primary size-sm btn-diff", 'btnType' => 'primary', 'onClick' => jsRaw('window.diffClick'));
$footToolbar['items'][] = array('text' => $lang->repo->allLog, 'url' => $readAllLink);
sidebar
+1 -1
View File
@@ -53,7 +53,7 @@ $config->repo->logDtable->fieldList['revision']['link'] = array('module' => 'rep
$logs = initTableData($logs, $config->repo->logDtable->fieldList);
$footToolbar['items'][] = array('text' => $lang->repo->diff, 'class' => "btn primary size-sm btn-diff", 'btnType' => 'primary', 'onClick' => jsRaw('window.diffClick'));
$footToolbar['items'][] = array('text' => $lang->repo->diff, 'className' => "btn primary size-sm btn-diff", 'btnType' => 'primary', 'onClick' => jsRaw('window.diffClick'));
featureBar(
backBtn