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
afe5a5e8
Commit
afe5a5e8
authored
Mar 09, 2022
by
Etienne Freiss
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '2425-delete-future-registration' into 'dev_cooperatic'
2425 delete future registration See merge request
!133
parents
3f8e967a
ba8cceb1
Pipeline
#1886
passed with stage
in 1 minute 30 seconds
Changes
17
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
328 additions
and
56 deletions
+328
-56
models.py
members/models.py
+13
-0
members-space-my-info.css
members_space/static/css/members-space-my-info.css
+7
-0
members-space-shifts-exchange.css
members_space/static/css/members-space-shifts-exchange.css
+23
-0
members-space.css
members_space/static/css/members-space.css
+5
-0
members-space-faq.js
members_space/static/js/members-space-faq.js
+0
-0
members-space-my-shifts.js
members_space/static/js/members-space-my-shifts.js
+1
-2
members-space-shifts-exchange.js
members_space/static/js/members-space-shifts-exchange.js
+202
-45
members-space.js
members_space/static/js/members-space.js
+9
-1
urls.py
members_space/urls.py
+1
-0
views.py
members_space/views.py
+10
-0
models.py
shifts/models.py
+4
-3
urls.py
shifts/urls.py
+1
-0
views.py
shifts/views.py
+31
-0
home.html
templates/members_space/home.html
+3
-0
index.html
templates/members_space/index.html
+7
-5
my_info.html
templates/members_space/my_info.html
+3
-0
shifts_exchange.html
templates/members_space/shifts_exchange.html
+8
-0
No files found.
members/models.py
View file @
afe5a5e8
...
...
@@ -905,6 +905,19 @@ class CagetteMember(models.Model):
return
res
def
update_extra_shift_done
(
self
,
value
):
api
=
OdooAPI
()
res
=
{}
f
=
{
'extra_shift_done'
:
value
}
res_item
=
api
.
update
(
'res.partner'
,
[
self
.
id
],
f
)
res
=
{
'mid'
:
self
.
id
,
'update'
:
res_item
}
return
res
class
CagetteMembers
(
models
.
Model
):
"""Class to manage operations on all members or part of them."""
...
...
members_space/static/css/members-space-my-info.css
View file @
afe5a5e8
...
...
@@ -54,6 +54,13 @@
margin
:
3rem
0
;
}
#my_info
.choose_makeups
,
#my_info
.unsuscribed_form_link
,
#my_info
.remove_future_registration
{
font-size
:
1.8rem
;
word-break
:
normal
;
}
#my_info
#member_status_action
,
#my_info
.member_shift_name_area
,
#my_info
.member_coop_number_area
{
...
...
members_space/static/css/members-space-shifts-exchange.css
View file @
afe5a5e8
...
...
@@ -90,6 +90,14 @@
border-radius
:
5px
;
}
.delete_registration_button
{
justify-content
:
center
;
align-items
:
center
;
margin
:
0.75rem
15px
;
color
:
#d9534f
;
cursor
:
pointer
;
display
:
none
;
}
/* -- Calendar screen, makeups message */
...
...
@@ -113,6 +121,21 @@
}
}
/* -- Calendar screen, can delete registrations message */
#can_delete_future_registrations_area
{
display
:
none
;
align-self
:
center
;
margin
:
0
1rem
1rem
1rem
;
padding
:
1rem
1.25rem
;
}
#can_delete_future_registrations_area
button
{
white-space
:
normal
;
word-break
:
normal
;
margin
:
1rem
;
}
/* -- Calendar screen, calendar */
#calendar
{
...
...
members_space/static/css/members-space.css
View file @
afe5a5e8
...
...
@@ -166,6 +166,11 @@ body {
font-size
:
1.5rem
;
}
.remove_future_registration
{
display
:
none
;
white-space
:
normal
;
}
.unsuscribed_form_link
{
display
:
none
;
text-decoration
:
none
;
...
...
members_space/static/js/members-space-faq.js
View file @
afe5a5e8
members_space/static/js/members-space-my-shifts.js
View file @
afe5a5e8
...
...
@@ -68,8 +68,7 @@ function prepare_server_data(data) {
if
(
history_item
.
associate_registered
==
false
||
history_item
.
associate_registered
==
undefined
)
{
history_item
.
associate_registered
=
""
;
}
else
{
}
else
{
if
(
partner_data
.
associated_partner_id
!=
"False"
)
{
if
(
history_item
.
associate_registered
===
"partner"
)
{
history_item
.
associate_registered
=
partner_data
.
name
;
...
...
members_space/static/js/members-space-shifts-exchange.js
View file @
afe5a5e8
...
...
@@ -2,6 +2,8 @@ var calendar = null,
selected_shift
=
null
,
vw
=
null
;
/* - Logic */
/**
* A partner can exchange shifts if:
* - s.he doesn't have to choose a makeup shift
...
...
@@ -23,6 +25,8 @@ function should_select_makeup() {
return
partner_data
.
makeups_to_do
>
0
||
(
partner_data
.
makeups_to_do
>
0
&&
partner_data
.
is_associated_people
===
"True"
&&
block_actions_for_attached_people
===
"False"
);
}
/* - Server requests */
/**
* Proceed to shift exchange or registration
* @param {int} new_shift_id
...
...
@@ -118,6 +122,7 @@ function add_or_change_shift(new_shift_id) {
`Si tu ne peux vraiment pas venir, tu seras noté.e absent.e à ton service. `
+
`Tu devras alors sélectionner un service de rattrapage sur ton espace membre.`
);
}
else
if
(
error
.
status
===
500
&&
error
.
msg
===
"Fail to create shift"
)
{
// TODO differentiate error cases!
alert
(
`Une erreur est survenue. `
+
`Il est néanmoins possible que la requête ait abouti, `
+
`veuillez patienter quelques secondes puis vérifier vos services enregistrés.`
);
...
...
@@ -139,8 +144,147 @@ function add_or_change_shift(new_shift_id) {
}
});
}
return
null
;
}
/**
* Send request to delete (cancel) a shift registration.
* @param {Int} shift_registration_id shift registration to cancel
*/
function
delete_shift_registration
(
shift_registration_id
)
{
if
(
is_time_to
(
'delete_shift_registration'
))
{
openModal
();
tData
=
'idPartner='
+
partner_data
.
concerned_partner_id
+
'&idRegister='
+
shift_registration_id
+
'&extra_shift_done='
+
partner_data
.
extra_shift_done
;
if
(
partner_data
.
is_associated_people
===
"False"
)
{
tData
+=
'&verif_token='
+
partner_data
.
verif_token
;
}
else
if
(
partner_data
.
is_associated_people
===
"True"
&&
block_actions_for_attached_people
===
"False"
)
{
tData
+=
'&verif_token='
+
partner_data
.
parent_verif_token
;
}
else
{
return
false
;
}
$
.
ajax
({
type
:
'POST'
,
url
:
"/shifts/cancel_shift"
,
dataType
:
"json"
,
data
:
tData
,
timeout
:
3000
,
success
:
function
()
{
partner_data
.
extra_shift_done
-=
1
;
// Refetch partner shifts list & update DOM
load_partner_shifts
(
partner_data
.
concerned_partner_id
)
.
then
(()
=>
{
init_shifts_list
();
if
(
partner_data
.
extra_shift_done
>
0
)
{
$
(
".extra_shift_done"
).
text
(
partner_data
.
extra_shift_done
);
init_delete_registration_buttons
();
}
else
{
$
(
"#can_delete_future_registrations_area"
).
hide
();
$
(
".delete_registration_button"
).
off
();
$
(
".delete_registration_button"
).
hide
();
}
closeModal
();
setTimeout
(()
=>
{
alert
(
"La présence a bien été annulée !"
);
},
100
);
});
// Redraw calendar
calendar
.
refetchEvents
();
},
error
:
function
()
{
closeModal
();
alert
(
"Une erreur est survenue."
);
}
});
}
return
null
;
}
/**
* Proceed affecting a shift registration to a/both member(s) of a pair
* @param {string} partner
* @param {string} shift_id
*/
function
affect_shift
(
partner
,
shift_id
)
{
if
(
is_time_to
(
'affect_shift'
))
{
tData
=
'idShiftRegistration='
+
shift_id
+
'&idPartner='
+
partner_data
.
partner_id
+
'&affected_partner='
+
partner
+
'&verif_token='
+
partner_data
.
verif_token
;
tUrl
=
'/shifts/affect_shift'
;
$
.
ajax
({
type
:
'POST'
,
url
:
tUrl
,
dataType
:
"json"
,
data
:
tData
,
timeout
:
3000
,
success
:
function
()
{
load_partner_shifts
(
partner_data
.
concerned_partner_id
)
.
then
(()
=>
{
init_shifts_list
();
modal
.
find
(
".btn-modal-ok"
).
show
();
closeModal
();
});
},
error
:
function
()
{
init_shifts_list
();
modal
.
find
(
".btn-modal-ok"
).
show
();
closeModal
();
alert
(
`Une erreur est survenue. `
+
`Il est néanmoins possible que la requête ait abouti, `
+
`veuillez patienter quelques secondes puis vérifier vos services enregistrés.`
);
}
});
}
}
/**
* Reset a member extra_shift_done to 0
*/
function
offer_extra_shift
()
{
if
(
is_time_to
(
'offer_extra_shift'
))
{
openModal
();
$
.
ajax
({
type
:
'POST'
,
url
:
"/members_space/offer_extra_shift"
,
dataType
:
"json"
,
data
:
{
partner_id
:
partner_data
.
concerned_partner_id
},
timeout
:
3000
,
success
:
function
()
{
$
(
"#can_delete_future_registrations_area"
).
hide
();
$
(
".delete_registration_button"
).
off
();
$
(
".delete_registration_button"
).
hide
();
closeModal
();
alert
(
"Don de service effectué"
);
},
error
:
function
()
{
closeModal
();
alert
(
"Une erreur est survenue"
);
}
});
}
}
/* - DOM */
function
init_shifts_list
()
{
$
(
".loading-incoming-shifts"
).
hide
();
$
(
"#shifts_list"
).
show
();
...
...
@@ -150,7 +294,7 @@ function init_shifts_list() {
}
else
{
$
(
"#shifts_list"
).
empty
();
for
(
shift
of
incoming_shifts
)
{
for
(
let
shift
of
incoming_shifts
)
{
let
shift_line_template
=
$
(
"#selectable_shift_line_template"
);
let
datetime_shift_start
=
new
Date
(
shift
.
date_begin
.
replace
(
/
\s
/
,
'T'
));
...
...
@@ -161,6 +305,7 @@ function init_shifts_list() {
shift_line_template
.
find
(
".shift_line_date"
).
text
(
f_date_shift_start
);
shift_line_template
.
find
(
".shift_line_time"
).
text
(
datetime_shift_start
.
toLocaleTimeString
(
"fr-fr"
,
time_options
));
// Disable or not
if
(
!
can_exchange_shifts
()
&&
block_actions_for_attached_people
===
"True"
)
{
shift_line_template
.
find
(
".selectable_shift_line"
).
removeClass
(
"btn--primary"
);
shift_line_template
.
find
(
".selectable_shift_line"
).
addClass
(
"btn"
);
...
...
@@ -172,10 +317,12 @@ function init_shifts_list() {
shift_line_template
.
find
(
".checkbox"
).
prop
(
"value"
,
shift
.
id
);
}
// Set assign shift button
if
(
partner_data
.
associated_partner_id
===
"False"
&&
partner_data
.
parent_id
===
"False"
)
{
shift_line_template
.
find
(
'.affect_associate_registered'
).
hide
();
}
else
{
shift_line_template
.
find
(
'.affect_associate_registered'
).
attr
(
'id'
,
'shift_id_'
+
shift
.
id
);
shift_line_template
.
find
(
'.affect_associate_registered'
).
closest
(
".shift_line_container"
)
.
attr
(
'id'
,
'shift_id_'
+
shift
.
id
);
if
(
shift
.
associate_registered
===
"both"
)
{
shift_line_template
.
find
(
'.affect_associate_registered'
).
text
(
"Les deux"
);
}
else
if
(
shift
.
associate_registered
===
"partner"
)
{
...
...
@@ -196,6 +343,17 @@ function init_shifts_list() {
}
}
// Set delete registration button if shift isn't a makeup
if
(
partner_data
.
extra_shift_done
>
0
&&
shift
.
is_makeup
===
false
)
{
if
(
shift_line_template
.
find
(
".delete_registration_button"
).
length
===
0
)
{
let
delete_reg_button_template
=
$
(
"#delete_registration_button_template"
);
shift_line_template
.
find
(
".shift_line_container"
).
append
(
delete_reg_button_template
.
html
());
}
}
else
{
shift_line_template
.
find
(
".delete_registration_button"
).
remove
();
}
$
(
"#shifts_list"
).
append
(
shift_line_template
.
html
());
}
...
...
@@ -228,7 +386,8 @@ function init_shifts_list() {
$
(
".affect_associate_registered"
).
on
(
"click"
,
function
()
{
// Display modal
id
=
$
(
this
).
attr
(
'id'
)
let
id
=
$
(
this
).
closest
(
".shift_line_container"
)
.
attr
(
'id'
)
.
split
(
'_'
)[
2
];
let
modal_template
=
$
(
"#modal_affect_shift"
);
...
...
@@ -267,48 +426,6 @@ function init_shifts_list() {
}
}
/**
* Proceed to shift modification
* @param {string} partner
* @param {string} shift_id
*/
function
affect_shift
(
partner
,
shift_id
)
{
tData
=
'idShiftRegistration='
+
shift_id
+
'&idPartner='
+
partner_data
.
partner_id
+
'&affected_partner='
+
partner
+
'&verif_token='
+
partner_data
.
verif_token
;
tUrl
=
'/shifts/affect_shift'
;
$
.
ajax
({
type
:
'POST'
,
url
:
tUrl
,
dataType
:
"json"
,
data
:
tData
,
timeout
:
3000
,
success
:
function
()
{
load_partner_shifts
(
partner_data
.
concerned_partner_id
)
.
then
(()
=>
{
init_shifts_list
();
modal
.
find
(
".btn-modal-ok"
).
show
();
closeModal
();
});
},
error
:
function
()
{
init_shifts_list
();
modal
.
find
(
".btn-modal-ok"
).
show
();
closeModal
();
alert
(
`Une erreur est survenue. `
+
`Il est néanmoins possible que la requête ait abouti, `
+
`veuillez patienter quelques secondes puis vérifier vos services enregistrés.`
);
}
});
}
/**
* Inits the page when the calendar is displayed
*/
...
...
@@ -345,6 +462,22 @@ function init_calendar_page() {
$
(
"#need_to_select_makeups_message"
).
show
();
}
if
(
partner_data
.
extra_shift_done
>
0
)
{
$
(
".extra_shift_done"
).
text
(
partner_data
.
extra_shift_done
);
$
(
"#can_delete_future_registrations_area"
).
show
();
$
(
"#offer_extra_shift"
).
on
(
"click"
,
()
=>
{
openModal
(
"<p>Je ne souhaite pas supprimer un service futur.</p>"
,
offer_extra_shift
,
"Confirmer"
,
false
);
});
$
(
"#delete_future_registration"
).
on
(
"click"
,
init_delete_registration_buttons
);
}
let
default_initial_view
=
""
;
let
header_toolbar
=
{};
...
...
@@ -569,6 +702,30 @@ function init_read_only_calendar_page() {
calendar
.
render
();
}
function
init_delete_registration_buttons
()
{
$
(
".delete_registration_button"
).
off
();
$
(
".delete_registration_button"
).
on
(
"click"
,
function
()
{
let
shift_name
=
$
(
this
).
closest
(
"div"
)
.
siblings
(
".selectable_shift_line"
)
.
text
()
.
trim
();
let
shift_id
=
$
(
this
).
closest
(
".shift_line_container"
)
.
attr
(
'id'
)
.
split
(
'_'
)[
2
];
openModal
(
`<p>Je m'apprête supprimer ma présence au service du <b>
${
shift_name
}
</b></p>`
,
()
=>
{
delete_shift_registration
(
shift_id
);
},
"Confirmer"
,
false
);
});
$
(
".delete_registration_button"
).
css
(
'display'
,
'flex'
);
}
function
init_shifts_exchange
()
{
$
(
".shifts_exchange_page_content"
).
hide
();
vw
=
window
.
innerWidth
;
...
...
members_space/static/js/members-space.js
View file @
afe5a5e8
...
...
@@ -158,6 +158,7 @@ function prepare_shift_line_template(date_begin) {
*/
function
init_my_info_data
()
{
$
(
".choose_makeups"
).
off
();
$
(
".remove_future_registration"
).
off
();
$
(
".unsuscribed_form_link"
).
off
();
$
(
".member_shift_name"
).
text
(
partner_data
.
regular_shift_name
);
...
...
@@ -223,6 +224,13 @@ function init_my_info_data() {
}
}
if
(
partner_data
.
extra_shift_done
>
0
)
{
$
(
".remove_future_registration"
).
show
();
$
(
".remove_future_registration"
).
on
(
'click'
,
()
=>
{
goto
(
'echange-de-services'
);
});
}
$
(
".member_coop_number"
).
text
(
partner_data
.
barcode_base
);
}
...
...
@@ -257,7 +265,7 @@ $(document).ready(function() {
// debouncing function from John Hann
// http://unscriptable.com/index.php/2009/03/20/debouncing-javascript-methods/
var
debounce
=
function
(
func
,
threshold
,
execAsap
)
{
var
timeout
;
var
timeout
=
null
;
return
function
debounced
()
{
var
obj
=
this
,
args
=
arguments
;
...
...
members_space/urls.py
View file @
afe5a5e8
...
...
@@ -12,5 +12,6 @@ urlpatterns = [
url
(
r'^faqBDM$'
,
views
.
faqBDM
),
url
(
r'^no_content$'
,
views
.
no_content
),
url
(
r'^get_shifts_history$'
,
views
.
get_shifts_history
),
url
(
r'^offer_extra_shift$'
,
views
.
offer_extra_shift
),
url
(
r'^.*'
,
views
.
index
)
# Urls unknown from the server will redirect to index
]
members_space/views.py
View file @
afe5a5e8
...
...
@@ -99,6 +99,7 @@ def index(request, exception=None):
partnerData
[
"parent_id"
]
=
partnerData
[
"parent_id"
][
0
]
md5_calc
=
hashlib
.
md5
(
partnerData
[
'parent_create_date'
]
.
encode
(
'utf-8'
))
.
hexdigest
()
partnerData
[
'parent_verif_token'
]
=
md5_calc
partnerData
[
'extra_shift_done'
]
=
partnerData
[
"parent_extra_shift_done"
]
else
:
partnerData
[
"parent_name"
]
=
False
...
...
@@ -235,3 +236,12 @@ def get_shifts_history(request):
res
[
"data"
]
=
m
.
get_shifts_history
(
partner_id
,
limit
,
offset
,
date_from
)
return
JsonResponse
(
res
)
def
offer_extra_shift
(
request
):
res
=
{}
partner_id
=
int
(
request
.
POST
[
'partner_id'
])
m
=
CagetteMember
(
partner_id
)
res
=
m
.
update_extra_shift_done
(
0
)
return
JsonResponse
(
res
)
shifts/models.py
View file @
afe5a5e8
...
...
@@ -38,17 +38,18 @@ class CagetteShift(models.Model):
'cooperative_state'
,
'final_standard_point'
,
'create_date'
,
'final_ftop_point'
,
'shift_type'
,
'leave_ids'
,
'makeups_to_do'
,
'barcode_base'
,
'street'
,
'street2'
,
'zip'
,
'city'
,
'mobile'
,
'phone'
,
'email'
,
'is_associated_people'
,
'parent_id'
]
'is_associated_people'
,
'parent_id'
,
'extra_shift_done'
]
partnerData
=
self
.
o_api
.
search_read
(
'res.partner'
,
cond
,
fields
,
1
)
if
partnerData
:
partnerData
=
partnerData
[
0
]
if
partnerData
[
'is_associated_people'
]:
cond
=
[[
'id'
,
'='
,
partnerData
[
'parent_id'
][
0
]]]
fields
=
[
'create_date'
]
fields
=
[
'create_date'
,
'extra_shift_done'
]
parentData
=
self
.
o_api
.
search_read
(
'res.partner'
,
cond
,
fields
,
1
)
if
parentData
:
partnerData
[
'parent_create_date'
]
=
parentData
[
0
][
'create_date'
]
partnerData
[
'parent_extra_shift_done'
]
=
parentData
[
0
][
'extra_shift_done'
]
if
partnerData
[
'shift_type'
]
==
'standard'
:
partnerData
[
'in_ftop_team'
]
=
False
...
...
@@ -91,7 +92,7 @@ class CagetteShift(models.Model):
def
get_shift_partner
(
self
,
id
):
"""Récupère les shift du membre"""
fields
=
[
'date_begin'
,
'date_end'
,
'final_standard_point'
,
'shift_id'
,
'shift_type'
,
'partner_id'
,
"id"
,
"associate_registered"
]
# res.partner
'shift_id'
,
'shift_type'
,
'partner_id'
,
"id"
,
"associate_registered"
,
"is_makeup"
]
# res.partner
cond
=
[[
'partner_id.id'
,
'='
,
id
],[
'state'
,
'='
,
'open'
],
[
'date_begin'
,
'>'
,
datetime
.
datetime
.
now
()
.
isoformat
()]]
shiftData
=
self
.
o_api
.
search_read
(
'shift.registration'
,
cond
,
fields
,
order
=
"date_begin ASC"
)
...
...
shifts/urls.py
View file @
afe5a5e8
...
...
@@ -15,6 +15,7 @@ urlpatterns = [
url
(
r'^change_shift'
,
views
.
change_shift
),
url
(
r'^affect_shift'
,
views
.
affect_shift
),
url
(
r'^add_shift'
,
views
.
add_shift
),
url
(
r'^cancel_shift'
,
views
.
cancel_shift
),
url
(
r'^request_delay'
,
views
.
request_delay
),
url
(
r'^reset_members_positive_points'
,
views
.
reset_members_positive_points
)
]
shifts/views.py
View file @
afe5a5e8
...
...
@@ -310,6 +310,37 @@ def add_shift(request):
else
:
return
HttpResponseForbidden
()
def
cancel_shift
(
request
):
""" Annule une présence à un shift """
if
'verif_token'
in
request
.
POST
:
partner_id
=
int
(
request
.
POST
.
get
(
'idPartner'
))
if
Verification
.
verif_token
(
request
.
POST
.
get
(
'verif_token'
),
partner_id
)
is
True
:
cs
=
CagetteShift
()
listRegister
=
[
int
(
request
.
POST
[
'idRegister'
])]
try
:
response
=
cs
.
cancel_shift
(
listRegister
)
# decrement extra_shift_done if param exists
if
'extra_shift_done'
in
request
.
POST
:
target
=
int
(
request
.
POST
[
"extra_shift_done"
])
-
1
# extra security
if
target
<
0
:
target
=
0
cm
=
CagetteMember
(
partner_id
)
cm
.
update_extra_shift_done
(
target
)
return
JsonResponse
({
"res"
:
'response'
})
except
Exception
as
e
:
return
JsonResponse
({
"error"
:
str
(
e
)},
status
=
500
)
else
:
return
HttpResponseForbidden
()
else
:
return
HttpResponseForbidden
()
def
request_delay
(
request
):
if
'verif_token'
in
request
.
POST
:
if
Verification
.
verif_token
(
request
.
POST
.
get
(
'verif_token'
),
int
(
request
.
POST
.
get
(
'idPartner'
)))
is
True
:
...
...
templates/members_space/home.html
View file @
afe5a5e8
...
...
@@ -21,6 +21,9 @@
<button
type=
"button"
class=
"btn--danger choose_makeups"
>
Je sélectionne mes rattrapages
</button>
<button
type=
"button"
class=
"btn--success remove_future_registration"
>
J'ai validé un service à deux, je peux supprimer une présence
</button>
</div>
<div
class=
"member_shift_name_area"
>
<span>
Mon créneau :
</span>
...
...
templates/members_space/index.html
View file @
afe5a5e8
...
...
@@ -36,17 +36,19 @@
</div>
<div
id=
"selectable_shift_line_template"
>
<div
class=
"d-flex"
>
<div
class=
"d-flex
shift_line_container
"
>
<div
class=
"selectable_shift_line btn--primary"
>
<input
type=
"checkbox"
class=
"checkbox"
>
<div
class=
"selectable_shift_line_text"
>
<span
class=
"shift_line_date"
></span>
-
<span
class=
"shift_line_time"
></span>
</div>
</div>
<div
class=
"affect_associate_registered button--warning"
>
<div
class=
"affect_associate_registered button--warning"
></div>
</div>
</div>
<div
id=
"delete_registration_button_template"
>
<div
class=
"delete_registration_button"
><i
class=
"fas fa-lg fa-trash"
></i></div>
</div>
<div
id=
"modal_affect_shift"
>
...
...
@@ -58,7 +60,6 @@
<div
id=
"shift_both"
class=
" btn--primary"
>
Les deux
</div>
</div>
<div
id=
"modal_shift_exchange_template"
>
...
...
@@ -140,7 +141,8 @@
"associated_partner_name"
:
"{{partnerData.associated_partner_name}}"
,
"verif_token"
:
"{{partnerData.verif_token}}"
,
"leave_stop_date"
:
"{{partnerData.leave_stop_date}}"
,
"comite"
:
"{{partnerData.comite}}"
"comite"
:
"{{partnerData.comite}}"
,
"extra_shift_done"
:
parseInt
(
"{{partnerData.extra_shift_done}}"
,
10
)
};
var
block_actions_for_attached_people
=
'{{block_actions_for_attached_people}}'
;
</script>
...
...
templates/members_space/my_info.html
View file @
afe5a5e8
...
...
@@ -25,6 +25,9 @@
<button
type=
"button"
class=
"btn--danger choose_makeups"
>
Je sélectionne mes rattrapages
</button>
<button
type=
"button"
class=
"btn--success remove_future_registration"
>
J'ai validé un service à deux, je peux supprimer une présence
</button>
</div>
</div>
</div>
...
...
templates/members_space/shifts_exchange.html
View file @
afe5a5e8
...
...
@@ -35,6 +35,14 @@
<span
class=
"select_makeups_message_block"
>
Je dois les sélectionner dans le calendrier.
</span>
<span
class=
"select_makeups_message_block"
>
Je ne peux pas échanger de service tant que je n'ai pas choisi mes rattrapages.
</span>
</div>
<div
id=
"can_delete_future_registrations_area"
>
<button
class=
"btn--success can_delete_future_registrations_button"
id=
"delete_future_registration"
>
J'ai validé
<span
class=
"extra_shift_done"
></span>
service(s) à deux, je supprime un service futur
</button>
<button
class=
"btn--success can_delete_future_registrations_button"
id=
"offer_extra_shift"
>
Je souhaite donner
<span
class=
"extra_shift_done"
></span>
service(s) d'avance à la communauté
</button>
</div>
<div
id=
"calendar_top_info"
>
<div
id=
"partner_shifts_list"
>
<h4>
Liste de mes services :
</h4>
...
...
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