Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

corporate: Update self-hosted complimentary access plan name.

Lauryn Menard8d638363da19
diff --git a/corporate/models.py b/corporate/models.py
index 00e7567d251..69eb4b4ad50 100644
--- a/corporate/models.py
+++ b/corporate/models.py
@@ -451,10 +451,12 @@ class CustomerPlan(AbstractCustomerPlan):
CustomerPlan.TIER_CLOUD_STANDARD: "Zulip Cloud Standard",
CustomerPlan.TIER_CLOUD_PLUS: "Zulip Cloud Plus",
CustomerPlan.TIER_CLOUD_ENTERPRISE: "Zulip Enterprise",
- CustomerPlan.TIER_SELF_HOSTED_LEGACY: "Free (legacy plan)",
CustomerPlan.TIER_SELF_HOSTED_BASIC: "Zulip Basic",
CustomerPlan.TIER_SELF_HOSTED_BUSINESS: "Zulip Business",
CustomerPlan.TIER_SELF_HOSTED_COMMUNITY: "Community",
+ # Complimentary access plans should never be billed through Stripe,
+ # so the tier name can exceed the 22 character limit noted above.
+ CustomerPlan.TIER_SELF_HOSTED_LEGACY: "Zulip Basic (complimentary)",
}[tier]
@property
diff --git a/corporate/tests/test_support_views.py b/corporate/tests/test_support_views.py
index b429cc67b31..c9c46a7679b 100644
--- a/corporate/tests/test_support_views.py
+++ b/corporate/tests/test_support_views.py
@@ -286,11 +286,11 @@ class TestRemoteServerSupportEndpoint(ZulipTestCase):
result,
)
- def check_legacy_plan_with_upgrade(result: "TestHttpResponse") -> None:
+ def check_complimentary_access_plan_with_upgrade(result: "TestHttpResponse") -> None:
self.assert_in_success_response(
[
"Current plan information:",
- "<b>Plan name</b>: Free (legacy plan)<br />",
+ "<b>Plan name</b>: Zulip Basic (complimentary)<br />",
"<b>Status</b>: New plan scheduled<br />",
"<b>End date</b>: 01 February 2050<br />",
"⏱️ Next plan information:",
@@ -305,11 +305,11 @@ class TestRemoteServerSupportEndpoint(ZulipTestCase):
result,
)
- def check_legacy_plan_without_upgrade(result: "TestHttpResponse") -> None:
+ def check_complimentary_access_plan_without_upgrade(result: "TestHttpResponse") -> None:
self.assert_in_success_response(
[
"Current plan information:",
- "<b>Plan name</b>: Free (legacy plan)<br />",
+ "<b>Plan name</b>: Zulip Basic (complimentary)<br />",
"<b>Status</b>: Active<br />",
"<b>End date</b>: 01 February 2050<br />",
],
@@ -414,14 +414,14 @@ class TestRemoteServerSupportEndpoint(ZulipTestCase):
assert_server_details_in_response(result, f"zulip-{server}.example.com")
assert_realm_details_in_response(result, f"realm-name-{server}", f"realm-host-{server}")
check_no_sponsorship_request(result)
- check_legacy_plan_with_upgrade(result)
+ check_complimentary_access_plan_with_upgrade(result)
server = 5
result = self.client_get("/activity/remote/support", {"q": f"zulip-{server}.example.com"})
assert_server_details_in_response(result, f"zulip-{server}.example.com")
assert_realm_details_in_response(result, f"realm-name-{server}", f"realm-host-{server}")
check_no_sponsorship_request(result)
- check_legacy_plan_without_upgrade(result)
+ check_complimentary_access_plan_without_upgrade(result)
# search for UUIDs
remote_server = RemoteZulipServer.objects.get(hostname=f"zulip-{server}.example.com")
diff --git a/templates/corporate/billing/billing.html b/templates/corporate/billing/billing.html
index 9ff4da4310c..ea384ae6d96 100644
--- a/templates/corporate/billing/billing.html
+++ b/templates/corporate/billing/billing.html
@@ -50,7 +50,7 @@
</a>
{% elif complimentary_access_plan %}
<a href="{{ billing_base_url }}/plans/">
- Zulip Basic
+ {{ plan_name.replace(" (complimentary)", "") -}}
</a>
<i>(complimentary access)</i>
{% else %}