Skip to content

Fixed a bug in model/controller. #2477

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Charisn
Copy link

@Charisn Charisn commented Dec 12, 2023

Issue with Zero Price: When a discount is applied to an order, and the final price becomes zero, the Viva payment system responds with an HTTP error 500. This issue occurs because Viva does not handle transactions with a zero amount correctly.

Database Column Name Change: In the database model, the column originally named vivawallet_total was renamed to payment_vivawallet_total. This change was made to ensure consistency and to match the actual column name used in the database.

Controller Modification for Checkout Process: An additional 'if' statement was added to the controller code. This modification was added for scenarios like one-page checkout processes, where the sequence of loading various components might differ from what the Viva extension originally expected. This change helps to avoid issues by ensuring that the payment process is only initiated when appropriate, especially in cases where the order amount might be zero due to discounts or other factors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant