zulip/analytics/views
Lauryn Menard ee19a9c274 corporate: Move attach_realm_discount to BillingSession class.
This moves the logic for `attach_realm_discount`, which is used in
the support view, to be in the BillingSession class.

Updates the function name to be `attach_discount_to_customer` so
that the context is generalized vs realm specific.

Updates RealmBillingSession implementation to account for actions
that are initiated by a support admin user.

Also moves the helper function `get_discount_for_realm` that is
only used in support views to `corporate/lib/support.py`.
2023-11-04 17:20:49 -07:00
..
__init__.py analytics: Create analytics/views/ directory. 2021-06-17 17:39:28 -07:00
activity_common.py analytics: Use realm_str to generate per realm URL. 2023-11-01 13:08:49 -07:00
installation_activity.py analytics: Use activity_details_template.html for installation page. 2023-11-01 10:31:04 -07:00
realm_activity.py models: Always search Messages with a realm_id or id limit. 2023-09-11 15:00:37 -07:00
remote_activity.py analytics: Move remote server view to separate file. 2023-10-05 12:31:57 -07:00
stats.py stats: Support fetching StreamCount based on stream_id. 2023-10-16 15:10:14 -07:00
support.py corporate: Move attach_realm_discount to BillingSession class. 2023-11-04 17:20:49 -07:00
user_activity.py ruff: Fix PLR1714 Consider merging multiple comparisons. 2023-07-23 15:21:33 -07:00