mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	Fix accounts_home and login to display no-password correctly.
This fixes the /register/ (accounts_home) and /login/ pages to not display the login form if login isn’t allowed at the organization level.
This commit is contained in:
		
				
					committed by
					
						
						Tim Abbott
					
				
			
			
				
	
			
			
			
						parent
						
							c7f710b8d4
						
					
				
				
					commit
					07ecf971c6
				
			@@ -44,6 +44,7 @@ $(function () {
 | 
				
			|||||||
                        configure authentication backends.</p>
 | 
					                        configure authentication backends.</p>
 | 
				
			||||||
                    </div>
 | 
					                    </div>
 | 
				
			||||||
                    {% else %}
 | 
					                    {% else %}
 | 
				
			||||||
 | 
					                        {% if password_auth_enabled %}
 | 
				
			||||||
                            <form class="form-inline" id="send_confirm" name="email_form"
 | 
					                            <form class="form-inline" id="send_confirm" name="email_form"
 | 
				
			||||||
                                action="{{ current_url() }}" method="post">
 | 
					                                action="{{ current_url() }}" method="post">
 | 
				
			||||||
                                {{ csrf_input }}
 | 
					                                {{ csrf_input }}
 | 
				
			||||||
@@ -68,6 +69,7 @@ $(function () {
 | 
				
			|||||||
                            {% if any_oauth_backend_enabled %}
 | 
					                            {% if any_oauth_backend_enabled %}
 | 
				
			||||||
                            <div class="or">or</div>
 | 
					                            <div class="or">or</div>
 | 
				
			||||||
                            {% endif %}
 | 
					                            {% endif %}
 | 
				
			||||||
 | 
					                        {% endif %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                        {% if google_auth_enabled %}
 | 
					                        {% if google_auth_enabled %}
 | 
				
			||||||
                        <div class="register-google">
 | 
					                        <div class="register-google">
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -129,12 +129,13 @@ autofocus('#id_username');
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
                    <button type="submit" name="button" class="full-width">{{ _("Sign in") }}</button>
 | 
					                    <button type="submit" name="button" class="full-width">{{ _("Sign in") }}</button>
 | 
				
			||||||
                </form>
 | 
					                </form>
 | 
				
			||||||
                {% endif %}
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
                {% if any_oauth_backend_enabled %}
 | 
					                {% if any_oauth_backend_enabled %}
 | 
				
			||||||
                <div class="or">or</div>
 | 
					                <div class="or">or</div>
 | 
				
			||||||
                {% endif %}
 | 
					                {% endif %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                {% endif %} <!-- if password_auth_enabled -->
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                {% if google_auth_enabled %}
 | 
					                {% if google_auth_enabled %}
 | 
				
			||||||
                <div class="login-google">
 | 
					                <div class="login-google">
 | 
				
			||||||
                    <a href="{{ url('zerver.views.auth.start_google_oauth2') }}">
 | 
					                    <a href="{{ url('zerver.views.auth.start_google_oauth2') }}">
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user