day-cohort-70 / Bangazon-API-BandyChamps

0 stars 0 forks source link

Added functionality for payment to be added to order #58

Closed nicholas-davison closed 1 month ago

nicholas-davison commented 1 month ago

Order class update method was attempting to save order payment type as a string. Corrected to add payment type as an instance of Payment.

Changes

Requests / Responses

Request

PUT /orders/2 Adds a payment method to the order id in the url, thus completing the order.

{
    "payment_type": "3"
}

Response

HTTP/1.1 204 No Content

{}

Testing

Related Issues