update
This commit is contained in:
parent
f28bd2a642
commit
c0a7eb3d3f
@ -185,14 +185,14 @@ async def pre_order(
|
||||
current_user: UserDB = Depends(get_current_user)
|
||||
):
|
||||
|
||||
# 检查是否有配送员在线
|
||||
deliveryman_online = db.query(UserDB).filter(
|
||||
UserDB.community_id == request.community_id,
|
||||
UserDB.is_delivering == True
|
||||
).first()
|
||||
# # 检查是否有配送员在线
|
||||
# deliveryman_online = db.query(UserDB).filter(
|
||||
# UserDB.community_id == request.community_id,
|
||||
# UserDB.is_delivering == True
|
||||
# ).first()
|
||||
|
||||
if not deliveryman_online:
|
||||
return error_response(code=400, message="没有配送员在线, 无法下单")
|
||||
# if not deliveryman_online:
|
||||
# return error_response(code=400, message="没有配送员在线, 无法下单")
|
||||
|
||||
|
||||
# 检查是否有未支付的订单
|
||||
|
||||
BIN
jobs.sqlite
BIN
jobs.sqlite
Binary file not shown.
Loading…
Reference in New Issue
Block a user