mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-04 14:03:30 +00:00 
			
		
		
		
	support: Clean up class names in support views.
Updates the class name used for the sponsorship form container in the remote support views to be more specific. Adds a shared "support-form" class for the different forms in the realm_details template. Use the same CSS rule for current and next plan information sections.
This commit is contained in:
		
				
					committed by
					
						
						Tim Abbott
					
				
			
			
				
	
			
			
			
						parent
						
							6ee123be21
						
					
				
				
					commit
					16135fbac6
				
			@@ -33,7 +33,7 @@
 | 
				
			|||||||
</div>
 | 
					</div>
 | 
				
			||||||
<div class="realm-support-forms">
 | 
					<div class="realm-support-forms">
 | 
				
			||||||
    <div class="realm-form-container">
 | 
					    <div class="realm-form-container">
 | 
				
			||||||
        <form method="POST" class="support-realm-status-form">
 | 
					        <form method="POST" class="support-realm-status-form support-form">
 | 
				
			||||||
            <b>Status</b>:<br />
 | 
					            <b>Status</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -43,14 +43,14 @@
 | 
				
			|||||||
            </select>
 | 
					            </select>
 | 
				
			||||||
            <button type="submit" class="support-submit-button">Update</button>
 | 
					            <button type="submit" class="support-submit-button">Update</button>
 | 
				
			||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
        <form method="POST" class="realm-subdomain-form">
 | 
					        <form method="POST" class="realm-subdomain-form support-form">
 | 
				
			||||||
            <b>New subdomain</b>:<br />
 | 
					            <b>New subdomain</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
            <input type="text" name="new_subdomain" required />
 | 
					            <input type="text" name="new_subdomain" required />
 | 
				
			||||||
            <button type="submit" class="support-submit-button">Update</button>
 | 
					            <button type="submit" class="support-submit-button">Update</button>
 | 
				
			||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
        <form method="POST" class="realm-organization-type-form">
 | 
					        <form method="POST" class="realm-organization-type-form support-form">
 | 
				
			||||||
            <b>Org type</b>:<br />
 | 
					            <b>Org type</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -63,7 +63,7 @@
 | 
				
			|||||||
            </select>
 | 
					            </select>
 | 
				
			||||||
            <button type="submit" class="support-submit-button">Update</button>
 | 
					            <button type="submit" class="support-submit-button">Update</button>
 | 
				
			||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
        <form method="POST" class="support-plan-type-form">
 | 
					        <form method="POST" class="support-plan-type-form support-form">
 | 
				
			||||||
            <b>Plan type</b>:<br />
 | 
					            <b>Plan type</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -76,7 +76,7 @@
 | 
				
			|||||||
            </select>
 | 
					            </select>
 | 
				
			||||||
            <button type="submit" class="support-submit-button">Update</button>
 | 
					            <button type="submit" class="support-submit-button">Update</button>
 | 
				
			||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
        <form method="POST" class="sponsorship-pending-form">
 | 
					        <form method="POST" class="sponsorship-pending-form support-form">
 | 
				
			||||||
            <b>Sponsorship pending</b>:<br />
 | 
					            <b>Sponsorship pending</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -88,7 +88,7 @@
 | 
				
			|||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        {% if plan_data[realm.id].customer and plan_data[realm.id].customer.sponsorship_pending %}
 | 
					        {% if plan_data[realm.id].customer and plan_data[realm.id].customer.sponsorship_pending %}
 | 
				
			||||||
        <form method="POST" class="approve-sponsorship-form">
 | 
					        <form method="POST" class="approve-sponsorship-form support-form">
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
            <input type="hidden" name="approve_sponsorship" value="true" />
 | 
					            <input type="hidden" name="approve_sponsorship" value="true" />
 | 
				
			||||||
@@ -99,7 +99,7 @@
 | 
				
			|||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
        {% endif %}
 | 
					        {% endif %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        <form method="POST" class="support-discount-form">
 | 
					        <form method="POST" class="support-discount-form support-form">
 | 
				
			||||||
            <b>Discount (use 85 for nonprofits)</b>:<br />
 | 
					            <b>Discount (use 85 for nonprofits)</b>:<br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -114,16 +114,14 @@
 | 
				
			|||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
    {% if plan_data[realm.id].current_plan %}
 | 
					    {% if plan_data[realm.id].current_plan %}
 | 
				
			||||||
    <div class="current-plan-container">
 | 
					    <div class="current-plan-container">
 | 
				
			||||||
        <div class="current-plan-details">
 | 
					        {% with %}
 | 
				
			||||||
            {% with %}
 | 
					            {% set plan_data = plan_data[realm.id] %}
 | 
				
			||||||
                {% set plan_data = plan_data[realm.id] %}
 | 
					            {% set format_discount = format_discount %}
 | 
				
			||||||
                {% set format_discount = format_discount %}
 | 
					            {% set dollar_amount = dollar_amount %}
 | 
				
			||||||
                {% set dollar_amount = dollar_amount %}
 | 
					            {% include 'corporate/support/current_plan_details.html' %}
 | 
				
			||||||
                {% include 'corporate/support/current_plan_details.html' %}
 | 
					        {% endwith %}
 | 
				
			||||||
            {% endwith %}
 | 
					 | 
				
			||||||
        </div>
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
        <form method="POST" class="billing-modality-form">
 | 
					        <form method="POST" class="billing-modality-form support-form">
 | 
				
			||||||
            <b>Billing collection method</b><br />
 | 
					            <b>Billing collection method</b><br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -134,7 +132,7 @@
 | 
				
			|||||||
            <button type="submit" class="support-submit-button">Update</button>
 | 
					            <button type="submit" class="support-submit-button">Update</button>
 | 
				
			||||||
        </form>
 | 
					        </form>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        <form method="POST" class="downgrade-plan-form">
 | 
					        <form method="POST" class="downgrade-plan-form support-form">
 | 
				
			||||||
            <b>Modify plan</b><br />
 | 
					            <b>Modify plan</b><br />
 | 
				
			||||||
            {{ csrf_input }}
 | 
					            {{ csrf_input }}
 | 
				
			||||||
            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					            <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
@@ -150,7 +148,7 @@
 | 
				
			|||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
    {% endif %}
 | 
					    {% endif %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <form method="POST" class="scrub-realm-form">
 | 
					    <form method="POST" class="scrub-realm-form support-form">
 | 
				
			||||||
        <h3>❌ Scrub realm</h3>
 | 
					        <h3>❌ Scrub realm</h3>
 | 
				
			||||||
        {{ csrf_input }}
 | 
					        {{ csrf_input }}
 | 
				
			||||||
        <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
					        <input type="hidden" name="realm_id" value="{{ realm.id }}" />
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -30,7 +30,7 @@
 | 
				
			|||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    {% if remote_realm.plan_type != SPONSORED_PLAN_TYPE %}
 | 
					    {% if remote_realm.plan_type != SPONSORED_PLAN_TYPE %}
 | 
				
			||||||
    <div class="sponsorship-container">
 | 
					    <div class="remote-support-sponsorship-container">
 | 
				
			||||||
        {% with %}
 | 
					        {% with %}
 | 
				
			||||||
            {% set sponsorship_data = support_data[remote_realm.id].sponsorship_data %}
 | 
					            {% set sponsorship_data = support_data[remote_realm.id].sponsorship_data %}
 | 
				
			||||||
            {% set remote_id = remote_realm.id %}
 | 
					            {% set remote_id = remote_realm.id %}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -69,7 +69,7 @@
 | 
				
			|||||||
                </div>
 | 
					                </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                {% if remote_server.plan_type != SPONSORED_PLAN_TYPE %}
 | 
					                {% if remote_server.plan_type != SPONSORED_PLAN_TYPE %}
 | 
				
			||||||
                <div class="sponsorship-container">
 | 
					                <div class="remote-support-sponsorship-container">
 | 
				
			||||||
                    {% with %}
 | 
					                    {% with %}
 | 
				
			||||||
                        {% set sponsorship_data = remote_servers_support_data[remote_server.id].sponsorship_data %}
 | 
					                        {% set sponsorship_data = remote_servers_support_data[remote_server.id].sponsorship_data %}
 | 
				
			||||||
                        {% set remote_id = remote_server.id %}
 | 
					                        {% set remote_id = remote_server.id %}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -279,18 +279,9 @@ tr.admin td:first-child {
 | 
				
			|||||||
    top: -2px;
 | 
					    top: -2px;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.scrub-realm-form,
 | 
					.support-form,
 | 
				
			||||||
.realm-organization-type-form,
 | 
					 | 
				
			||||||
.realm-subdomain-form,
 | 
					 | 
				
			||||||
.downgrade-plan-form,
 | 
					 | 
				
			||||||
.billing-modality-form,
 | 
					 | 
				
			||||||
.approve-sponsorship-form,
 | 
					 | 
				
			||||||
.current-plan-details,
 | 
					 | 
				
			||||||
.sponsorship-pending-form,
 | 
					 | 
				
			||||||
.support-plan-type-form,
 | 
					 | 
				
			||||||
.support-discount-form,
 | 
					 | 
				
			||||||
.support-realm-status-form,
 | 
					 | 
				
			||||||
.remote-form,
 | 
					.remote-form,
 | 
				
			||||||
 | 
					.next-plan-information,
 | 
				
			||||||
.current-plan-information {
 | 
					.current-plan-information {
 | 
				
			||||||
    margin-bottom: 10px;
 | 
					    margin-bottom: 10px;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -401,7 +392,7 @@ tr.admin td:first-child {
 | 
				
			|||||||
.realm-form-container,
 | 
					.realm-form-container,
 | 
				
			||||||
.next-plan-container,
 | 
					.next-plan-container,
 | 
				
			||||||
.current-plan-container,
 | 
					.current-plan-container,
 | 
				
			||||||
.sponsorship-container {
 | 
					.remote-support-sponsorship-container {
 | 
				
			||||||
    border: 2px solid hsl(33deg 99% 60%);
 | 
					    border: 2px solid hsl(33deg 99% 60%);
 | 
				
			||||||
    border-radius: 4px;
 | 
					    border-radius: 4px;
 | 
				
			||||||
    padding: 10px;
 | 
					    padding: 10px;
 | 
				
			||||||
@@ -409,7 +400,7 @@ tr.admin td:first-child {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.realm-form-container,
 | 
					.realm-form-container,
 | 
				
			||||||
.sponsorship-container {
 | 
					.remote-support-sponsorship-container {
 | 
				
			||||||
    background-color: hsl(30deg 100% 96%);
 | 
					    background-color: hsl(30deg 100% 96%);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user