Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
third-party
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
2
Merge Requests
2
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
cooperatic-foodcoops
third-party
Commits
1a2bcfad
Commit
1a2bcfad
authored
Feb 28, 2022
by
Félicie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
url changed
parent
f01511b3
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
98 additions
and
54 deletions
+98
-54
admin.py
members/admin.py
+10
-14
manage_attached.css
members/static/css/admin/manage_attached.css
+50
-1
bdm_index.js
members/static/js/admin/bdm_index.js
+4
-4
urls.py
members/urls.py
+2
-4
manage_attached.html
templates/members/admin/manage_attached.html
+2
-2
manage_attached_create_pair.html
templates/members/admin/manage_attached_create_pair.html
+30
-29
manage_attached_delete_pair.html
templates/members/admin/manage_attached_delete_pair.html
+0
-0
No files found.
members/admin.py
View file @
1a2bcfad
...
...
@@ -334,20 +334,6 @@ def manage_attached(request):
'module'
:
'Membres'
}
return
HttpResponse
(
template
.
render
(
context
,
request
))
def
manage_attached_create
(
request
):
""" Administration des binômes membres """
template
=
loader
.
get_template
(
'members/admin/manage_attached_create.html'
)
context
=
{
'title'
:
'BDM - Binômes'
,
'module'
:
'Membres'
}
return
HttpResponse
(
template
.
render
(
context
,
request
))
def
manage_attached_delete
(
request
):
""" Administration des binômes membres """
template
=
loader
.
get_template
(
'members/admin/manage_attached_delete.html'
)
context
=
{
'title'
:
'BDM - Binômes'
,
'module'
:
'Membres'
}
return
HttpResponse
(
template
.
render
(
context
,
request
))
def
get_makeups_members
(
request
):
""" Récupération des membres qui doivent faire des rattrapages """
res
=
CagetteMembers
.
get_makeups_members
()
...
...
@@ -477,6 +463,11 @@ def get_member_info(request, member_id):
def
create_pair
(
request
):
template
=
loader
.
get_template
(
'members/admin/manage_attached_create_pair.html'
)
context
=
{
'title'
:
'BDM - Binômes'
,
'module'
:
'Membres'
}
return
HttpResponse
(
template
.
render
(
context
,
request
))
"""Create pair
payload example:
...
...
@@ -539,6 +530,11 @@ def create_pair(request):
def
delete_pair
(
request
):
""" Administration des binômes membres """
template
=
loader
.
get_template
(
'members/admin/manage_attached_delete_pair.html'
)
context
=
{
'title'
:
'BDM - Binômes'
,
'module'
:
'Membres'
}
return
HttpResponse
(
template
.
render
(
context
,
request
))
"""Delete pair
payload example:
...
...
members/static/css/admin/manage_attached.css
View file @
1a2bcfad
...
...
@@ -23,8 +23,13 @@
align-items
:
center
;
}
@media
screen
and
(
max-width
:
992px
)
{
#search_member_area
{
flex-direction
:
column
;
}
}
#search_member_form_area
{
display
:
flex
;
align-items
:
center
;
}
...
...
@@ -45,4 +50,47 @@
.search_member_results
{
display
:
flex
;
flex-wrap
:
wrap
;
}
/* -- Tiles */
.tile
{
flex
:
1
0
45%
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
border-radius
:
30px
;
margin
:
1rem
1rem
;
box-shadow
:
2px
2px
3px
rgba
(
10
,
10
,
10
,
.1
),
0
0
0
1px
rgba
(
10
,
10
,
10
,
.1
);
}
.high_tile
{
min-height
:
350px
;
}
.small_tile
{
min-height
:
250px
;
}
.full_width_tile
{
flex
:
1
0
90%
;
min-height
:
100px
;
}
.tile_title
{
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
border-bottom
:
1px
solid
#e7e9ed
;
font-size
:
2.4rem
;
padding
:
2rem
0
;
width
:
80%
;
}
.tile_content
{
position
:
relative
;
margin
:
3rem
0
;
width
:
80%
;
display
:
flex
;
height
:
100%
;
}
\ No newline at end of file
members/static/js/admin/bdm_index.js
View file @
1a2bcfad
...
...
@@ -13,10 +13,10 @@ $(document).ready(function() {
window
.
location
.
assign
(
location
+
"/manage_shift_registrations"
);
}
else
if
(
this
.
id
==
'manage_attached_button'
)
{
window
.
location
.
assign
(
location
+
"/manage_attached"
);
}
else
if
(
this
.
id
==
'manage_attached_delete_button'
)
{
window
.
location
.
assign
(
location
+
"/delete"
);
}
else
if
(
this
.
id
==
'manage_attached_create_button'
)
{
window
.
location
.
assign
(
location
+
"/create"
);
}
else
if
(
this
.
id
==
'manage_attached_delete_
pair_
button'
)
{
window
.
location
.
assign
(
location
+
"/delete
_pair
"
);
}
else
if
(
this
.
id
==
'manage_attached_create_
pair_
button'
)
{
window
.
location
.
assign
(
location
+
"/create
_pair
"
);
}
else
if
(
this
.
id
==
'manage_leaves_button'
)
{
console
.
log
(
'coming soon...'
);
}
...
...
members/urls.py
View file @
1a2bcfad
...
...
@@ -58,13 +58,11 @@ urlpatterns = [
url
(
r'^admin/manage_makeups$'
,
admin
.
manage_makeups
),
url
(
r'^admin/manage_shift_registrations$'
,
admin
.
manage_shift_registrations
),
url
(
r'^admin/manage_attached$'
,
admin
.
manage_attached
),
url
(
r'^admin/manage_attached/create
$'
,
admin
.
manage_attached_create
),
url
(
r'^admin/manage_attached/delete
$'
,
admin
.
manage_attached_delete
),
url
(
r'^admin/manage_attached/create
_pair$'
,
admin
.
create_pair
),
url
(
r'^admin/manage_attached/delete
_pair$'
,
admin
.
delete_pair
),
url
(
r'^get_makeups_members$'
,
admin
.
get_makeups_members
),
url
(
r'^update_members_makeups$'
,
admin
.
update_members_makeups
),
url
(
r'^delete_shift_registration$'
,
admin
.
delete_shift_registration
),
url
(
r'^get_member_info/(\d+)$'
,
admin
.
get_member_info
),
url
(
r'^admin/create_pair$'
,
admin
.
create_pair
),
url
(
r'^admin/delete_pair$'
,
admin
.
delete_pair
),
]
templates/members/admin/manage_attached.html
View file @
1a2bcfad
...
...
@@ -28,11 +28,11 @@
<div
class=
"page_content"
>
<div
class=
"management_type_buttons txtcenter"
>
<button
type=
"button"
class=
"btn--primary management_type_button"
id=
"manage_attached_create_button"
>
<button
type=
"button"
class=
"btn--primary management_type_button"
id=
"manage_attached_create_
pair_
button"
>
Créer un binôme
<span
class=
"management_type_button_icons"
><i
class=
"fas fa-arrow-right"
></i></span>
</button><br>
<button
type=
"button"
class=
"btn--primary management_type_button"
id=
"manage_attached_delete_button"
>
<button
type=
"button"
class=
"btn--primary management_type_button"
id=
"manage_attached_delete_
pair_
button"
>
Désolidariser un binôme
<span
class=
"management_type_button_icons"
><i
class=
"fas fa-arrow-right"
></i></span>
</button><br>
...
...
templates/members/admin/manage_attached_create.html
→
templates/members/admin/manage_attached_create
_pair
.html
View file @
1a2bcfad
...
...
@@ -26,39 +26,40 @@
</div>
<div
class=
"page_content"
>
<div
id=
"search_member_area"
>
<div
id=
"search_member_form_area"
>
<h4>
Rechercher le.a coopérateur.ice titulaire
</h4>
<form
id=
"search_member_form"
action=
"javascript:;"
method=
"post"
>
<input
type=
"text"
id=
"search_member_input"
value=
""
placeholder=
"Nom ou numéro du coop..."
required
>
<button
type=
"submit"
class=
"btn--primary"
id=
"search_member_button"
>
Recherche
</button>
</form>
</div>
</div>
<div
class=
"search_member_results_area"
style=
"display:none;"
>
<div
class=
"search_results_text"
>
<p><i>
Choisissez parmi les membres trouvés :
</i></p>
<div
class=
"tiles_container"
>
<div
id=
"search_member_area"
>
<div
id=
"search_member_form_area"
>
<h4>
Rechercher le.a coopérateur.ice titulaire
</h4>
<form
id=
"search_member_form"
action=
"javascript:;"
method=
"post"
>
<input
type=
"text"
id=
"search_member_input"
value=
""
placeholder=
"Nom ou numéro du coop..."
required
>
<button
type=
"submit"
class=
"btn--primary"
id=
"search_member_button"
>
Recherche
</button>
</form>
</div>
</div>
<div
class=
"search_member_results_area"
style=
"display:none;"
>
<div
class=
"search_results_text"
>
<p><i>
Choisissez parmi les membres trouvés :
</i></p>
</div>
<div
class=
"search_member_results"
></div>
</div>
<div
class=
"search_member_results"
></div>
</div>
<div
id=
"search_member_form_area"
>
<h4>
Rechercher le.a coopérateur.ice co-titulaire
</h4>
<form
id=
"search_member_form"
action=
"javascript:;"
method=
"post"
>
<input
type=
"text"
id=
"search_member_input"
value=
""
placeholder=
"Nom ou numéro du coop..."
required
>
<button
type=
"submit"
class=
"btn--primary"
id=
"search_member_button"
>
Recherche
</button>
</form>
</div>
</div>
<div
class=
"search_member_results_area"
style=
"display:none;"
>
<div
class=
"search_results_text"
>
<p><i>
Choisissez parmi les membres trouvés :
</i></p>
<div
id=
"search_member_area"
>
<div
id=
"search_member_form_area"
>
<h4>
Rechercher le.a coopérateur.ice co-titulaire
</h4>
<form
id=
"search_member_form"
action=
"javascript:;"
method=
"post"
>
<input
type=
"text"
id=
"search_member_input"
value=
""
placeholder=
"Nom ou numéro du coop..."
required
>
<button
type=
"submit"
class=
"btn--primary"
id=
"search_member_button"
>
Recherche
</button>
</form>
</div>
</div>
<div
class=
"search_member_results"
></div>
<div
class=
"search_member_results_area"
style=
"display:none;"
>
<div
class=
"search_results_text"
>
<p><i>
Choisissez parmi les membres trouvés :
</i></p>
</div>
<div
class=
"search_member_results"
></div>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
templates/members/admin/manage_attached_delete.html
→
templates/members/admin/manage_attached_delete
_pair
.html
View file @
1a2bcfad
File moved
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