07.01.26
This commit is contained in:
@@ -1011,11 +1011,11 @@ class PnlBI(ModelSingleton,ModelSQL, ModelView):
|
||||
config = Configuration.search(['id','>',0])[0]
|
||||
|
||||
payload = {
|
||||
"resource": {"dashboard": 2},
|
||||
"resource": {"dashboard": config.pnl_id},
|
||||
"params": {},
|
||||
"exp": datetime.datetime.utcnow() + datetime.timedelta(minutes=30),
|
||||
}
|
||||
token = jwt.encode(payload, "5d95b70853af02897d1240e2ee4834e2bf065a5132b5d09840fbef6cf683ae45", algorithm="HS256")
|
||||
token = jwt.encode(payload, config.payload, algorithm="HS256")
|
||||
logger.info("TOKEN:%s",token)
|
||||
if config.dark:
|
||||
url = f"metabase:{config.bi}/embed/dashboard/{token}#theme=night&bordered=true&titled=true"
|
||||
|
||||
Reference in New Issue
Block a user