|
|
@@ -12,9 +12,6 @@ $(document).ready( function () {
|
|
|
}
|
|
|
});
|
|
|
|
|
|
- var loc_uri = URI.parse(window.location.href);
|
|
|
- var loc_qry = URI.parseQuery(loc_uri.query)
|
|
|
-
|
|
|
$('.filters-bar').children('select[data-filter]').each(function () {
|
|
|
var filter_name = $(this).data('filter');
|
|
|
if(filter_name in loc_qry) {
|
|
|
@@ -84,21 +81,6 @@ $(document).ready( function () {
|
|
|
window.location.href = target;
|
|
|
});
|
|
|
|
|
|
- var getUrlParameter = function getUrlParameter(sParam) {
|
|
|
- var sPageURL = window.location.search.substring(1),
|
|
|
- sURLVariables = sPageURL.split('&'),
|
|
|
- sParameterName,
|
|
|
- i;
|
|
|
-
|
|
|
- for (i = 0; i < sURLVariables.length; i++) {
|
|
|
- sParameterName = sURLVariables[i].split('=');
|
|
|
-
|
|
|
- if (sParameterName[0] === sParam) {
|
|
|
- return sParameterName[1] === undefined ? true : decodeURIComponent(sParameterName[1]);
|
|
|
- }
|
|
|
- }
|
|
|
- };
|
|
|
-
|
|
|
$('#id_epic').val([getUrlParameter('epic')])
|
|
|
$('#id_name').val([getUrlParameter('name')])
|
|
|
$('#id_weight').val([getUrlParameter('weight')])
|
|
|
@@ -138,27 +120,6 @@ $(document).ready( function () {
|
|
|
}
|
|
|
});
|
|
|
|
|
|
- function csrfSafeMethod(method) {
|
|
|
- // these HTTP methods do not require CSRF protection
|
|
|
- return (/^(GET|HEAD|OPTIONS|TRACE)$/.test(method));
|
|
|
- }
|
|
|
- function getCookie(name) {
|
|
|
- var cookieValue = null;
|
|
|
- if (document.cookie && document.cookie !== '') {
|
|
|
- var cookies = document.cookie.split(';');
|
|
|
- for (var i = 0; i < cookies.length; i++) {
|
|
|
- var cookie = jQuery.trim(cookies[i]);
|
|
|
- // Does this cookie string begin with the name we want?
|
|
|
- if (cookie.substring(0, name.length + 1) === (name + '=')) {
|
|
|
- cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
|
|
|
- break;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- return cookieValue;
|
|
|
- }
|
|
|
- var csrftoken = getCookie('csrftoken');
|
|
|
-
|
|
|
$(".notif-seen").click(function(event) {
|
|
|
event.preventDefault();
|
|
|
var notif = $(this).closest('.notif');
|