Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
PyPrevention
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sr04
PyPrevention
Commits
726c1a72
Commit
726c1a72
authored
Oct 22, 2018
by
Hippolyte Vergnol (Hive)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add grid loop + test page
parent
d5195dcb
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
34 additions
and
1 deletion
+34
-1
pyprevention/dashboard/__pycache__/urls.cpython-36.pyc
pyprevention/dashboard/__pycache__/urls.cpython-36.pyc
+0
-0
pyprevention/dashboard/__pycache__/views.cpython-36.pyc
pyprevention/dashboard/__pycache__/views.cpython-36.pyc
+0
-0
pyprevention/dashboard/templates/index.html
pyprevention/dashboard/templates/index.html
+1
-1
pyprevention/dashboard/templates/test.html
pyprevention/dashboard/templates/test.html
+28
-0
pyprevention/dashboard/urls.py
pyprevention/dashboard/urls.py
+1
-0
pyprevention/dashboard/views.py
pyprevention/dashboard/views.py
+4
-0
pyprevention/pyprevention/__pycache__/settings.cpython-36.pyc
...evention/pyprevention/__pycache__/settings.cpython-36.pyc
+0
-0
No files found.
pyprevention/dashboard/__pycache__/urls.cpython-36.pyc
View file @
726c1a72
No preview for this file type
pyprevention/dashboard/__pycache__/views.cpython-36.pyc
View file @
726c1a72
No preview for this file type
pyprevention/dashboard/templates/
home
.html
→
pyprevention/dashboard/templates/
index
.html
View file @
726c1a72
...
...
@@ -6,7 +6,7 @@
<div
class=
"container-fluid"
>
<div
class=
"jumbotron jumbotron-fluid"
>
<div
class=
"container"
>
<h1
class=
"display-4"
>
Bonjour Monsieur
Hive
,
</h1>
<h1
class=
"display-4"
>
Bonjour Monsieur
{{user.username}}
,
</h1>
<p
class=
"lead"
>
Bienvenue sur votre espace.
</p>
</div>
</div>
...
...
pyprevention/dashboard/templates/test.html
0 → 100644
View file @
726c1a72
{% extends "base.html" %}
{% block content %}
<div
class=
"row"
>
{% for item in items %}
<div
class=
"col"
>
<a
href=
"https://www.w3schools.com"
>
<div
class=
"card mx-auto"
style=
"width: 18rem; height:10rem;"
>
<img
class=
"card-img-top"
src=
"https://www.cadredesante.com/spip/local/cache-vignettes/L379xH251/hopital-dessin-g-7f972.jpg"
alt=
"Card image cap"
>
<div
class=
"card-body"
>
<h5
class=
"card-title"
>
Mes patients {{item.title}}
</h5>
</div>
</div>
</a>
</div>
{% if forloop.counter|divisibleby:"6" or forloop.last %}
</div>
<!--end row-->
{% endif %}
{% endfor %}
{% endblock %}
pyprevention/dashboard/urls.py
View file @
726c1a72
...
...
@@ -6,6 +6,7 @@ from django.contrib import admin
urlpatterns
=
[
path
(
''
,
views
.
index
,
name
=
'index'
),
path
(
'api'
,
views
.
api
,
name
=
'api'
),
path
(
'test'
,
views
.
test
,
name
=
'test'
),
path
(
'logout'
,
views
.
logout_view
,
name
=
'logout'
),
url
(
r'^accounts/login/$'
,
views
.
login
,
name
=
'login'
),
url
(
r'^home/$'
,
views
.
home
,
name
=
'home'
),
...
...
pyprevention/dashboard/views.py
View file @
726c1a72
...
...
@@ -12,6 +12,10 @@ def logout_view(request):
def
index
(
request
):
return
render
(
request
,
'index.html'
)
def
test
(
request
):
items
=
[{
"title"
:
"ok1"
},
{
"title"
:
"ok2"
}]
return
render
(
request
,
'test.html'
,
{
"items"
:
items
})
@
login_required
def
api
(
request
):
return
HttpResponse
(
"API"
)
...
...
pyprevention/pyprevention/__pycache__/settings.cpython-36.pyc
View file @
726c1a72
No preview for this file type
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