Removed Get Team Invite Link link when user creation is disabled

Этот коммит содержится в:
Harrison Healey
2016-03-03 16:01:41 -05:00
родитель a413c8ffa6
Коммит 31238f1d3a
2 изменённых файлов: 10 добавлений и 15 удалений

Просмотреть файл

@@ -41,8 +41,6 @@ export default class GetLinkModal extends React.Component {
} }
render() { render() {
const userCreationEnabled = global.window.mm_config.EnableUserCreation === 'true';
let helpText = null; let helpText = null;
if (this.props.helpText) { if (this.props.helpText) {
helpText = ( helpText = (
@@ -55,7 +53,7 @@ export default class GetLinkModal extends React.Component {
} }
let copyLink = null; let copyLink = null;
if (userCreationEnabled && document.queryCommandSupported('copy')) { if (document.queryCommandSupported('copy')) {
copyLink = ( copyLink = (
<button <button
data-copy-btn='true' data-copy-btn='true'
@@ -71,17 +69,14 @@ export default class GetLinkModal extends React.Component {
); );
} }
let linkText = null; const linkText = (
if (userCreationEnabled) { <textarea
linkText = ( className='form-control no-resize min-height'
<textarea readOnly='true'
className='form-control no-resize min-height' ref='textarea'
readOnly='true' value={this.props.link}
ref='textarea' />
value={this.props.link} );
/>
);
}
var copyLinkConfirm = null; var copyLinkConfirm = null;
if (this.state.copiedLink) { if (this.state.copiedLink) {

Просмотреть файл

@@ -107,7 +107,7 @@ export default class NavbarDropdown extends React.Component {
</li> </li>
); );
if (this.props.teamType === Constants.OPEN_TEAM) { if (this.props.teamType === Constants.OPEN_TEAM && global.window.mm_config.EnableUserCreation === 'true') {
teamLink = ( teamLink = (
<li> <li>
<a <a