Skip to content
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

Feature: Withdraw charges #1943

Merged
merged 44 commits into from
Jan 3, 2024

Conversation

Aunshon
Copy link
Collaborator

@Aunshon Aunshon commented Jul 25, 2023

All Submissions:

  • My code follow the WordPress' coding standards
  • My code satisfies feature requirements
  • My code is tested
  • My code passes the PHPCS tests
  • My code has proper inline documentation
  • I've included developer documentation (optional)
  • I've added proper labels to this pull request

Changes proposed in this Pull Request:

New feature withdraw charge.

Video Links: Introduction, Feature video

How to test the changes in this Pull Request:

  1. First do not set charge and try to make a withdraw request. the experience will be as before.
  2. Set withdraw charges and try to make request.
  3. Check all the amount are alright as expected when applied charge.

Changelog entry

Admin can set a withdrawal charge (flat rate and percentage) for vendors so that admin can charge vendors for withdrawals based on the payment gateway and it will also reflect in the details report. Vendor can see how many charge will apply when request withdraw and show the charge and receivable amount in vendor dashboard list.

PR Self Review Checklist:

  • Code is not following code style guidelines
  • Bad naming: make sure you would understand your code if you read it a few months from now.
  • KISS: Keep it simple, Sweetie (not stupid!).
  • DRY: Don't Repeat Yourself.
  • Code that is not readable: too many nested 'if's are a bad sign.
  • Performance issues
  • Complicated constructions that need refactoring or comments: code should almost always be self-explanatory.
  • Grammar errors.

FOR PR REVIEWER ONLY:

As a reviewer, your feedback should be focused on the idea, not the person. Seek to understand, be respectful, and focus on constructive dialog.

As a contributor, your responsibility is to learn from suggestions and iterate your pull request should it be needed based on feedback. Seek to collaborate and produce the best possible contribution to the greater whole.

  • Correct — Does the change do what it’s supposed to? ie: code 100% fulfilling the requirements?
  • Secure — Would a nefarious party find some way to exploit this change? ie: everything is sanitized/escaped appropriately for any SQL or XSS injection possibilities?
  • Readable — Will your future self be able to understand this change months down the road?
  • Elegant — Does the change fit aesthetically within the overall style and architecture?

@Aunshon Aunshon added the In Progress The issues is being worked on label Jul 25, 2023
@Aunshon Aunshon self-assigned this Jul 25, 2023
@Aunshon
Copy link
Collaborator Author

Aunshon commented Jul 25, 2023

image

    • Move withdraw charge from pro to lite.
    • Combine the withdraw method section and withdraw charge section setting and make them one component
    • Move upgrader from pro to lite
    • Remove get charge api and do the task calculation to lite existing ajax

@Aunshon Aunshon added Needs: Testing This requires further testing and removed In Progress The issues is being worked on labels Aug 3, 2023
@nurul-umbhiya nurul-umbhiya changed the title Withdraw charges Feature: Withdraw charges Aug 18, 2023
includes/REST/WithdrawController.php Outdated Show resolved Hide resolved
includes/Withdraw/Hooks.php Outdated Show resolved Hide resolved
includes/Withdraw/Hooks.php Outdated Show resolved Hide resolved
includes/Withdraw/Manager.php Outdated Show resolved Hide resolved
includes/Withdraw/Manager.php Outdated Show resolved Hide resolved
includes/Withdraw/Withdraw.php Outdated Show resolved Hide resolved
includes/Withdraw/Withdraw.php Outdated Show resolved Hide resolved
templates/withdraw/approved-request-listing.php Outdated Show resolved Hide resolved
templates/withdraw/cancelled-request-listing.php Outdated Show resolved Hide resolved
tests/Withdrawal/WithdrawChargeAjaxTest.php Outdated Show resolved Hide resolved
@nurul-umbhiya nurul-umbhiya added 👍 Dev Review Done and removed Needs: Dev Review It requires a developer review and approval labels Sep 27, 2023
@shashwatahalder01 shashwatahalder01 added QA In Progress and removed Needs: Testing This requires further testing labels Nov 2, 2023
@shashwatahalder01 shashwatahalder01 added QA approved This PR is approved by the QA team and removed QA In Progress labels Dec 7, 2023
@nurul-umbhiya nurul-umbhiya merged commit 52f1b37 into getdokan:develop Jan 3, 2024
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants