﻿/// <reference path="~/js/jquery-1.3.2.js" />
function boxToggle() {
    var boxclass = $("div.panel");
    var boxHead = boxclass.children("div");
    var toggleLink = $('<a href="#" class="compresslink"></a>');
    toggleLink.insertAfter(boxHead.children("span"));
    var allLink = $(".compresslink");
    allLink.toggle(
				function() {
				    $(this).text("(Click Here To Collapse)");
				    $(this).parent("div").parent("div").children("table").show("slow");
				},
				function() {
				    $(this).text("(Click Here To Expand)");
				    $(this).parent("div").parent("div").children("table").hide("slow");
				}

			);
    allLink.text("(Click Here To Expand)");
    allLink.parent("div").parent("div").children("table").hide();
}
$(document).ready(function() { boxToggle(); });