|
@@ -21,7 +21,7 @@ import {
|
|
|
} from './utils/commons';
|
|
} from './utils/commons';
|
|
|
|
|
|
|
|
type Props = CommonProps & {
|
|
type Props = CommonProps & {
|
|
|
-
|
|
|
|
|
|
|
+ registrationMode: string,
|
|
|
pageWithMetaStr: string,
|
|
pageWithMetaStr: string,
|
|
|
isMailerSetup: boolean,
|
|
isMailerSetup: boolean,
|
|
|
enabledStrategies: unknown,
|
|
enabledStrategies: unknown,
|
|
@@ -55,6 +55,7 @@ const LoginPage: NextPage<Props> = (props: Props) => {
|
|
|
registrationWhiteList={props.registrationWhiteList}
|
|
registrationWhiteList={props.registrationWhiteList}
|
|
|
isPasswordResetEnabled={true}
|
|
isPasswordResetEnabled={true}
|
|
|
isMailerSetup={props.isMailerSetup}
|
|
isMailerSetup={props.isMailerSetup}
|
|
|
|
|
+ registrationMode={props.registrationMode}
|
|
|
/>
|
|
/>
|
|
|
</NoLoginLayout>
|
|
</NoLoginLayout>
|
|
|
);
|
|
);
|
|
@@ -106,6 +107,7 @@ async function injectServerConfigurations(context: GetServerSidePropsContext, pr
|
|
|
props.isLdapSetupFailed = configManager.getConfig('crowi', 'security:passport-ldap:isEnabled') && !props.isLdapStrategySetup;
|
|
props.isLdapSetupFailed = configManager.getConfig('crowi', 'security:passport-ldap:isEnabled') && !props.isLdapStrategySetup;
|
|
|
props.registrationWhiteList = configManager.getConfig('crowi', 'security:registrationWhiteList');
|
|
props.registrationWhiteList = configManager.getConfig('crowi', 'security:registrationWhiteList');
|
|
|
props.isEmailAuthenticationEnabled = configManager.getConfig('crowi', 'security:passport-local:isEmailAuthenticationEnabled');
|
|
props.isEmailAuthenticationEnabled = configManager.getConfig('crowi', 'security:passport-local:isEmailAuthenticationEnabled');
|
|
|
|
|
+ props.registrationMode = configManager.getConfig('crowi', 'security:registrationMode');
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
export const getServerSideProps: GetServerSideProps = async(context: GetServerSidePropsContext) => {
|
|
export const getServerSideProps: GetServerSideProps = async(context: GetServerSidePropsContext) => {
|