bug fixes. added auto table

This commit is contained in:
2024-12-28 15:53:59 -05:00
parent 4a2ec2418c
commit 8ad7329f78
4 changed files with 27 additions and 14 deletions

View File

@@ -68,3 +68,14 @@ def get_delivery(delivery_id_order):
return JSONResponse(content=jsonable_encoder(get_delivery), status_code=200)
@router.get("/all/profile/{customer_id}", status_code=200)
def get_autos_customers(customer_id):
get_delivery = (
session.query(Tickets_Auto_Delivery)
.filter(Tickets_Auto_Delivery.customer_id == customer_id)
.order_by(Tickets_Auto_Delivery.id.asc())
.all()
)
return JSONResponse(content=jsonable_encoder(get_delivery), status_code=200)