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

Not able to create partial invoice from Magento2 REST API for Pay on account [Company Credit] payment method orders #32428

Closed
i95devdivya opened this issue Mar 10, 2021 · 4 comments

Comments

@i95devdivya
Copy link

i95devdivya commented Mar 10, 2021

Preconditions
Magento EE 2.3.5 B2B
PHP 7.2.x

Steps to reproduce
Create order in Magento either with company user or company admin with Pay on account(Company Credit) payment method with multiple items with different quantities or single item with more than one quantity
Try to create an invoice for the order for the partial quantity from Magento REST API using service POST /V1/order/{orderId}/invoice

Expected result
Getting an error like “Invoice Document Validation Error(s): An invoice for partial quantities cannot be issued for this order. To continue, change the specified quantity to the full quantity.”

Actual result
The invoice should be created with the partial quantity

Note
We are able to create partial from Magento2 admin order view page

@m2-assistant
Copy link

m2-assistant bot commented Mar 10, 2021

Hi @i95devdivya. Thank you for your report.
To help us process this issue please make sure that you provided the following information:

  • Summary of the issue
  • Information on your environment
  • Steps to reproduce
  • Expected and actual results

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento give me 2.4-develop instance - upcoming 2.4.x release

For more details, please, review the Magento Contributor Assistant documentation.

Please, add a comment to assign the issue: @magento I am working on this


⚠️ According to the Magento Contribution requirements, all issues must go through the Community Contributions Triage process. Community Contributions Triage is a public meeting.

🕙 You can find the schedule on the Magento Community Calendar page.

📞 The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, please join the Community Contributions Triage session to discuss the appropriate ticket.

🎥 You can find the recording of the previous Community Contributions Triage on the Magento Youtube Channel

✏️ Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel

@i95devdivya
Copy link
Author

We observed the following plug-in from B2B Company Credit module causing the issue

"Magento\CompanyCredit\Plugin\Sales\Model\Order\InvoiceQuantityValidatorPlugin"

If we comment above plug-in from di.xml then we are able to create a partial invoices from REST API.

@i95devdivya
Copy link
Author

#22300

@stale
Copy link

stale bot commented May 27, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed after 14 days if no further activity occurs. Is this issue still relevant? If so, what is blocking it? Is there anything you can do to help move it forward? Thank you for your contributions!

@stale stale bot added the stale issue label May 27, 2021
@stale stale bot closed this as completed Jun 10, 2021
@m2-community-project m2-community-project bot removed this from Ready for Confirmation in Issue Confirmation and Triage Board Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant