Advertisement
PythoNyashka

Untitled

Feb 7th, 2020
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.34 KB | None | 0 0
  1. top_user_query = User.select().order_by(User.balance.desc()).get()
  2.  
  3. if int(top_user_query.user_id) == int(request.values['vk_user_id']):
  4.     user_lvl = 21 # Зверев у топ 1 юзера
  5.     lvl_top_str = 'ТОП 1 FLEXXX'
  6. else:
  7.     user_lvl = min(20, int(user_query.balance) // 10000 + 1)
  8.     lvl_top_str = f'{user_query.balance}/{(user_lvl) * 10000}'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement