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
c772725e
Commit
c772725e
authored
Oct 05, 2022
by
Félicie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
first commit
parent
2e87daab
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
27 deletions
+48
-27
inscriptions.css
members/static/css/inscriptions.css
+7
-2
inscriptions.js
members/static/js/inscriptions.js
+21
-18
inscriptions.html
templates/members/inscriptions.html
+20
-7
No files found.
members/static/css/inscriptions.css
View file @
c772725e
...
...
@@ -59,7 +59,7 @@
font-weight
:
bold
;
}
#existing_member_choice
,
#new_
member_choice
{
.
member_choice
{
border
:
1px
solid
black
;
width
:
40%
;
cursor
:
pointer
;
...
...
@@ -69,7 +69,8 @@
color
:
black
;
padding
:
1rem
1.5rem
;
}
#existing_member_choice
:hover
,
#new_member_choice
:hover
{
.member_choice
:hover
,
.member_choice
:hover
{
background-color
:
#ccc
;
}
...
...
@@ -89,6 +90,10 @@
margin-bottom
:
10px
;
}
.choice_button_area
input
[
type
=
radio
]
{
display
:
none
;
}
#associate_area
{
margin-bottom
:
15px
;
}
...
...
members/static/js/inscriptions.js
View file @
c772725e
...
...
@@ -127,6 +127,7 @@ function create_new_coop() {
$
(
'.chosen_associate_area'
).
hide
();
$
(
'.member_choice'
).
removeClass
(
'choice_active'
);
$
(
".remove_binome_icon"
).
on
(
"click"
,
hide_chosen_associate
);
$
(
'input[name="binome"]'
).
prop
(
'checked'
,
false
);
local_in_process
=
getLocalInProcess
();
if
(
getLocalInProcess
().
length
>
0
)
{
empty_waiting_local_processes
();
...
...
@@ -611,27 +612,29 @@ $('#coop_create').submit(store_new_coop);
$
(
'#generate_email'
).
click
(
generate_email
);
$
(
'#odoo_user_connect'
).
click
();
$
(
'#add_binome'
).
click
(
function
()
{
if
(
$
(
'#associate_area'
).
is
(
':visible'
))
{
$
(
'#associate_area'
).
hide
();
$
(
'#new_member_input'
).
val
(
''
);
$
(
'#associate_area .choice_active'
).
removeClass
(
"choice_active"
);
associated_old_choice
=
null
;
if
(
current_coop
!=
null
)
{
delete
current_coop
.
parent_name
;
delete
current_coop
.
parent_id
;
delete
current_coop
.
is_associated_people
;
delete
current_coop
.
shift_template
;
}
}
else
{
$
(
'#associate_area'
).
show
();
$
(
'.member_choice'
).
removeClass
(
'choice_active'
);
$
(
'#existing_member_choice_action'
).
hide
();
$
(
'#new_member_choice_action'
).
hide
();
associated_old_choice
=
null
;
$
(
'#no_binome'
).
click
(
function
()
{
$
(
'#associate_area'
).
hide
();
$
(
'#new_member_input'
).
val
(
''
);
$
(
'#associate_area .choice_active'
).
removeClass
(
"choice_active"
);
associated_old_choice
=
null
;
if
(
current_coop
!=
null
)
{
delete
current_coop
.
parent_name
;
delete
current_coop
.
parent_id
;
delete
current_coop
.
is_associated_people
;
delete
current_coop
.
shift_template
;
}
});
$
(
'#add_binome'
).
click
(
function
()
{
$
(
'#associate_area'
).
show
();
$
(
'input[name="choose_binome"]'
).
prop
(
'required'
,
true
);
$
(
'.member_choice'
).
removeClass
(
'choice_active'
);
$
(
'#existing_member_choice_action'
).
hide
();
$
(
'#new_member_choice_action'
).
hide
();
associated_old_choice
=
null
;
});
$
(
'.member_choice'
).
on
(
'click'
,
function
()
{
if
(
associated_old_choice
!=
null
&&
associated_old_choice
!=
$
(
this
).
attr
(
'id'
))
{
...
...
templates/members/inscriptions.html
View file @
c772725e
...
...
@@ -80,16 +80,29 @@
{% endif %}
{% if can_create_binome %}
<p
id=
"add_binome"
>
+ Binomes (facultatif)
</p>
<div>
Voulez-vous mettre la personne en binôme ?
</div>
<label>
<input
type=
"radio"
name=
"binome"
id=
"no_binome"
required
>
Non
</label><br>
<label>
<input
type=
"radio"
name=
"binome"
id=
"add_binome"
required
>
Oui
</label><br>
<div
id=
"associate_area"
style=
"display:none;"
>
<div
class=
"choice_button_area d-flex"
>
<div
id=
"existing_member_choice"
class=
"member_choice"
>
A mettre en binome avec un.e membre existant.e
</div>
<label
class=
"member_choice"
id=
"existing_member_choice"
>
<input
type=
"radio"
name=
"choose_binome"
>
À mettre en binôme avec un.e membre existant.e
</label>
{% if ASSOCIATE_MEMBER_SHIFT %}
<div
id=
"new_member_choice"
class=
"member_choice"
>
A mettre en binome avec un.e nouveau membre
</div>
<label
class=
"member_choice"
id=
"new_member_choice"
>
<input
type=
"radio"
name=
"choose_binome"
>
À mettre en binôme avec un nouveau membre
</label>
{% endif %}
</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