mirror of
https://github.com/zulip/zulip.git
synced 2025-11-01 20:44:04 +00:00
billing: Remove PLAN_NAMES and other legacy code.
This commit is contained in:
@@ -19,8 +19,7 @@ from zerver.lib.timestamp import datetime_to_timestamp, timestamp_to_datetime
|
||||
from zerver.lib.utils import generate_random_token
|
||||
from zerver.lib.actions import do_change_plan_type
|
||||
from zerver.models import Realm, UserProfile, RealmAuditLog
|
||||
from corporate.models import Customer, CustomerPlan, Plan, Coupon, \
|
||||
get_active_plan
|
||||
from corporate.models import Customer, CustomerPlan, get_active_plan
|
||||
from zproject.settings import get_secret
|
||||
|
||||
STRIPE_PUBLISHABLE_KEY = get_secret('stripe_publishable_key')
|
||||
|
||||
@@ -29,7 +29,7 @@ from corporate.lib.stripe import catch_stripe_errors, attach_discount_to_realm,
|
||||
DEFAULT_INVOICE_DAYS_UNTIL_DUE, MIN_INVOICED_LICENSES, do_create_customer, \
|
||||
add_months, next_month, next_renewal_date, renewal_amount, \
|
||||
compute_plan_parameters, update_or_create_stripe_customer
|
||||
from corporate.models import Customer, CustomerPlan, Plan, Coupon
|
||||
from corporate.models import Customer, CustomerPlan
|
||||
from corporate.views import payment_method_string
|
||||
import corporate.urls
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ from corporate.lib.stripe import STRIPE_PUBLISHABLE_KEY, \
|
||||
unsign_string, BillingError, process_downgrade, do_replace_payment_source, \
|
||||
MIN_INVOICED_LICENSES, DEFAULT_INVOICE_DAYS_UNTIL_DUE, \
|
||||
next_renewal_date, renewal_amount
|
||||
from corporate.models import Customer, CustomerPlan, Plan, get_active_plan
|
||||
from corporate.models import Customer, CustomerPlan, get_active_plan
|
||||
|
||||
billing_logger = logging.getLogger('corporate.stripe')
|
||||
|
||||
@@ -145,11 +145,6 @@ def initial_upgrade(request: HttpRequest) -> HttpResponse:
|
||||
response = render(request, 'corporate/upgrade.html', context=context)
|
||||
return response
|
||||
|
||||
PLAN_NAMES = {
|
||||
Plan.CLOUD_ANNUAL: "Zulip Standard (billed annually)",
|
||||
Plan.CLOUD_MONTHLY: "Zulip Standard (billed monthly)",
|
||||
}
|
||||
|
||||
@zulip_login_required
|
||||
def billing_home(request: HttpRequest) -> HttpResponse:
|
||||
user = request.user
|
||||
|
||||
Reference in New Issue
Block a user