Skip to content

Commit

Permalink
Remove subscription schedule actions
Browse files Browse the repository at this point in the history
  • Loading branch information
jleclanche committed Aug 29, 2023
1 parent c9698c2 commit d2c2615
Showing 1 changed file with 0 additions and 27 deletions.
27 changes: 0 additions & 27 deletions djstripe/admin/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -638,33 +638,6 @@ class SubscriptionScheduleAdmin(StripeModelAdmin):
list_filter = ("status", "subscription", "customer")
list_select_related = ("customer", "customer__subscriber", "subscription")

@admin.display(description="Release Selected Subscription Schedules")
def _release_subscription_schedule(self, request, queryset):
"""Release a SubscriptionSchedule."""
context = self.get_admin_action_context(
queryset, "_release_subscription_schedule", CustomActionForm
)
return render(request, "djstripe/admin/confirm_action.html", context)

@admin.display(description="Cancel Selected Subscription Schedules")
def _cancel_subscription_schedule(self, request, queryset):
"""Cancel a SubscriptionSchedule."""
context = self.get_admin_action_context(
queryset, "_cancel_subscription_schedule", CustomActionForm
)
return render(request, "djstripe/admin/confirm_action.html", context)

def get_actions(self, request):
# get all actions
actions = super().get_actions(request)
actions["_release_subscription_schedule"] = self.get_action(
"_release_subscription_schedule"
)
actions["_cancel_subscription_schedule"] = self.get_action(
"_cancel_subscription_schedule"
)
return actions


@admin.register(models.TaxCode)
class TaxCodeAdmin(StripeModelAdmin):
Expand Down

0 comments on commit d2c2615

Please sign in to comment.