fix(usage): explain and de-emphasize the pending-packet button lock
An admin whose report delivery is stuck (old schema, network issue, etc.) saw the v5-upgrade and portal buttons greyed out with no indication why, or what to do about it — the backend's single-packet- in-flight guard is correct, but silent. Add an inline note pointing at "Retry / send if due" when a pending packet is the actual cause. Also: "Review expanded usage.v5 scope" didn't read as an upgrade action — renamed to "Upgrade to usage.v5" / "Auf usage.v5 upgraden". "Open usage portal" is now a primary (green) button in both its signed-in and pre-participation forms, matching the visual weight of the other primary actions on this tab instead of blending in as a secondary outline button.
This commit is contained in:
@@ -223,6 +223,16 @@ export default function ProductUsageTab() {
|
||||
</Button>
|
||||
</div>
|
||||
)}
|
||||
{data.pending_action && data.pending_action !== 'consent' && (
|
||||
// The v5-upgrade and portal buttons below are disabled by the same
|
||||
// pending-packet guard the backend enforces (command() refuses a
|
||||
// second packet while one is still unacknowledged) — without this
|
||||
// note the buttons just look broken, and "Retry" above them isn't
|
||||
// obviously the fix.
|
||||
<p role="status" className="text-sm text-neutral-600 dark:text-neutral-400">
|
||||
{t('productUsage.pendingBlocksActions')}
|
||||
</p>
|
||||
)}
|
||||
<div className="flex flex-wrap gap-3">
|
||||
{data.status === 'disabled' ? (
|
||||
<Button disabled={busy} onClick={() => setConsent(true)}>
|
||||
@@ -274,7 +284,6 @@ export default function ProductUsageTab() {
|
||||
{active ? (
|
||||
<>
|
||||
<Button
|
||||
variant="outline"
|
||||
disabled={busy || Boolean(data.pending_action)}
|
||||
onClick={openPortal}
|
||||
>
|
||||
@@ -294,7 +303,7 @@ export default function ProductUsageTab() {
|
||||
</>
|
||||
) : (
|
||||
<a
|
||||
className="btn btn-outline btn-md"
|
||||
className="btn btn-primary btn-md"
|
||||
href={data.collector_url}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
|
||||
@@ -14,10 +14,11 @@
|
||||
"configurationOnly": "Nur Konfiguration, die tatsächliche Nutzung wird nicht erfasst.",
|
||||
"versionDisclosure": "Diese Zustimmung gilt für usage.v5 / usage-consent.v5: 87 Funktionen und dieselben zwei Bestandszahlen. Neue Ja/Nein-Werte unterscheiden echte CMS-, Vorlagen-, Branding-, SEO-, Kategorie- und Ereignistyp-Änderungen sowie die Annahme echter Vorlagen-E-Mails durch den Mailtransport (auch im Hintergrund) von Standards, unverändertem Speichern, Vorschauen und Tests. Inhalte, Empfänger, Vorlagenkennungen, Aktionszeitpunkte und Häufigkeiten werden nicht erfasst. Die Beobachtung beginnt erst nach bestätigter Zustimmung; Nein bedeutet nicht, dass noch Standards verwendet werden. Frühere Versionen behalten bis zum Upgrade Bedeutung und Umfang. Wartende Pakete bleiben unverändert; Markierungen starten nach Bestätigung neu.",
|
||||
"currentSchema": "Aktuelles Berichtsschema: {{schema}}",
|
||||
"reviewUpgrade": "Erweiterten Umfang von usage.v5 ansehen",
|
||||
"reviewUpgrade": "Auf usage.v5 upgraden",
|
||||
"upgrade": "usage.v5 ausdrücklich zustimmen",
|
||||
"upgradeExplanation": "Deine bestehende Teilnahme behält ihren bisherigen Umfang. Sieh dir den erweiterten Katalog und die beiden Bestandszahlen an, bevor du dich entscheidest. Ablehnen beendet die Teilnahme nicht.",
|
||||
"upgradePending": "Die signierte Erweiterung wartet auf die Bestätigung des Collectors. Bis dahin wird nur der bisher bestätigte Umfang erfasst. Versuche es erneut, wenn der Collector erreichbar ist, oder deaktiviere die Teilnahme, um zu stoppen und zu löschen.",
|
||||
"pendingBlocksActions": "Das v5-Upgrade und das Nutzungsportal sind gesperrt, bis der ausstehende Bericht erneut gesendet wurde oder zugestellt ist — nutze oben „Jetzt senden“.",
|
||||
"catalog": {
|
||||
"crm": {
|
||||
"name": "Kundenverwaltung",
|
||||
|
||||
@@ -14,10 +14,11 @@
|
||||
"configurationOnly": "Configuration only — actual use is not collected.",
|
||||
"versionDisclosure": "This consent covers usage.v5 / usage-consent.v5: 87 capabilities and the same two inventory totals. New booleans distinguish real CMS/template/branding/SEO/category/event-type edits and actual template-email transport acceptance, including background sends, from defaults, unchanged saves, previews and tests. No content, recipient, template key, action timestamp or frequency is collected. Observations begin only after accepted consent; false does not mean an installation still uses defaults. Previous versions keep their meanings and scope until upgrade; queued packets stay unchanged and markers restart after confirmation.",
|
||||
"currentSchema": "Current reporting schema: {{schema}}",
|
||||
"reviewUpgrade": "Review expanded usage.v5 scope",
|
||||
"reviewUpgrade": "Upgrade to usage.v5",
|
||||
"upgrade": "Explicitly agree to usage.v5",
|
||||
"upgradeExplanation": "Your existing participation keeps its current scope. Review the expanded catalog and the two inventory totals before deciding whether to upgrade. Declining does not end participation.",
|
||||
"upgradePending": "The signed consent upgrade is pending confirmation. Only the previously accepted scope is collected. Retry when the collector is available, or disable participation to stop and delete.",
|
||||
"pendingBlocksActions": "The v5 upgrade and the usage portal are unavailable until the pending report is retried or delivered — use \"Retry / send if due\" above.",
|
||||
"catalog": {
|
||||
"crm": {
|
||||
"name": "Client management",
|
||||
|
||||
Reference in New Issue
Block a user