chang bigint add global and loacl top
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
aed4df32f9
commit
0d945cfb36
26
bot.py
26
bot.py
@ -78,7 +78,7 @@ async def ident(message: types.Message):
|
||||
|
||||
|
||||
if abs(diff) <= 0:
|
||||
await bot.send_message(message.chat.id, f'@{message.from_user.url},🚫 вы уже крутили пипису, ее размер <b>{b.dick_size}</b> см! ')
|
||||
await bot.send_message(message.chat.id, f'@{message.from_user.username},🚫 вы уже крутили пипису, ее размер <b>{b.dick_size}</b> см! ')
|
||||
session.close_all()
|
||||
print(diff)
|
||||
print(type(diff))
|
||||
@ -137,6 +137,30 @@ async def send_time(message: types.Message):
|
||||
💩 {delimiter.join(map(str, top[9]))}\n')
|
||||
session.close_all()
|
||||
|
||||
|
||||
@dp.message_handler(commands=["globaldick"])
|
||||
async def send_time(message: types.Message):
|
||||
engine = create_engine('postgresql+psycopg2://postgres:postgres@postgres.vdk2ch.ru:5432/jack_bot', echo=True)
|
||||
Session = sessionmaker(bind=engine)
|
||||
session = Session()
|
||||
Base = declarative_base()
|
||||
|
||||
top = session.query(user.user_fullname, user.dick_size).order_by(user.dick_size.desc()).limit(10).all()
|
||||
delimiter = ': '
|
||||
|
||||
await bot.send_message(message.chat.id, f'🏆<u>Топ 10 бубылд</u>🏆\n\n\
|
||||
🚀 {delimiter.join(map(str, top[0]))}\n\
|
||||
💫 {delimiter.join(map(str, top[1]))}\n\
|
||||
🍆 {delimiter.join(map(str, top[2]))}\n\
|
||||
🍌 {delimiter.join(map(str, top[3]))}\n\
|
||||
🐍 {delimiter.join(map(str, top[4]))}\n\
|
||||
🐎 {delimiter.join(map(str, top[5]))}\n\
|
||||
🌭 {delimiter.join(map(str, top[6]))}\n\
|
||||
🌶 {delimiter.join(map(str, top[7]))}\n\
|
||||
👌 {delimiter.join(map(str, top[8]))}\n\
|
||||
💩 {delimiter.join(map(str, top[9]))}\n')
|
||||
session.close_all()
|
||||
|
||||
@dp.message_handler(commands=['start'])
|
||||
async def start_func(message: types.Message):
|
||||
# user_id = message.from_user.id
|
||||
|
Loading…
Reference in New Issue
Block a user