1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-11 11:51:27 +00:00

Add internal links to the dir (#3947)

* Add internal links to the dir

* Indent style
This commit is contained in:
zxj96
2019-08-05 17:31:15 +08:00
committed by Daniel Pan
parent affa4f8d12
commit c7933c7f63
4 changed files with 20 additions and 8 deletions

View File

@@ -10,6 +10,7 @@ import { Utils } from '../../utils/utils';
const propTypes = {
path: PropTypes.string.isRequired,
repoID: PropTypes.string.isRequired,
direntType: PropTypes.string
};
class InternalLink extends React.Component {
@@ -21,9 +22,8 @@ class InternalLink extends React.Component {
}
componentDidMount() {
let repoID = this.props.repoID;
let path = this.props.path;
seafileAPI.getInternalLink(repoID, path).then(res => {
let { repoID, path, direntType } = this.props;
seafileAPI.getInternalLink(repoID, path, direntType).then(res => {
this.setState({
smartLink: res.data.smart_link
});