[UP] OrderNotificationsIn {~ order > order_id}
This commit is contained in:
parent
87b754d767
commit
0bc6e7ab04
1 changed files with 4 additions and 4 deletions
|
|
@ -168,9 +168,9 @@ class OrderOut(BaseModel):
|
|||
|
||||
|
||||
class OrderNotificationsIn(BaseModel):
|
||||
order: int
|
||||
notify_side: OrderNotifySide
|
||||
notify_type: OrderNotifyType
|
||||
order_id: int
|
||||
notify_side: OrderNotifySide = Field(default=OrderNotifySide.CLIENT)
|
||||
notify_type: OrderNotifyType = Field(default=OrderNotifyType.DRIVER_ARRIVED)
|
||||
processed: Optional[bool] = False
|
||||
|
||||
class OrderNotificationsOut(BaseModel):
|
||||
|
|
@ -416,7 +416,7 @@ class TaxisClient:
|
|||
return OrderNotificationsOut(**result)
|
||||
|
||||
async def mark_order_notification_processed(self, notification_id: int, processed: bool) -> 'OrderNotificationsOut':
|
||||
result = await self._request("PATCH", f"/order_notifications/{notification_id}/processed", params={"processed": processed})
|
||||
result = await self._request("PATCH", f"/order_notifications/{notification_id}/processed", params={"processed": str(processed).lower()})
|
||||
return OrderNotificationsOut(**result)
|
||||
|
||||
async def delete_order_notification(self, notification_id: int) -> None:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue