Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
widgets_FEKK
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kyla Martin
widgets_FEKK
Commits
34d38102
Commit
34d38102
authored
May 16, 2022
by
Franco Velasco
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed urls pointing to user
parent
af702936
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
5 deletions
+3
-5
models.py
WidgetFEKK/Homepage/models.py
+0
-3
user_details.html
WidgetFEKK/Homepage/templates/user_details.html
+1
-1
urls.py
WidgetFEKK/Homepage/urls.py
+0
-1
urls.py
WidgetFEKK/WidgetFEKK/urls.py
+2
-0
No files found.
WidgetFEKK/Homepage/models.py
View file @
34d38102
...
@@ -30,9 +30,6 @@ class WidgetUser(models.Model):
...
@@ -30,9 +30,6 @@ class WidgetUser(models.Model):
return
f
"""{self.last_name}, {self.first_name} {self.middle_name}:
return
f
"""{self.last_name}, {self.first_name} {self.middle_name}:
{self.id_num}, {self.email}, {self.department}"""
{self.id_num}, {self.email}, {self.department}"""
def
get_absolute_url
(
self
):
return
f
"users/{self.id_num}/details"
def
get_name
(
self
)
->
str
:
def
get_name
(
self
)
->
str
:
return
f
"{self.last_name}, {self.first_name} {self.middle_name}"
return
f
"{self.last_name}, {self.first_name} {self.middle_name}"
...
...
WidgetFEKK/Homepage/templates/user_details.html
View file @
34d38102
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
<h3>
{{ counter }}. {{ user.get_name }}
</h3>
<h3>
{{ counter }}. {{ user.get_name }}
</h3>
<div
class=
"user-links"
>
<div
class=
"user-links"
>
<span>
{{ user.id_num }}
</span>
<span>
{{ user.id_num }}
</span>
<a
href=
"
{{ user.get_absolute_url }}
"
>
View Profile
</a>
<a
href=
"
/users/{{ user.id_num }}/details
"
>
View Profile
</a>
</div>
</div>
</div>
</div>
{% endblock %}
{% endblock %}
\ No newline at end of file
WidgetFEKK/Homepage/urls.py
View file @
34d38102
...
@@ -3,7 +3,6 @@ from .views import HomePageView, UserPageView
...
@@ -3,7 +3,6 @@ from .views import HomePageView, UserPageView
urlpatterns
=
[
urlpatterns
=
[
path
(
''
,
HomePageView
.
as_view
(),
name
=
'index'
),
path
(
''
,
HomePageView
.
as_view
(),
name
=
'index'
),
path
(
'users/<int:user_id>/details'
,
UserPageView
.
as_view
(),
name
=
'user-details'
)
]
]
app_name
=
"Homepage"
app_name
=
"Homepage"
\ No newline at end of file
WidgetFEKK/WidgetFEKK/urls.py
View file @
34d38102
...
@@ -18,12 +18,14 @@ from django.urls import path, include
...
@@ -18,12 +18,14 @@ from django.urls import path, include
import
Announcements.views
as
Announcements_views
import
Announcements.views
as
Announcements_views
import
Forum.views
as
Forum_views
import
Forum.views
as
Forum_views
from
Assignments.views
import
AssignmentDetailView
from
Assignments.views
import
AssignmentDetailView
from
Homepage.views
import
UserPageView
urlpatterns
=
[
urlpatterns
=
[
path
(
'admin/'
,
admin
.
site
.
urls
),
path
(
'admin/'
,
admin
.
site
.
urls
),
path
(
'forum/'
,
include
(
'Forum.urls'
,
namespace
=
'Forum'
)),
path
(
'forum/'
,
include
(
'Forum.urls'
,
namespace
=
'Forum'
)),
path
(
'posts/<int:post_id>/details/'
,
Forum_views
.
details
,
name
=
'post_details'
),
path
(
'posts/<int:post_id>/details/'
,
Forum_views
.
details
,
name
=
'post_details'
),
path
(
'homepage/'
,
include
(
'Homepage.urls'
,
namespace
=
"Homepage"
)),
path
(
'homepage/'
,
include
(
'Homepage.urls'
,
namespace
=
"Homepage"
)),
path
(
'users/<int:user_id>/details'
,
UserPageView
.
as_view
(),
name
=
'user-details'
),
path
(
'announcements/'
,
include
(
'Announcements.urls'
,
namespace
=
"Announcements"
)),
path
(
'announcements/'
,
include
(
'Announcements.urls'
,
namespace
=
"Announcements"
)),
path
(
'announcements/<int:announcement_id>/details'
,
Announcements_views
.
details
,
name
=
'announcement_details'
),
path
(
'announcements/<int:announcement_id>/details'
,
Announcements_views
.
details
,
name
=
'announcement_details'
),
path
(
'assignments/'
,
include
(
'Assignments.urls'
,
namespace
=
"Assignments"
)),
path
(
'assignments/'
,
include
(
'Assignments.urls'
,
namespace
=
"Assignments"
)),
...
...
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