Merge branch 'master' into Develop
# Conflicts: # cps/__init__.py # cps/comic.py # cps/editbooks.py # cps/helper.py # cps/kobo.py # cps/translations/nl/LC_MESSAGES/messages.mo # cps/translations/nl/LC_MESSAGES/messages.po # cps/ub.py # cps/uploader.py # cps/web.py
This commit is contained in:
@@ -28,7 +28,7 @@ $( 'body.mailset' ).addClass( 'admin' );
|
||||
curHref = window.location.href.split('/');
|
||||
prevHref = document.referrer.split('/');
|
||||
$( '.navbar-form.navbar-left' )
|
||||
.before( '<div class="plexBack"><a href="' + document.referrer + '"></a></div>' );
|
||||
.before( '<div class="plexBack"><a href="' + encodeURI(document.referrer) + '"></a></div>' );
|
||||
if ( history.length === 1 ||
|
||||
curHref[0] +
|
||||
curHref[1] +
|
||||
@@ -43,7 +43,7 @@ if ( history.length === 1 ||
|
||||
//Weird missing a after pressing back from edit.
|
||||
setTimeout(function() {
|
||||
if ( $( '.plexBack a').length < 1 ) {
|
||||
$( '.plexBack' ).append('<a href="' + document.referrer + '"></a>');
|
||||
$( '.plexBack' ).append('<a href="' + encodeURI(document.referrer) + '"></a>');
|
||||
}
|
||||
},10);
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ $("#sort_name").click(function() {
|
||||
});*/
|
||||
// Find count of middle element
|
||||
if (count > 20) {
|
||||
var middle = parseInt(count / 2) + (count % 2);
|
||||
var middle = parseInt(count / 2, 10) + (count % 2);
|
||||
// search for the middle of all visibe elements
|
||||
$(".row").each(function() {
|
||||
index++;
|
||||
@@ -146,7 +146,7 @@ $("#all").click(function() {
|
||||
// Find count of middle element
|
||||
var listItems = $("#list").children(".row");
|
||||
var listlength = listItems.length;
|
||||
var middle = parseInt(listlength / 2) + (listlength % 2);
|
||||
var middle = parseInt(listlength / 2, 10) + (listlength % 2);
|
||||
// go through all elements and make them visible
|
||||
listItems.each(function() {
|
||||
$(this).show();
|
||||
@@ -178,7 +178,7 @@ $(".char").click(function() {
|
||||
});
|
||||
if (count > 20) {
|
||||
// Find count of middle element
|
||||
var middle = parseInt(count / 2) + (count % 2);
|
||||
var middle = parseInt(count / 2, 10) + (count % 2);
|
||||
// search for the middle of all visibe elements
|
||||
$(".row").each(function() {
|
||||
index++;
|
||||
|
||||
@@ -112,7 +112,7 @@ $(function() {
|
||||
return "";
|
||||
},
|
||||
url: path + "/../../ajax/listrestriction/" + type,
|
||||
rowStyle: function(row, index) {
|
||||
rowStyle: function(row) {
|
||||
// console.log('Reihe :' + row + " Index :" + index);
|
||||
if (row.id.charAt(0) === "a") {
|
||||
return {classes: "bg-primary"};
|
||||
@@ -120,15 +120,15 @@ $(function() {
|
||||
return {classes: "bg-dark-danger"};
|
||||
}
|
||||
},
|
||||
onClickCell: function (field, value, row, $element) {
|
||||
if (field == 3) {
|
||||
onClickCell: function (field, value, row) {
|
||||
if (field === 3) {
|
||||
$.ajax ({
|
||||
type: "Post",
|
||||
data: "id=" + row.id + "&type=" + row.type + "&Element=" + row.Element,
|
||||
url: path + "/../../ajax/deleterestriction/" + type,
|
||||
async: true,
|
||||
timeout: 900,
|
||||
success:function(data) {
|
||||
success:function() {
|
||||
$.ajax({
|
||||
method:"get",
|
||||
url: path + "/../../ajax/listrestriction/" + type,
|
||||
@@ -145,14 +145,14 @@ $(function() {
|
||||
striped: false
|
||||
});
|
||||
$("#restrict-elements-table").removeClass("table-hover");
|
||||
$("#restrict-elements-table").on("editable-save.bs.table", function (e, field, row, old, $el) {
|
||||
$("#restrict-elements-table").on("editable-save.bs.table", function (e, field, row) {
|
||||
$.ajax({
|
||||
url: path + "/../../ajax/editrestriction/" + type,
|
||||
type: "Post",
|
||||
data: row
|
||||
});
|
||||
});
|
||||
$("[id^=submit_]").click(function(event) {
|
||||
$("[id^=submit_]").click(function() {
|
||||
$(this)[0].blur();
|
||||
$.ajax({
|
||||
url: path + "/../../ajax/addrestriction/" + type,
|
||||
@@ -196,7 +196,7 @@ $(function() {
|
||||
});
|
||||
|
||||
/* Function for deleting domain restrictions */
|
||||
function TableActions (value, row, index) {
|
||||
function TableActions (value, row) {
|
||||
return [
|
||||
"<a class=\"danger remove\" data-toggle=\"modal\" data-target=\"#DeleteDomain\" data-domain-id=\"" + row.id
|
||||
+ "\" title=\"Remove\">",
|
||||
@@ -206,7 +206,7 @@ function TableActions (value, row, index) {
|
||||
}
|
||||
|
||||
/* Function for deleting domain restrictions */
|
||||
function RestrictionActions (value, row, index) {
|
||||
function RestrictionActions (value, row) {
|
||||
return [
|
||||
"<div class=\"danger remove\" data-restriction-id=\"" + row.id + "\" title=\"Remove\">",
|
||||
"<i class=\"glyphicon glyphicon-trash\"></i>",
|
||||
|
||||
Reference in New Issue
Block a user