bx-2052-deal-tab #2

Merged
ksenia_mikhailova merged 25 commits from bx-2052-deal-tab into main 2024-11-19 13:59:00 +03:00
2 changed files with 7 additions and 2 deletions
Showing only changes of commit 558033c30b - Show all commits

View File

@ -149,8 +149,10 @@ async def deal_tab(
task_data_json = task_data.json()
# logger.info(task_data_json["result"]["tasks"])
parts = WEBHOOK.split("/")
domain = f"https://{parts[2]}"
return templates.TemplateResponse(
request=request, name="deal_tab.html", context={"tasks": task_data_json["result"]["tasks"]}
request=request, name="deal_tab.html", context={"tasks": task_data_json["result"]["tasks"], "domain":domain}
)
return {"status": "success", "result": task_data_json}

View File

@ -1,8 +1,10 @@
<!DOCTYPE html>
<html>
<head>
<title>Список элементов</title>
</head>
<body>
<table>
<tr>
@ -17,7 +19,7 @@
<tr>
<td>{{ item.id }}</td>
<td>
<a href="/workgroups/group/{{item.groupId}}/tasks/task/view/{{item.id}}/">
<a href="{{domain}}/workgroups/group/{{item.groupId}}/tasks/task/view/{{item.id}}/">
{{ item.title }}
</a>
</td>
@ -29,4 +31,5 @@
{% endfor %}
</table>
</body>
</html>