alma / alma-monthlypayments-magento2

Magento 2 Payment Gateway integration for Alma
Other
6 stars 9 forks source link

Fix issue when creating quote via api #189

Open mrodespin opened 2 months ago

mrodespin commented 2 months ago

Reason for change

When we are trying to create a quote using the Magento API we have the following error

{ "message": "No such entity with %fieldName = %fieldValue", "parameters": { "fieldName": "customerId", "fieldValue": 3 },

Code changes

Included a validation to not load quote by customer integration ids.

How to test

Create a new quote using following API Methods:

  1. rest/all/V1/carts/
  2. rest/all/V1/carts/{cart_id}/items
  3. rest/all/V1/carts/{cart_id}/estimate-shipping-methods
  4. rest/all/V1/carts/{cart_id}/shipping-information (This one fails)

Checklist for authors and reviewers

sonarcloud[bot] commented 2 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud