mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-08 02:10:24 +00:00
repair visit file history bug
This commit is contained in:
@@ -46,8 +46,8 @@ class HistoryItem extends React.Component {
|
||||
let item = this.props.item;
|
||||
let downloadUrl = URLDecorator.getUrl({type: 'download_historic_file', filePath: filePath, objID: item.rev_file_id});
|
||||
let userProfileURL = `${siteRoot}profile/${encodeURIComponent(item.creator_email)}/`;
|
||||
let viewUrl = `${siteRoot}repo/${historyRepoID}/history/files/?obj_id=${item.rev_file_id}&commit_id=${item.commit_id}&p=${filePath}`;
|
||||
let diffUrl = `${siteRoot}repo/text_diff/${historyRepoID}/?commit=${item.commit_id}&p=${filePath}`;
|
||||
let viewUrl = `${siteRoot}repo/${historyRepoID}/history/files/?obj_id=${item.rev_file_id}&commit_id=${item.commit_id}&p=${Utils.encodePath(filePath)}`;
|
||||
let diffUrl = `${siteRoot}repo/text_diff/${historyRepoID}/?commit=${item.commit_id}&p=${Utils.encodePath(filePath)}`;
|
||||
return (
|
||||
<Fragment>
|
||||
<tr onMouseEnter={this.onMouseEnter} onMouseLeave={this.onMouseLeave} className={this.state.active ? 'tr-highlight' : ''}>
|
||||
|
@@ -7,7 +7,7 @@ class URLDecorator {
|
||||
let params = '';
|
||||
switch (options.type) {
|
||||
case 'download_historic_file':
|
||||
params = 'p=' + options.filePath;
|
||||
params = 'p=' + Utils.encodePath(options.filePath);
|
||||
url = siteRoot + 'repo/' + historyRepoID + '/' + options.objID + '/download?' + params;
|
||||
break;
|
||||
case 'download_file_url':
|
||||
|
Reference in New Issue
Block a user