Skip to content

feat(settings): Azure and GCP create-override modal (closes #109)#588

Open
cristim wants to merge 1 commit into
feat/multicloud-web-frontendfrom
feat/issue-109-azure-gcp-override-modal
Open

feat(settings): Azure and GCP create-override modal (closes #109)#588
cristim wants to merge 1 commit into
feat/multicloud-web-frontendfrom
feat/issue-109-azure-gcp-override-modal

Conversation

@cristim
Copy link
Copy Markdown
Member

@cristim cristim commented May 20, 2026

Summary

  • Drop the canCreate = provider === 'aws' gate in loadOverridesPanel; Azure and GCP accounts now get the "Add override" button and auto-open the create modal on empty state
  • Add AZURE_OVERRIDE_SERVICES and GCP_OVERRIDE_SERVICES lists; getOverrideServicesForProvider dispatches to the right list so the service dropdown is provider-aware
  • Remove o.provider === 'aws' inline-editing guards for Term, Payment, Coverage, and Enabled cells on existing override rows
  • Payment dropdown uses getCommitmentConfig(provider).payments as fallback; Azure shows upfront/monthly, GCP shows monthly-only
  • Remove now-unused AWS_PAYMENT_OPTIONS constant (superseded by getCommitmentConfig)

Test plan

  • npx tsc --noEmit passes
  • npx jest passes (1897/1897)
  • Three tests updated that previously asserted the read-only Azure/GCP behavior; new assertions verify Azure payment options, inline editing, and empty-state modal auto-open with correct service list
  • Manual: open Settings, add Azure account, open its overrides, verify "Add override" button appears, service dropdown shows Azure services (VM, SQL, Cosmos DB, Redis, Search), payment shows Upfront/Monthly
  • Manual: open GCP account overrides, verify service dropdown shows GCP services, payment shows Monthly only

Extend the per-account override create/edit flow to Azure and GCP accounts
(previously AWS-only, tracked as follow-up to issue #104).

- Drop `canCreate = provider === 'aws'` gate: all providers now render the
  "Add override" button and auto-open the create modal on empty state
- Add AZURE_OVERRIDE_SERVICES and GCP_OVERRIDE_SERVICES lists; dispatch via
  getOverrideServicesForProvider so the service dropdown is provider-aware
- Remove `o.provider === 'aws'` guards on term/payment/coverage table cells:
  all three get inline editing selects/inputs for every provider
- Remove the disabled+tooltip guard on the enabled checkbox for non-AWS rows
- buildPaymentOverrideSelect and syncOverridePaymentOptions now derive the
  fallback payment list from getCommitmentConfig(provider) instead of a
  hardcoded AWS-only constant, so Azure shows upfront/monthly and GCP shows
  monthly-only
- Remove now-unused AWS_PAYMENT_OPTIONS constant (superseded by
  getCommitmentConfig which already owns the same data)
- Tests: update three tests that asserted the old read-only behavior; add
  coverage for Azure payment options, Azure inline editing, and Azure
  empty-state modal auto-open with provider-correct service list
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 20, 2026

Warning

Rate limit exceeded

@cristim has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 7 minutes and 2 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9c5004d8-fcb4-4e2a-9e5f-68fac275e169

📥 Commits

Reviewing files that changed from the base of the PR and between bc8831b and eb5641b.

📒 Files selected for processing (2)
  • frontend/src/__tests__/settings-accounts.test.ts
  • frontend/src/settings.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/issue-109-azure-gcp-override-modal

Comment @coderabbitai help to get the list of available commands and usage tips.

@cristim cristim added priority/p2 Backlog-worthy severity/medium Moderate harm urgency/this-sprint Within the current sprint impact/many Affects most users effort/m Days type/feat New capability triaged Item has been triaged labels May 20, 2026
@cristim
Copy link
Copy Markdown
Member Author

cristim commented May 20, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 20, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@cristim
Copy link
Copy Markdown
Member Author

cristim commented May 22, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 22, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@cristim
Copy link
Copy Markdown
Member Author

cristim commented May 22, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 22, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effort/m Days impact/many Affects most users priority/p2 Backlog-worthy severity/medium Moderate harm triaged Item has been triaged type/feat New capability urgency/this-sprint Within the current sprint

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant