Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
La Quadrature du Net
Respect My Net
Commits
94ca88b8
Commit
94ca88b8
authored
Mar 02, 2016
by
Okhin
Browse files
Updating the Me Too small form to actually work
parent
61763ca9
Changes
3
Hide whitespace changes
Inline
Side-by-side
nnmon/templates/index.html
View file @
94ca88b8
...
...
@@ -12,9 +12,8 @@
$
(
'
.metoo
'
).
submit
(
function
(
event
)
{
event
.
preventDefault
();
var
form
=
$
(
this
);
var
pk
=
form
.
attr
(
"
id
"
).
split
(
"
-
"
)[
1
];
var
email
=
form
.
find
(
"
#email-
"
+
pk
).
val
();
console
.
log
(
"
pk:
"
+
pk
+
"
email:
"
+
email
);
var
pk
=
$
(
form
).
attr
(
"
id
"
)
var
email
=
$
(
form
).
find
(
"
#email-
"
+
pk
).
val
();
$
.
ajax
({
url
:
"
/confirm/
"
+
pk
+
"
/
"
+
email
,
...
...
@@ -22,7 +21,7 @@ $('.metoo').submit(function(event) {
form
.
find
(
"
div
"
).
html
(
data
);
}
});
}
}
);
$
(
"
#lookup_btn
"
).
click
(
function
(
event
)
{
event
.
preventDefault
();
$
.
ajax
({
...
...
nnmon/templates/list.html
View file @
94ca88b8
...
...
@@ -14,6 +14,18 @@
<script
type=
"text/javascript"
>
var
data
=
{
%
if
countryweights
%
}{{
countryweights
|
safe
}}{
%
else
%
}[]{
%
endif
%
};
var
country
=
"
{{country}}
"
;
$
(
'
.metoo
'
).
submit
(
function
(
event
)
{
event
.
preventDefault
();
var
form
=
$
(
this
);
var
pk
=
$
(
form
).
attr
(
"
id
"
)
var
email
=
$
(
form
).
find
(
"
#email-
"
+
pk
).
val
();
$
.
ajax
({
url
:
"
/confirm/
"
+
pk
+
"
/
"
+
email
,
success
:
function
(
data
)
{
form
.
find
(
"
div
"
).
html
(
data
);
}
});
$
(
"
#sortedList
"
).
tablesorter
({
theme
:
'
dropbox
'
,
});
...
...
@@ -58,7 +70,7 @@ $("#sortedList").tablesorter({
<div
class=
"modal fade"
id=
"modal-{{ violation.pk }}"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"modal-label-{{ violation.pk }}"
data-backdrop=
"false"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<form
method=
"post"
class=
"inline-from"
action=
"/confirm/{{ violation.pk }}"
id=
"i{{ violation.pk }}"
>
<form
method=
"post"
class=
"
metoo
inline-from"
action=
"/confirm/{{ violation.pk }}"
id=
"i{{ violation.pk }}"
>
<div
class=
"modal-body"
>
<div
class=
"form-group"
>
<label
for=
"list-email-{{ violation.pk }}"
>
{% trans "In order to
<strong>
confirm
</strong>
this report, please enter your email address" %}
</label>
...
...
nnmon/templates/search/search.html
View file @
94ca88b8
...
...
@@ -15,6 +15,20 @@
<script
type=
"text/javascript"
>
var
data
=
{
%
if
countryweights
%
}{{
countryweights
|
safe
}}{
%
else
%
}[]{
%
endif
%
};
var
country
=
"
{{country}}
"
;
$
(
'
.metoo
'
).
submit
(
function
(
event
)
{
event
.
preventDefault
();
var
form
=
$
(
this
);
var
pk
=
$
(
form
).
attr
(
"
id
"
)
var
email
=
$
(
form
).
find
(
"
#email-
"
+
pk
).
val
();
$
.
ajax
({
url
:
"
/confirm/
"
+
pk
+
"
/
"
+
email
,
success
:
function
(
data
)
{
form
.
find
(
"
div
"
).
html
(
data
);
}
});
});
$
(
"
#sortedList
"
).
tablesorter
({
theme
:
'
dropbox
'
,
});
...
...
@@ -77,7 +91,7 @@ $("#sortedList").tablesorter({
<div
class=
"modal fade"
id=
"modal-{{ violation.pk }}"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"modal-label-{{ violation.pk }}"
data-backdrop=
"false"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<form
method=
"post"
class=
"inline-from"
action=
"/confirm/{{ violation.pk }}"
id=
"i{{ violation.pk }}"
>
<form
method=
"post"
class=
"
metoo
inline-from"
action=
"/confirm/{{ violation.pk }}"
id=
"i{{ violation.pk }}"
>
<div
class=
"modal-body"
>
<div
class=
"form-group"
>
<label
for=
"list-email-{{ violation.pk }}"
>
{% trans "In order to
<strong>
confirm
</strong>
this report, please enter your email address" %}
</label>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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