Switch to English?
Yes
Переключитись на українську?
Так
Переключиться на русскую?
Да
Przełączyć się na polską?
Tak
With a certain command, the Telegram bot gives you a link to your chat ID. With a certain command, the Telegram bot gives you a link to your chat ID. You will have your link, which will have a status (displayed in the console)

And I was given 3 databases of bot telegrams, workers, currency, users. The point was that I had to make 3 statuses for users and workers, status 0 - random values of the graph relative to (-2 ; 2), status 1 - winning, i.e. if a person with status 1 bet on downgrade, the graph will go down, the same goes for promotion, status 2 is a loss, i.e.

if a person with status 2 bets on a decrease, the graph will go up with a small interval, usually status 2 and 0 were used for users. I had to take this status in the database, in relation to the Telegram bot (of course, I informed the customer that he needed a separate server for the database, but at the moment I did it directly from the file), in which the "senior" could select a user and put his status, then the database was changing, so I made it so that the database was updated every time the page was loaded. I also had to make sure that each user had his own page. Change the frontend, and a couple more exercises

How did I do it?
To begin with, I read the code of the bot's telegrams, read what is contained in the databases, read the entire code (about 50,000 lines), it was difficult to understand what was to what, because I was analyzing someone else's code, which was written very awkwardly, not broken down into blocks, not formed After that I realized that it would be best to write it in django, I rewrote all the code in django so that I could work both with python (on which the telegram bot is written) and to work with html. After that, I made my own page for each user using the chat ID from the user database (this database was taken from the Telegram bot, which, when pressing the start button, recorded all the necessary information in the database, and recorded default data for unknown information).
YOU WILL NOT BE ABLE TO USE THE WEB PAGE WITHOUT A CHAT ID THAT IS IN YOUR DATABASE. That is, the path to the page should look something like this: https://YOUR_HOST/658257014.
Status 0: Raindom integer, min 25 000, max 35 000. Сase (-2, 2)
Status 1: Win, min 25 000, max 35 000. If the user chose to increase the schedule, the chances: (-2, 4)
Status 2: Loss, min 25 000, max 35 000. If the user chose to increase the schedule, the chances: (-4, 2)
Деталі роботи
Бюджет 50 UAH
Додано 23 березня 2024
104 перегляди
Фрилансер
Андрій Хоміцький
Україна Україна
Немає відгуків

Вільний для роботи Вільний для роботи
На сервісі 4 роки