DmitrMakeev commited on
Commit
35d6525
·
verified ·
1 Parent(s): 5303efd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -1
app.py CHANGED
@@ -2255,9 +2255,25 @@ def serve_html_vk(filename):
2255
  try:
2256
  # Получаем параметры из GET-запроса
2257
  apps_id = request.args.get('apps_id')
2258
- fullUrl = request.args.get('fullUrl')
2259
  vk_app_id = request.args.get('vk_app_id')
2260
  vk_are_notifications_enabled = request.args.get('vk_are_notifications_enabled')
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2261
 
2262
  logging.debug(f"Received params: apps_id={apps_id}")
2263
  logging.debug(f"Received params: fullUrl={fullUrl}")
 
2255
  try:
2256
  # Получаем параметры из GET-запроса
2257
  apps_id = request.args.get('apps_id')
2258
+ base_url = request.args.get('fullUrl')
2259
  vk_app_id = request.args.get('vk_app_id')
2260
  vk_are_notifications_enabled = request.args.get('vk_are_notifications_enabled')
2261
+ vk_is_app_user = request.args.get('vk_is_app_user')
2262
+
2263
+
2264
+ # Параметры запроса
2265
+ params = {
2266
+ 'vk_app_id': vk_app_id,
2267
+ 'vk_are_notifications_enabled': vk_are_notifications_enabled,
2268
+ 'vk_is_app_user': vk_is_app_user'
2269
+ }
2270
+
2271
+ # Формирование URL с использованием f-строк
2272
+ fullUrl = f"{base_url}?{'&'.join([f'{key}={value}' for key, value in params.items()])}"
2273
+
2274
+
2275
+
2276
+
2277
 
2278
  logging.debug(f"Received params: apps_id={apps_id}")
2279
  logging.debug(f"Received params: fullUrl={fullUrl}")