-
{gettext('Libraries')}
-
/
+ {pathPrefix ?
+ pathPrefix :
+
+ {gettext('Libraries')}
+ /
+
+ }
{currentPath === '/' ?
{repoName}:
{repoName}
diff --git a/frontend/src/components/cur-dir-path/index.js b/frontend/src/components/cur-dir-path/index.js
index 59215351a4..fbacc1e922 100644
--- a/frontend/src/components/cur-dir-path/index.js
+++ b/frontend/src/components/cur-dir-path/index.js
@@ -5,6 +5,7 @@ import DirTool from './dir-tool';
const propTypes = {
repoID: PropTypes.string.isRequired,
+ pathPrefix: PropTypes.object.isRequired,
repoName: PropTypes.string.isRequired,
permission: PropTypes.bool.isRequired,
currentPath: PropTypes.string.isRequired,
@@ -18,6 +19,7 @@ class CurDirPath extends React.Component {
diff --git a/frontend/src/components/dir-view/dir-panel.js b/frontend/src/components/dir-view/dir-panel.js
index cc7ce5a04a..63034f10ac 100644
--- a/frontend/src/components/dir-view/dir-panel.js
+++ b/frontend/src/components/dir-view/dir-panel.js
@@ -14,6 +14,7 @@ import FileUploader from '../file-uploader/file-uploader';
const propTypes = {
currentRepo: PropTypes.object,
+ pathPrefix: PropTypes.object.isRequired,
path: PropTypes.string.isRequired,
repoID: PropTypes.string.isRequired,
repoName: PropTypes.string.isRequired,
@@ -147,6 +148,7 @@ class DirPanel extends React.Component {
{
@@ -430,6 +424,7 @@ class DirView extends React.Component {
render() {
return (
{
- this.props.tabItemClick(param);
+ tabItemClick = (param, id) => {
+ this.props.tabItemClick(param, id);
}
getActiveClass = (tab) => {
@@ -76,7 +76,7 @@ class MainSideNav extends React.Component {
{this.state.groupItems.map(item => {
return (
- this.tabItemClick(item.id)}>
+ this.tabItemClick(item.name, item.id)}>
#
{item.name}
diff --git a/frontend/src/components/shared-repo-list-view/shared-repo-list-item.js b/frontend/src/components/shared-repo-list-view/shared-repo-list-item.js
index 3f47415558..ebf8ad26e9 100644
--- a/frontend/src/components/shared-repo-list-view/shared-repo-list-item.js
+++ b/frontend/src/components/shared-repo-list-view/shared-repo-list-item.js
@@ -2,6 +2,7 @@ import React, { Fragment } from 'react';
import PropTypes from 'prop-types';
import moment from 'moment';
import { Dropdown, DropdownMenu, DropdownToggle, DropdownItem } from 'reactstrap';
+import { Link } from '@reach/router';
import { Utils } from '../../utils/utils';
import { gettext, siteRoot, isPro, username, folderPermEnabled } from '../../utils/constants';
@@ -91,7 +92,7 @@ class SharedRepoListItem extends React.Component {
});
//todo change to library; div-view is not compatibility
- let libPath = `${siteRoot}#group/${currentGroup.id}/lib/${this.props.repo.repo_id}/`;
+ let libPath = `${siteRoot}library/${this.props.repo.repo_id}/`;
return { iconUrl, iconTitle, libPath };
}
@@ -269,7 +270,7 @@ class SharedRepoListItem extends React.Component {
return (
 |
- {repo.repo_name} |
+ {repo.repo_name} |
{this.state.isOperationShow && this.generatorPCMenu()} |
{repo.size} |
{moment(repo.last_modified).fromNow()} |