Skip to content

fix(frontend): gate recharge actions by payment availability - #7221

Merged
cuisongliu merged 2 commits into
labring:release-v5.1from
mlhiter:lyon
Aug 15, 2026
Merged

fix(frontend): gate recharge actions by payment availability#7221
cuisongliu merged 2 commits into
labring:release-v5.1from
mlhiter:lyon

Conversation

@mlhiter

@mlhiter mlhiter commented Aug 14, 2026

Copy link
Copy Markdown
Member

Summary

  • Gate insufficient-balance recharge actions in App Launchpad and Database on CostCenter payment availability.
  • Add provider-local, fail-closed payment configuration endpoints with trusted runtime URL fallbacks.
  • Remove the duplicate deployment error toast from the Database edit flow.

Sequence Diagram

sequenceDiagram
    participant User
    participant Provider
    participant CostCenter
    participant Desktop
    User->>Provider: Deployment fails with insufficient balance
    Provider->>CostCenter: Read payment configuration
    alt Recharge enabled and payment method available
        CostCenter-->>Provider: paymentEnabled = true
        Provider-->>User: Show Add credit action
        User->>Provider: Select Add credit
        Provider->>Desktop: Open CostCenter recharge
    else Disabled or unavailable
        CostCenter-->>Provider: Disabled or request failure
        Provider-->>User: Show confirmation-only dialog
    end
Loading

Verification

  • App Launchpad and Database lint passed.
  • App Launchpad and Database typechecks passed.
  • App Launchpad and Database production builds passed.
  • Enabled, disabled, and unavailable CostCenter API smoke cases passed; unavailable configuration fails closed.
  • git diff --check passed.
  • Vitest is unavailable in this checkout (vitest command not found).

@mlhiter
mlhiter requested a review from a team as a code owner August 14, 2026 07:23
@mlhiter mlhiter added this to the v5.1 milestone Aug 14, 2026
@cuisongliu
cuisongliu merged commit 9937a88 into labring:release-v5.1 Aug 15, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants