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
ada4b8a0
Commit
ada4b8a0
authored
Sep 30, 2021
by
Damien Moulard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
linting
parent
1b3bbae9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
9 deletions
+12
-9
members-space-home.js
members_space/static/js/members-space-home.js
+3
-2
members-space-shifts-exchange.js
members_space/static/js/members-space-shifts-exchange.js
+9
-7
No files found.
members_space/static/js/members-space-home.js
View file @
ada4b8a0
...
...
@@ -30,7 +30,7 @@ function request_delay() {
verif_token
:
partner_data
.
verif_token
,
idPartner
:
partner_data
.
partner_id
,
start_date
:
delay_start
,
duration
:
diff_days
,
duration
:
diff_days
},
success
:
function
()
{
partner_data
.
cooperative_state
=
'delay'
;
...
...
@@ -45,6 +45,7 @@ function request_delay() {
closeModal
();
let
msg_template
=
$
(
"#cant_have_delay_msg_template"
);
openModal
(
msg_template
.
html
(),
()
=>
{
...
...
@@ -53,7 +54,7 @@ function request_delay() {
"J'accède au formulaire"
,
true
,
false
)
)
;
}
else
{
err
=
{
msg
:
"erreur serveur lors de la création du délai"
,
ctx
:
'request_delay'
};
if
(
typeof
data
.
responseJSON
!=
'undefined'
&&
typeof
data
.
responseJSON
.
error
!=
'undefined'
)
{
...
...
members_space/static/js/members-space-shifts-exchange.js
View file @
ada4b8a0
...
...
@@ -187,8 +187,8 @@ function init_calendar_page() {
template_explanations
.
html
(),
closeModal
,
"J'ai compris"
)
})
)
;
})
;
}
else
{
$
(
"#calendar_explaination_button"
).
hide
();
$
(
"#calendar_explaination_area"
).
html
(
template_explanations
.
html
());
...
...
@@ -288,10 +288,12 @@ function init_calendar_page() {
// Check if selected new shift is in less than 6 months
if
(
partner_data
.
date_delay_stop
!==
'False'
)
{
date_partner_delay_stop
=
new
Date
(
partner_data
.
date_delay_stop
);
if
(
datetime_new_shift
>
date_partner_delay_stop
)
{
if
(
datetime_new_shift
>
date_partner_delay_stop
)
{
let
msg
=
`Vous avez jusqu'au
${
date_partner_delay_stop
.
toLocaleDateString
(
"fr-fr"
,
date_options
)}
`
+
`pour sélectionner un rattrapage (soit une période de 6 mois depuis votre absence).`
;
alert
(
msg
);
return
;
}
}
...
...
@@ -341,11 +343,11 @@ function init_shifts_exchange() {
});
}
else
if
(
partner_data
.
cooperative_state
===
'suspended'
&&
partner_data
.
can_have_delay
===
'False'
)
{
&&
partner_data
.
can_have_delay
===
'False'
)
{
let
msg_template
=
$
(
"#cant_have_delay_msg_template"
);
$
(
".suspended_cant_have_delay_msg"
).
html
(
msg_template
.
html
())
$
(
"#suspended_cant_have_delay_content"
).
show
()
$
(
".suspended_cant_have_delay_msg"
).
html
(
msg_template
.
html
());
$
(
"#suspended_cant_have_delay_content"
).
show
();
$
(
".cant_have_delay_form_link"
)
.
show
()
...
...
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