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
47352168
Commit
47352168
authored
Feb 23, 2022
by
Etienne Freiss
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
work in progress
parent
37baee98
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
12 deletions
+15
-12
members-space-shifts-exchange.js
members_space/static/js/members-space-shifts-exchange.js
+12
-9
index.html
templates/members_space/index.html
+3
-3
No files found.
members_space/static/js/members-space-shifts-exchange.js
View file @
47352168
...
...
@@ -146,7 +146,7 @@ function init_shifts_list() {
if
(
partner_data
.
associated_partner_id
===
"False"
&&
partner_data
.
parent_id
===
"False"
){
shift_line_template
.
find
(
'.affect_associate_reistered'
).
hide
();
}
else
{
shift_line_template
.
find
(
'.affect_associate_registered'
).
attr
(
'id'
,
shift
.
id
)
shift_line_template
.
find
(
'.affect_associate_registered'
).
attr
(
'id'
,
'shidt_id_'
+
shift
.
id
)
if
(
shift
.
associate_registered
===
"both"
){
shift_line_template
.
find
(
'.affect_associate_registered'
).
text
(
"Les deux"
)
}
else
if
(
shift
.
associate_registered
===
"partner"
){
...
...
@@ -197,21 +197,24 @@ function init_shifts_list() {
}
});
$
(
".affect_associate_registered"
).
on
(
"click"
,
function
(
e
)
{
// Display modal
let
modal_template
=
$
(
"#modal_affect_shift"
);
console
.
log
(
modal_template
.
find
(
".partner"
).
html
())
if
(
partner_data
.
associated_partner_id
!=
"False"
)
{
modal_template
.
find
(
"
.
partner"
).
text
(
partner_data
.
name
);
modal_template
.
find
(
"
.
associate"
).
text
(
partner_data
.
associated_partner_name
);
modal_template
.
find
(
"
#shift_
partner"
).
text
(
partner_data
.
name
);
modal_template
.
find
(
"
#shift_
associate"
).
text
(
partner_data
.
associated_partner_name
);
}
else
{
modal_template
.
find
(
"
.
partner"
).
text
(
partner_data
.
associated_partner_name
);
modal_template
.
find
(
"
.
associate"
).
text
(
partner_data
.
parent_name
);
modal_template
.
find
(
"
#shift_
partner"
).
text
(
partner_data
.
associated_partner_name
);
modal_template
.
find
(
"
#shift_
associate"
).
text
(
partner_data
.
parent_name
);
}
// modal_template.find(".time_old_shift").text(old_shift_time);
// modal_template.find(".date_new_shift").text(new_shift_date);
// modal_template.find(".time_new_shift").text(new_shift_time);
openModal
(
modal_template
.
html
(),
...
...
templates/members_space/index.html
View file @
47352168
...
...
@@ -51,11 +51,11 @@
<div
id=
"modal_affect_shift"
>
<div>
Qui sera présent ?
</div>
<div
class=
"partner
btn--primary"
>
<div
id=
"shift_partner"
class=
"
btn--primary"
>
</div>
<div
class=
"associate
btn--primary"
>
<div
id=
"shift_associate"
class=
"
btn--primary"
>
</div>
<div
class=
"both
btn--primary"
>
<div
id=
"shift_both"
class=
"
btn--primary"
>
Les deux
</div>
...
...
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