* Finish task #7915.
This commit is contained in:
+20
-2
@@ -287,6 +287,14 @@ class repo extends control
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager(0, 8, 1);
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
$oldRevision = isset($this->post->revision[1]) ? $this->post->revision[1] : '';
|
||||
$newRevision = isset($this->post->revision[0]) ? $this->post->revision[0] : '';
|
||||
|
||||
$this->locate( $this->repo->createLink('diff', "repoID=$repoID&entry=" . $this->repo->encodePath(urldecode($path)) . "&oldrevision=$oldRevision&newRevision=$newRevision"));
|
||||
}
|
||||
|
||||
/* Cache infos. */
|
||||
if($refresh or !$cacheFile or !file_exists($cacheFile) or (time() - filemtime($cacheFile)) / 60 > $this->config->repo->cacheTime)
|
||||
{
|
||||
@@ -371,6 +379,14 @@ class repo extends control
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
$oldRevision = isset($this->post->revision[1]) ? $this->post->revision[1] : '';
|
||||
$newRevision = isset($this->post->revision[0]) ? $this->post->revision[0] : '';
|
||||
|
||||
$this->locate( $this->repo->createLink('diff', "repoID=$repoID&entry=" . $this->repo->encodePath(urldecode($path)) . "&oldrevision=$oldRevision&newRevision=$newRevision"));
|
||||
}
|
||||
|
||||
$this->scm->setEngine($repo);
|
||||
$info = $this->scm->info($entry, $revision);
|
||||
|
||||
@@ -558,14 +574,16 @@ class repo extends control
|
||||
$arrange = $this->cookie->arrange ? $this->cookie->arrange : 'inline';
|
||||
if($this->server->request_method == 'POST')
|
||||
{
|
||||
$oldRevision = isset($this->post->revision[1]) ?$this->post->revision[1] : '';
|
||||
$newRevision = isset($this->post->revision[0]) ?$this->post->revision[0] : '';
|
||||
$oldRevision = isset($this->post->revision[1]) ? $this->post->revision[1] : '';
|
||||
$newRevision = isset($this->post->revision[0]) ? $this->post->revision[0] : '';
|
||||
if($this->post->arrange)
|
||||
{
|
||||
$arrange = $this->post->arrange;
|
||||
setcookie('arrange', $arrange);
|
||||
}
|
||||
if($this->post->encoding) $encoding = $this->post->encoding;
|
||||
|
||||
$this->locate( $this->repo->createLink('diff', "repoID=$repoID&entry=$entry&oldrevision=$oldRevision&newRevision=$newRevision&showBug=&encoding=$encoding"));
|
||||
}
|
||||
|
||||
$this->scm->setEngine($repo);
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
$(document).ready(function()
|
||||
{
|
||||
$("#inline").click(function(){$('#arrange').val('inline');this.form.submit();});
|
||||
$("#appose").click(function(){$('#arrange').val('appose');this.form.submit();});
|
||||
$(".label-exchange").click(function(){ $('#exchange').submit();});
|
||||
});
|
||||
function changeEncoding(encoding)
|
||||
{
|
||||
$('#encoding').val(encoding);
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
$pathInfo = '&root=' . $this->repo->encodePath(empty($path) ? '/' : $path);
|
||||
if(isset($entry)) $pathInfo .= '&type=file';
|
||||
?>
|
||||
<form id='logForm' class='main-table' data-ride='table' action='<?php echo $this->repo->createLink('diff', "repoID=$repoID", "entry=" . $this->repo->encodePath($path))?>' method='post'>
|
||||
<form id='logForm' class='main-table' data-ride='table' method='post'>
|
||||
<table class='table table-fixed'>
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
<?php endif;?>
|
||||
</ul>
|
||||
</nav>
|
||||
<form id='logForm' class='main-table' data-ride='table' action='<?php echo $this->repo->createLink('diff', "repoID=$repoID", "entry=" . $this->repo->encodePath($entry))?>' method='post'>
|
||||
<form id='logForm' class='main-table' data-ride='table' method='post'>
|
||||
<table class='table table-fixed' id='logList'>
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
Reference in New Issue
Block a user