X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;ds=sidebyside;f=src%2Fmain%2Fresources%2Ftemplates%2Finclude%2Fhead.html;h=19a5f3860536628c2a273055fce4c4db781a91cb;hb=127690d3563777313dda224adf420e88e0f25668;hp=16c939104d3f0cad9ee03021aaded3319981df2a;hpb=49d9495df2c569a03b24925e1b0f3c9bcbd2f379;p=Sone.git diff --git a/src/main/resources/templates/include/head.html b/src/main/resources/templates/include/head.html index 16c9391..19a5f38 100644 --- a/src/main/resources/templates/include/head.html +++ b/src/main/resources/templates/include/head.html @@ -34,7 +34,7 @@ $(document).ready(function() { $("#sone .post").each(function() { postId = $(this).attr("id"); - enhanceDeletePostButton("#sone .post#" + postId + " > .status-line .delete button", postId); + enhanceDeletePostButton("#sone .post#" + postId + " > .inner-part > .status-line .delete button", postId); (function(postId) { $("#sone .post#" + postId + " .reply").each(function() { replyId = $(this).attr("id"); @@ -84,17 +84,31 @@ }); return false; }); + $("#sone .blacklist").submit(function() { + var blacklistElement = this; + $.getJSON("ajax/blacklistSone.ajax", { "sone" : getSoneId(this), "formPassword" : getFormPassword() }, function() { + $(getSoneElement(blacklistElement)).slideUp(); + }); + return false; + }); + $("#sone .unblacklist").submit(function() { + var unblacklistElement = this; + $.getJSON("ajax/unblacklistSone.ajax", { "sone" : getSoneId(this), "formPassword" : getFormPassword() }, function() { + $(getSoneElement(unblacklistElement)).slideUp(); + }); + return false; + }); });