hore
This commit is contained in:
parent
f9a68b343d
commit
188047e1b6
@ -229,7 +229,7 @@
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"execution_count": 1,
|
||||
"id": "2809c42c",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
@ -254,6 +254,7 @@
|
||||
" app.append(''.join(cell['source']))\n",
|
||||
"\n",
|
||||
" with open(f'{filename_without_extension}.py', 'w') as f:\n",
|
||||
" f.write(f\"# `{filename_without_extension}.py` generate from `{filename_without_extension}.ipynb` by `build.ipynb` \\n\")\n",
|
||||
" f.write('\\n\\n'.join(app))\n",
|
||||
"\n",
|
||||
"build()"
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
# `email_task.py` generate from `email_task.ipynb` by `build.ipynb`
|
||||
#ignore
|
||||
import os
|
||||
|
||||
|
||||
13
main.py
13
main.py
@ -1,3 +1,4 @@
|
||||
# `main.py` generate from `main.ipynb` by `build.ipynb`
|
||||
# FastAPI
|
||||
|
||||
## App
|
||||
@ -1069,17 +1070,6 @@ async def logout(
|
||||
@app.get("/api/me", response_model=dict)
|
||||
async def get_me(response: Response, current_user: Dict = Security(get_current_user, scopes=["read:self"])):
|
||||
user = display_user(current_user)
|
||||
refresh_exp = timedelta(days=REFRESH_TOKEN_EXPIRE_DAYS)
|
||||
if current_user['email'] == 'kultmost@yandex.ru':
|
||||
response.set_cookie(
|
||||
domain='.kultmost.ru',
|
||||
key="token",
|
||||
value='2124|bhcbiP7XEgSe6ooTAoPf6mklBWNExG6a5CmmwTvTfafc5d5b',
|
||||
httponly=True,
|
||||
secure=PROD,
|
||||
samesite="strict",
|
||||
max_age=int(refresh_exp.total_seconds())
|
||||
)
|
||||
return bson_clear(user)
|
||||
|
||||
|
||||
@ -3540,7 +3530,6 @@ async def api_exhibition_post_select(
|
||||
return {"ok": True}
|
||||
|
||||
|
||||
|
||||
@app.get("/profile/partner/exhibition/{exhibition_id}/catalog", response_class=HTMLResponse)
|
||||
async def profile_partner_exhibitions_catalog(
|
||||
request: Request,
|
||||
|
||||
1
tasks.py
1
tasks.py
@ -1,3 +1,4 @@
|
||||
# `tasks.py` generate from `tasks.ipynb` by `build.ipynb`
|
||||
from config import *
|
||||
from db import *
|
||||
from typing import Dict, Any, List, Optional, Callable, Union
|
||||
|
||||
Loading…
Reference in New Issue
Block a user