feat: Added notes creation, view and deletion, added route planning, added location list with current weather and nearby locations, code improvements and fixes

This commit is contained in:
ITQ
2024-03-26 07:49:50 +03:00
parent 65719a61ef
commit 88dfe1704d
24 changed files with 1571 additions and 301 deletions
+46
View File
@@ -0,0 +1,46 @@
__all__ = ("get",)
from aiogram import types
from aiogram.utils.keyboard import InlineKeyboardBuilder
def get(travel_id: int, note):
builder = InlineKeyboardBuilder()
builder.row(
types.InlineKeyboardButton(
text="⏩ View note",
callback_data=f"travel_notesend_{note.id}",
),
)
if note.public:
builder.row(
types.InlineKeyboardButton(
text="🔒 Make private",
callback_data=f"travel_note_change_privacy_{note.id}",
),
)
else:
builder.row(
types.InlineKeyboardButton(
text="🔓 Make public",
callback_data=f"travel_note_change_privacy_{note.id}",
),
)
builder.row(
types.InlineKeyboardButton(
text="❌ Delete note",
callback_data=f"travel_notedelete_{note.id}",
),
)
builder.row(
types.InlineKeyboardButton(
text="⬅️",
callback_data=f"travel_detail_{travel_id}",
),
)
return builder.as_markup()