mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-16 07:08:55 +00:00
Change sdoc frozen icon (#6439)
* 01 change sdoc frozen icon * 02 optimize codes
This commit is contained in:
@@ -680,15 +680,15 @@ class DirentListItem extends React.Component {
|
||||
};
|
||||
|
||||
render() {
|
||||
let { path, dirent } = this.props;
|
||||
let { path, dirent, repoID } = this.props;
|
||||
let direntPath = Utils.joinPath(path, dirent.name);
|
||||
let dirHref = '';
|
||||
if (this.props.currentRepoInfo) {
|
||||
dirHref = siteRoot + 'library/' + this.props.repoID + '/' + this.props.currentRepoInfo.repo_name + Utils.encodePath(direntPath);
|
||||
dirHref = siteRoot + 'library/' + repoID + '/' + this.props.currentRepoInfo.repo_name + Utils.encodePath(direntPath);
|
||||
}
|
||||
let fileHref = siteRoot + 'lib/' + this.props.repoID + '/file' + Utils.encodePath(direntPath);
|
||||
let fileHref = siteRoot + 'lib/' + repoID + '/file' + Utils.encodePath(direntPath);
|
||||
if (dirent.is_sdoc_revision && dirent.revision_id) {
|
||||
fileHref = siteRoot + 'lib/' + this.props.repoID + '/revisions/' + dirent.revision_id + '/';
|
||||
fileHref = siteRoot + 'lib/' + repoID + '/revisions/' + dirent.revision_id + '/';
|
||||
}
|
||||
|
||||
let iconUrl = Utils.getDirentIcon(dirent);
|
||||
|
Reference in New Issue
Block a user