-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
26 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Copyright (c) 2019 Alexander Todorov <atodorov@MrSenko.com> | ||
|
||
# Licensed under the GPL 3.0: https://www.gnu.org/licenses/gpl-3.0.txt | ||
|
||
from django import template | ||
from django.db import connection | ||
|
||
from tcms_tenants import utils | ||
|
||
register = template.Library() | ||
|
||
|
||
@register.simple_tag | ||
def tenant_url(request, schema_name = None): | ||
if not schema_name: | ||
schema_name = connection.schema_name | ||
|
||
return utils.tenant_url(request, schema_name) |