Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
Django LDP
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
20
Issues
20
List
Boards
Labels
Milestones
Merge Requests
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Container Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Startin blox
djangoldp-packages
Django LDP
Commits
ff8c754c
Verified
Commit
ff8c754c
authored
Dec 02, 2019
by
Jean-Baptiste Pasquier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
hotfix: absolute_url based on SITE_URL
parent
56bce0a8
Pipeline
#6603
passed with stage
in 1 minute and 21 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
djangoldp/models.py
djangoldp/models.py
+1
-1
No files found.
djangoldp/models.py
View file @
ff8c754c
...
...
@@ -41,7 +41,7 @@ class Model(models.Model):
@
classonlymethod
def
absolute_url
(
cls
,
instance_or_model
):
if
isinstance
(
instance_or_model
,
ModelBase
)
or
instance_or_model
.
urlid
is
None
or
instance_or_model
.
urlid
==
''
:
return
'{}{}'
.
format
(
settings
.
BAS
E_URL
,
Model
.
resource
(
instance_or_model
))
return
'{}{}'
.
format
(
settings
.
SIT
E_URL
,
Model
.
resource
(
instance_or_model
))
else
:
return
instance_or_model
.
urlid
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment