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.

models: Make it easier to debug current plan name and status.

Aman Agrawale02e0cd37e34
diff --git a/corporate/models.py b/corporate/models.py
index ce5626a18de..57e918997d8 100644
--- a/corporate/models.py
+++ b/corporate/models.py
@@ -289,6 +289,10 @@ class CustomerPlan(models.Model):
# TODO maybe override setattr to ensure billing_cycle_anchor, etc
# are immutable.
+ @override
+ def __str__(self) -> str:
+ return f"{self.name} (status: {self.get_plan_status_as_text()})"
+
@staticmethod
def name_from_tier(tier: int) -> str:
# NOTE: Check `statement_descriptor` values after updating this.