mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-04 16:31:13 +00:00
Wiki search modify (#2346)
* modify search privilege * modify params * modify search module
This commit is contained in:
committed by
zheng xie
parent
83f6485bea
commit
ed65284bda
@@ -8,9 +8,10 @@ export const mediaUrl = window.app.config.mediaUrl;
|
|||||||
export const siteTitle = window.app.config.siteTitle;
|
export const siteTitle = window.app.config.siteTitle;
|
||||||
export const logoWidth = window.app.config.logoWidth;
|
export const logoWidth = window.app.config.logoWidth;
|
||||||
export const logoHeight = window.app.config.logoHeight;
|
export const logoHeight = window.app.config.logoHeight;
|
||||||
|
export const isPro = window.app.config.isPro === "True";
|
||||||
|
|
||||||
export const slug = window.wiki.config.slug;
|
export const slug = window.wiki.config.slug;
|
||||||
export const repoID = window.wiki.config.repoId;
|
export const repoID = window.wiki.config.repoId;
|
||||||
export const serviceUrl = window.wiki.config.serviceUrl;
|
export const serviceUrl = window.wiki.config.serviceUrl;
|
||||||
export const initialFilePath = window.wiki.config.initial_file_path;
|
export const initialFilePath = window.wiki.config.initial_file_path;
|
||||||
export const permission = window.wiki.config.permission
|
export const permission = window.wiki.config.permission;
|
||||||
|
@@ -1,10 +1,11 @@
|
|||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
import { gettext, repoID, serviceUrl, slug, siteRoot } from '../../components/constance';
|
import { gettext, repoID, serviceUrl, slug, siteRoot, isPro } from '../../components/constance';
|
||||||
import Search from '../../components/search';
|
import Search from '../../components/search';
|
||||||
import Account from '../../components/account';
|
import Account from '../../components/account';
|
||||||
import MarkdownViewer from '../../components/markdown-viewer';
|
import MarkdownViewer from '../../components/markdown-viewer';
|
||||||
import TreeDirView from '../../components/tree-dir-view/tree-dir-view';
|
import TreeDirView from '../../components/tree-dir-view/tree-dir-view';
|
||||||
|
|
||||||
|
|
||||||
class MainPanel extends Component {
|
class MainPanel extends Component {
|
||||||
|
|
||||||
onMenuClick = () => {
|
onMenuClick = () => {
|
||||||
@@ -49,7 +50,7 @@ class MainPanel extends Component {
|
|||||||
<a className="btn btn-secondary btn-topbar" onClick={this.onEditClick}>{gettext("Edit Page")}</a>
|
<a className="btn btn-secondary btn-topbar" onClick={this.onEditClick}>{gettext("Edit Page")}</a>
|
||||||
</div>
|
</div>
|
||||||
<div className="common-toolbar">
|
<div className="common-toolbar">
|
||||||
<Search onSearchedClick={this.props.onSearchedClick}/>
|
{isPro && <Search onSearchedClick={this.props.onSearchedClick}/>}
|
||||||
<Account />
|
<Account />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -29,6 +29,7 @@
|
|||||||
logoHeight: '{{ logo_height }}',
|
logoHeight: '{{ logo_height }}',
|
||||||
siteTitle: '{{ site_title }}',
|
siteTitle: '{{ site_title }}',
|
||||||
siteRoot: '{{ SITE_ROOT }}',
|
siteRoot: '{{ SITE_ROOT }}',
|
||||||
|
isPro: '{{ is_pro }}'
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
Reference in New Issue
Block a user