Commit Graph

39 Commits

Author SHA1 Message Date
Zakhar Izmaylov 0890d326a4 Refactor trial management function names for clarity. Renamed set_trial to update_trial in database.py and updated all related handler calls in start.py, admin_user_editor.py, and trial_key.py to reflect this change. This improves code readability and consistency across the codebase. 2025-01-23 12:03:01 +03:00
Zakhar Izmaylov 73a365eeb6 Refactor server management and database interactions. Renamed get_servers_from_db to get_servers for clarity and updated related handlers to utilize session management. Refactored add_server_to_db to create_server for consistency. Improved code readability and maintainability across coupon and notification handlers by streamlining database calls and enhancing error handling. 2025-01-23 11:36:15 +03:00
Zakhar Izmaylov e42a66dde7 Refactor database interaction functions in database.py and update related handlers. Renamed functions for clarity: save_temporary_data to create_temporary_data, add_blocked_user to create_blocked_user, remove_blocked_user to delete_blocked_user, and delete_coupon_from_db to delete_coupon. Updated trial management function from restore_trial to set_trial to better reflect its purpose. Adjusted corresponding calls in notifications, start, user, and admin handlers for consistency and improved readability. 2025-01-23 10:38:32 +03:00
Zakhar Izmaylov 31dd3d6654 Refactor client management in key_utils.py and trial_key.py to utilize ClientConfig dataclass for improved parameter handling. This change enhances code clarity and maintainability by consolidating client configuration parameters into a single structured object, streamlining the add_client function calls across multiple handlers. 2025-01-23 10:24:16 +03:00
Zakhar Izmaylov 2d638b0c82 Refactor key management functions to improve database interactions by consolidating key deletion logic into a single function. Introduce timezone-aware expiry date calculations for keys and enhance key retrieval processes across various handlers. Update the start command to utilize a dedicated function for adding connections, ensuring cleaner code and better session management. 2025-01-23 07:49:21 +03:00
Zakhar Izmaylov acb73101c0 Refactor and clean up code formatting across multiple files
- Consolidated and simplified code formatting by removing unnecessary line breaks and improving readability in various functions.
- Updated the handling of backup file sending in backup.py for better clarity.
- Streamlined error handling and logging messages in several handlers to enhance consistency.
- Adjusted the Makefile to exclude specific files during Ruff checks and formatting.
- Made minor adjustments to function signatures and parameter handling for improved clarity and consistency.

This commit enhances code maintainability and readability without altering functionality.
2025-01-21 08:57:12 +03:00
Vladless 4135dd514a fix trial_key for SuperNode 2025-01-15 20:16:52 +03:00
Vladless 722a0f4913 SuperNode/SyncTimeout/pytz 2025-01-14 12:16:14 +03:00
Vladless 0391bd90e9 FlowPayRenew/fixNotify/pay_history/custom/statistic/minorFixes 2025-01-14 04:06:55 +03:00
Zakhar Izmaylov a018a42f2c Add antiflood and lint 2025-01-10 14:51:13 +03:00
Vladless 365e1f6d61 fiatCryptobot/flowPayments/Buttons/fixNotify/BanOfUsers/fixTrial and more 2025-01-09 02:40:39 +03:00
hteppl db8f263128 fix: typo in error message 2025-01-04 20:34:49 +03:00
hteppl 80779e161e fix: check trial key already used 2025-01-04 15:30:34 +03:00
Vladless 97091f4875 fix_refferal/GIFTS/redirect/name_sub and more 2024-12-19 20:37:41 +03:00
Zakhar Izmaylov 142c1c15e7 Migrate to ruff 2024-12-13 12:09:20 +03:00
Vladless f0b2c40a8a Revert "Merge pull request #112 from Vladless/hteppl-optimize-sources"
This reverts commit fa681fac92, reversing
changes made to b31c9d2e10.
2024-12-10 03:53:07 +03:00
hteppl dd79c6a709 Move keys utils into utils folder 2024-12-08 05:11:31 +03:00
hteppl 9233fab758 Move utils.py to the utils folder 2024-12-08 05:02:41 +03:00
hteppl 7a11c51e1f Move util-related files into separated folder + refactor imports 2024-12-08 04:57:20 +03:00
Vladless d8e499bcfb pc button for trial_key 2024-12-02 03:37:28 +03:00
Vladless 319ea2b63b servers in database 2024-12-01 23:24:53 +03:00
Zakhar Izmaylov f97faccf95 Enhanced notifications and admin: CSV export for users/payments, better feedback/navigation, DEV_MODE checks for notifications, .csv in .gitignore, fixed trial expiry with TRIAL_TIME. 2024-11-26 02:52:15 +03:00
Vladless 783ac6f705 ID_Inbound 2024-11-24 22:29:32 +03:00
Vladless b0b690b78f ID_Inbound 2024-11-24 22:29:05 +03:00
Zakhar Izmaylov 95192032de Fix typing 2024-11-24 01:19:00 +03:00
Zakhar Izmaylov d1b7a01b4f Update config 2024-11-22 21:24:55 +03:00
Vladless a568edad63 security update 1.0 2024-11-19 11:21:34 +03:00
Vladless e23676b74d servers in clusters/total_gb 2024-11-14 03:03:32 +03:00
Vladless bd051f81a6 custom trial time 2024-11-13 18:51:25 +03:00
Vladless ca056b0add minPython 3.10/py3xui/subs/rm_artefacts 2024-11-11 17:47:26 +03:00
Zakhar Izmaylov e524e439b1 Add make and config for formatting 2024-11-10 11:02:15 +03:00
Vladless 0697873742 bug and fix 2024-11-10 02:25:36 +03:00
Zakhar Izmaylov 7b9e5914c0 isort and black 2024-11-09 11:44:15 +03:00
Zakhar Izmaylov 76dd0fd1f6 Migrate logging for loguru 2024-11-09 11:41:48 +03:00
Zakhar Izmaylov ff2c66784d Fix logging 2024-11-09 11:33:17 +03:00
Zakhar Izmaylov c68a5794af Refactoring and fix 2024-11-09 10:36:16 +03:00
Vladless 53a56e00cb v3. Полноценные подписки 2024-11-07 07:53:29 +03:00
Vladless 0341acf1c4 ReadMe 2024-10-30 04:50:53 +03:00
Vladless 1c19bf6205 Полная реструктуризация. Тексты все в texts.py 2024-10-27 03:16:58 +03:00