simnova / ownercommunity

MIT License
5 stars 1 forks source link

Payment related fixes #196

Closed yashasvi-jain closed 2 months ago

yashasvi-jain commented 2 months ago

Changes made

Summary by Sourcery

This pull request addresses issues related to payment methods. It ensures that the default payment method is selected in the payment modal if available, and displays an Empty component with an action button if no payment methods exist. Additionally, it enforces that the first payment method added is set as the default.

sourcery-ai[bot] commented 2 months ago

Reviewer's Guide by Sourcery

This pull request focuses on improving the payment modal and add payment method modal by ensuring the default payment method is selected and handling cases where no payment methods are available. It also simplifies the violation ticket detail container by removing unnecessary queries and form items.

File-Level Changes

Files Changes
ui-community/src/components/layouts/members/components/payment-modal.tsx
ui-community/src/components/layouts/members/components/add-payment-method-modal.tsx
ui-community/src/components/layouts/members/components/add-payment-method-modal.container.tsx
ui-community/src/components/layouts/members/components/payment-instruments-list.tsx
Enhanced the payment modal and add payment method modal to handle default payment methods and improved error handling and loading states.
ui-community/src/components/layouts/members/components/violation-ticket-detail.container.tsx
ui-community/src/components/layouts/members/components/violation-ticket-detail.tsx
ui-community/src/components/layouts/admin/components/violation-tickets-detail.container.graphql
Simplified the violation ticket detail container by removing unnecessary queries and form items.

Tips - Trigger a new Sourcery review by commenting `@sourcery-ai review` on the pull request. - Continue your discussion with Sourcery by replying directly to review comments. - You can change your review settings at any time by accessing your [dashboard](https://app.sourcery.ai): - Enable or disable the Sourcery-generated pull request summary or reviewer's guide; - Change the review language; - You can always [contact us](mailto:support@sourcery.ai) if you have any questions or feedback.