updated libs and js

This commit is contained in:
tmont 2011-03-04 08:20:37 +00:00
parent a41335c5ba
commit a414d1a17f
9 changed files with 46 additions and 7 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -713,6 +713,12 @@
</summary> </summary>
<param name="indexableObject">The object that needs its index updated</param> <param name="indexableObject">The object that needs its index updated</param>
</member> </member>
<member name="M:Portoa.Search.ISearchIndexBuilder`1.DeleteIndex(`0)">
<summary>
Deletes the index for the specified <paramref name="indexableObject"/>
</summary>
<param name="indexableObject">The object that needs its index deleted</param>
</member>
<member name="M:Portoa.Search.CompositeIndexBuilder.Add``1(Portoa.Search.ISearchIndexBuilder{``0})"> <member name="M:Portoa.Search.CompositeIndexBuilder.Add``1(Portoa.Search.ISearchIndexBuilder{``0})">
<summary> <summary>
Adds an index builder to the collection Adds an index builder to the collection
@ -755,6 +761,12 @@
</summary> </summary>
<param name="entity">The entity that needs its index updated</param> <param name="entity">The entity that needs its index updated</param>
</member> </member>
<member name="M:Portoa.Search.ISearchIndexBuilder`2.DeleteIndex(`0)">
<summary>
Deletes the index for the specified <paramref name="entity"/>
</summary>
<param name="entity">The entity that needs its index deleted</param>
</member>
<member name="M:Portoa.Logging.LoggingExtensions.IsLoggable(System.Reflection.ICustomAttributeProvider)"> <member name="M:Portoa.Logging.LoggingExtensions.IsLoggable(System.Reflection.ICustomAttributeProvider)">
<summary> <summary>
Determines if this object should be logged Determines if this object should be logged

View File

@ -96,7 +96,7 @@ dd {
body { body {
background-color: #EEEEEE; background-color: #EEEEEE;
color: #000000; color: #000000;
font-family: Calibri, Corbel, Helvetica, Arial; font-family: Calibri, Corbel, Arial;
font-size: 1em; font-size: 1em;
height: 100%; height: 100%;
} }
@ -511,7 +511,7 @@ a.external {
.quote-links { .quote-links {
float: right; float: right;
text-align: right; text-align: right;
width: 100px; width: 125px;
} }
.flag-dialog { .flag-dialog {

File diff suppressed because one or more lines are too long

View File

@ -428,13 +428,11 @@
var $submit = $("<a/>").attr({ href: "#", title: "submit" }).addClass("submit-icon").click(submitCategory); var $submit = $("<a/>").attr({ href: "#", title: "submit" }).addClass("submit-icon").click(submitCategory);
var $cancel = $("<a/>").attr({ href: "#", title: "cancel" }).addClass("cancel-icon"); var $cancel = $("<a/>").attr({ href: "#", title: "cancel" }).addClass("cancel-icon");
var $input = $("<input/>").attr({ id: "new-category-name", type: "text" }).bind("keyup", function(e) { var $input = $("<input/>").attr({ id: "new-category-name", type: "text" }).bind("keyup", function(e) {
console.log(e.which);
if (e.which === 13) { if (e.which === 13) {
e.preventDefault(); //make sure the parent form doesn't get submitted e.preventDefault(); //make sure the parent form doesn't get submitted
submitCategory.call($(this).siblings(".submit-icon").get(0)); //make sure to invoke it with the correct context submitCategory.call($(this).siblings(".submit-icon").get(0)); //make sure to invoke it with the correct context
} else if (e.which === 27) { } else if (e.which === 27) {
e.preventDefault(); e.preventDefault();
//$cancel.onclick.call($(this).siblings(".cancel-icon").get(0));
$cancel.click(); $cancel.click();
} }
}); });
@ -457,6 +455,10 @@
} }
var $row = $table.find("tr:last"); var $row = $table.find("tr:last");
if ($row.length === 0) {
$row = $("<tr/>");
$table.append($row);
}
$cell = $("<td/>"); $cell = $("<td/>");
if ($row.find("td").length === 5) { if ($row.find("td").length === 5) {
$row = $("<tr/>"); $row = $("<tr/>");

File diff suppressed because one or more lines are too long

View File

@ -135,7 +135,7 @@
}; };
var setupFlagLink = function() { var setupFlagLink = function() {
$("a.quote-flag-icon").click(function() { $(".quote-flag-link").click(function() {
if ($(".flag-dialog").length > 0) { if ($(".flag-dialog").length > 0) {
return false; return false;
} }
@ -205,6 +205,30 @@
}); });
}; };
var setupDeleteLink = function() {
$(".delete-quote-link").click(function() {
var $link = $(this);
var $container = $link.parents(".quote-container");
$.ajax("/quote/delete", {
type: "POST",
data: { id: $container.find(".quote-id").val() },
beforeSend: function() { $link.toggleClass("delete-icon loading-icon"); },
success: function(data) {
if (data.Error !== null) {
window.alert(data.Error);
return;
}
$container.remove();
},
complete: function() { $link.toggleClass("delete-icon loading-icon"); }
});
return false;
});
};
var setupLogin = function() { var setupLogin = function() {
var showLoginForm = function() { var showLoginForm = function() {
var $dialog = $("#login-dialog"); var $dialog = $("#login-dialog");
@ -257,6 +281,7 @@
$(document).ready(function() { $(document).ready(function() {
$.vgquotes.preload([$.vgquotes.loadingGif]); $.vgquotes.preload([$.vgquotes.loadingGif]);
setupFlagLink(); setupFlagLink();
setupDeleteLink();
setupVoting(); setupVoting();
$("body").ajaxError(function(e, xhr, options, error){ $("body").ajaxError(function(e, xhr, options, error){