From 35fd66d70fa67e3687dfdd0ff86216f235f25eb3 Mon Sep 17 00:00:00 2001 From: raihahahan Date: Sat, 10 Aug 2024 16:04:42 +0800 Subject: [PATCH] final changes for qr code feature --- Dockerfile | 8 ++++++++ bots/userbot.py | 16 +++++++++++++++- fly.toml | 7 +++++++ 3 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 Dockerfile create mode 100644 fly.toml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..aa76fd5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM python:3.10 +# WORKDIR /bot +# COPY requirements.txt /bot/ +COPY . . +RUN pip install -r requirements.txt +RUN pip install python-dotenv +# COPY . /bot +CMD python main.py \ No newline at end of file diff --git a/bots/userbot.py b/bots/userbot.py index 44b84cc..4b4d076 100644 --- a/bots/userbot.py +++ b/bots/userbot.py @@ -17,6 +17,20 @@ from admin import ( ADMIN_LIST, BOT_ENV, + ADMIN_DEV +) + +from admin import ( + ADMIN_HEAD, + ADMIN_HEAD_NAME, + ADMIN_HEAD_MOBILE, + ADMIN_SAFETY, + ADMIN_SAFETY_MOBILE, + ADMIN_SAFETY_NAME, + ADMIN_TREASURER, + ADMIN_TREASURER_MOBILE, + ADMIN_TREASURER_NAME, + ADMIN_TREASURER_URL, ) from bot_text import ( @@ -152,7 +166,7 @@ def qr_rent_command(self, update, context, bike_name): context.user_data['bike_name'] = bike_name # Show terms - text = "hello" #TERMS_TEXT.format(**globals()) + text = TERMS_TEXT.format(**globals()) update.message.reply_text( text, parse_mode='HTML', ) diff --git a/fly.toml b/fly.toml new file mode 100644 index 0000000..e463141 --- /dev/null +++ b/fly.toml @@ -0,0 +1,7 @@ +# fly.toml app configuration file generated for orc4bikes on 2024-08-10T15:22:27+08:00 +# +# See https://fly.io/docs/reference/configuration/ for information about how to use this file. +# + +app = 'orc4bikes' +primary_region = 'sin'