fix: remove duplicate 'Create subscription' block in multi-subscription admin view

This commit is contained in:
c0mrade
2026-03-24 17:53:28 +03:00
parent 3a3cd0b445
commit 20f0e44d2d

View File

@@ -1757,9 +1757,8 @@ export default function AdminUserDetail() {
</> </>
) : null} ) : null}
{/* Create new subscription (shown when no subs, or single-tariff mode) */} {/* Create new subscription — only for single-sub users or no subs */}
{hasPermission('users:subscription') && {hasPermission('users:subscription') && userSubscriptions.length <= 1 && (
!(subscriptionDetailView && userSubscriptions.length > 1) && (
<div className="rounded-xl bg-dark-800/50 p-4"> <div className="rounded-xl bg-dark-800/50 p-4">
{userSubscriptions.length === 0 && ( {userSubscriptions.length === 0 && (
<div className="mb-4 text-center text-dark-400"> <div className="mb-4 text-center text-dark-400">