fixes fixes fixes tenaancy
This commit is contained in:
@@ -108,6 +108,11 @@ class InvoiceAdmin(AccountAdminMixin, admin.ModelAdmin):
|
||||
|
||||
@admin.register(Payment)
|
||||
class PaymentAdmin(AccountAdminMixin, admin.ModelAdmin):
|
||||
\"\"\"
|
||||
Payment admin - DO NOT USE.
|
||||
Use the Payment admin in modules/billing/admin.py which has approval workflow actions.
|
||||
This is kept for backward compatibility only.
|
||||
\"\"\"
|
||||
list_display = [
|
||||
'id',
|
||||
'invoice',
|
||||
@@ -121,6 +126,9 @@ class PaymentAdmin(AccountAdminMixin, admin.ModelAdmin):
|
||||
list_filter = ['status', 'payment_method', 'currency', 'created_at']
|
||||
search_fields = ['invoice__invoice_number', 'account__name', 'stripe_payment_intent_id', 'paypal_order_id']
|
||||
readonly_fields = ['created_at', 'updated_at']
|
||||
|
||||
def has_add_permission(self, request):\n return False # Prevent creating payments here
|
||||
\n def has_delete_permission(self, request, obj=None):\n return False # Prevent deleting payments here
|
||||
|
||||
|
||||
@admin.register(CreditPackage)
|
||||
|
||||
Reference in New Issue
Block a user