diff --git a/store/sql_team_store.go b/store/sql_team_store.go
index dfc07d3d88..e0f95fa7e3 100644
--- a/store/sql_team_store.go
+++ b/store/sql_team_store.go
@@ -32,7 +32,7 @@ func NewSqlTeamStore(sqlStore *SqlStore) TeamStore {
func (s SqlTeamStore) UpgradeSchemaIfNeeded() {
// REMOVE AFTER 1.2 SHIP see PLT-828
s.RemoveColumnIfExists("Teams", "AllowValet")
- s.CreateColumnIfNotExists("Teams", "InviteId", "varchar(26)", "varchar(26)", "")
+ s.CreateColumnIfNotExists("Teams", "InviteId", "varchar(32)", "varchar(32)", "")
s.CreateColumnIfNotExists("Teams", "AllowOpenInvite", "tinyint(1)", "boolean", "0")
s.CreateColumnIfNotExists("Teams", "AllowTeamListing", "tinyint(1)", "boolean", "0")
}
diff --git a/web/react/components/login.jsx b/web/react/components/login.jsx
index c519959af2..2b9ce67caf 100644
--- a/web/react/components/login.jsx
+++ b/web/react/components/login.jsx
@@ -185,7 +185,7 @@ export default class Login extends React.Component {
if (this.props.inviteId) {
userSignUp = (
);
+ }
+ } else {
+ teamListing = (
+
+
{'Choose a Team'}
+
+ {
+ this.props.teams.map((team) => {
+ return (
+
+ );
+ })
+ }
+
+
+ );
+ }
+ }
+
+ if (global.window.mm_config.EnableTeamCreation !== 'true') {
+ if (teamListing == null) {
+ return ({'Team creation has been disabled. Please contact an administrator for access.'}
);
+ }
+
return (
-
{'Choose a Team'}
-
- {
- this.props.teams.map((team) => {
- return (
-
- );
- })
- }
-
+ {teamListing}
);
}
if (this.state.page === 'choose') {
return (
-
+
+ {teamListing}
+
+
);
}
if (this.state.page === 'email') {
- return ;
+ return (
+
+ {teamListing}
+
+
+ );
} else if (this.state.page === 'gitlab') {
- return ;
+ return (
+
+ {teamListing}
+
+
+ );
}
}
}
diff --git a/web/react/components/team_general_tab.jsx b/web/react/components/team_general_tab.jsx
index 69ba446641..c7c4fa2ea1 100644
--- a/web/react/components/team_general_tab.jsx
+++ b/web/react/components/team_general_tab.jsx
@@ -54,7 +54,6 @@ export default class GeneralTab extends React.Component {
handleTeamListingRadio(listing) {
if (global.window.mm_config.EnableTeamListing !== 'true' && listing) {
- ReactDOM.findDOMNode(this.refs.teamListingRadioNo).checked = true;
this.setState({clientError: 'Team directory has been disabled. Please ask a system admin to enable it.'});
} else {
this.setState({allow_team_listing: listing});
@@ -278,13 +277,13 @@ export default class GeneralTab extends React.Component {
- {'When allowed the team will appear on the main page as part of team directory.'}
+ {'Including this team will display the team name from the Team Directory section of the Home Page, and provide a link to the sign-in page.'}
];
teamListingSection = (
@@ -337,13 +336,13 @@ export default class GeneralTab extends React.Component {
- {'When allowed the team signup link will be included on the login page and anyone can signup to this team.'}
+ {'When allowed, a link to account creation will be included on the sign-in page of this team and allow any visitor to sign-up.'}
];
openInviteSection = (
@@ -387,7 +386,7 @@ export default class GeneralTab extends React.Component {
maxLength='32'
/>
- {'When allowing open invites this code is used as part of the signup process. Changing this code will invalidate the previous open signup link.'}
+ {'Your Invite Code is used in the URL sent to people to join your team. Regenerating your Invite Code will invalidate the URLs in previous invitations, unless "Allow anyone to sign-up from login page" is enabled.'}
);
diff --git a/web/sass-files/sass/partials/_signup.scss b/web/sass-files/sass/partials/_signup.scss
index 14c676f823..84f9892f47 100644
--- a/web/sass-files/sass/partials/_signup.scss
+++ b/web/sass-files/sass/partials/_signup.scss
@@ -316,7 +316,7 @@
.signup-team-all {
width: 280px;
box-shadow: 3px 3px 1px #d5d5d5;
- margin: 0px 0px 0px 5px;
+ margin: 0px 0px 50px 5px;
}
.signup-team-dir {
diff --git a/web/web.go b/web/web.go
index 34f4df08f0..51f6664b6c 100644
--- a/web/web.go
+++ b/web/web.go
@@ -170,7 +170,7 @@ func root(c *api.Context, w http.ResponseWriter, r *http.Request) {
page.Props[team.Name] = team.DisplayName
}
- if len(teams) == 1 && *utils.Cfg.TeamSettings.EnableTeamListing {
+ if len(teams) == 1 && *utils.Cfg.TeamSettings.EnableTeamListing && !utils.Cfg.TeamSettings.EnableTeamCreation {
http.Redirect(w, r, c.GetSiteURL()+"/"+teams[0].Name, http.StatusTemporaryRedirect)
return
}