Advertisement
Guest User

Untitled

a guest
May 21st, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. req_list = Requests.objects.filter(
  2. client=client_id,
  3. direction=direction_id,
  4. status=lead_status,
  5. ).order_by('-date')
  6.  
  7. if len(req_list) > 0:
  8. return req_list[0], True
  9. else:
  10. return None, False
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement