- The formats for each week in League tab are now clickable to show the details for the format.
This commit is contained in:
@@ -122,6 +122,7 @@ public class LeagueResource extends AbstractResource {
|
||||
serieElem.setAttribute("maxMatches", String.valueOf(serie.getMaxMatches()));
|
||||
serieElem.setAttribute("start", String.valueOf(serie.getStart()));
|
||||
serieElem.setAttribute("end", String.valueOf(serie.getEnd()));
|
||||
serieElem.setAttribute("formatType", serie.getFormat());
|
||||
serieElem.setAttribute("format", _formatLibrary.getFormat(serie.getFormat()).getName());
|
||||
serieElem.setAttribute("collection", serie.getCollectionType().getFullName());
|
||||
serieElem.setAttribute("limited", String.valueOf(serie.isLimited()));
|
||||
|
||||
@@ -38,6 +38,11 @@
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.clickableFormat {
|
||||
cursor: pointer;
|
||||
color: #6f6fff;
|
||||
}
|
||||
|
||||
.pocket {
|
||||
background-color: #000000;
|
||||
border: 1px solid #ffffff;
|
||||
@@ -220,11 +225,11 @@
|
||||
|
||||
var infoDialog = $("<div></div>")
|
||||
.dialog({
|
||||
autoOpen: false,
|
||||
closeOnEscape: true,
|
||||
resizable: false,
|
||||
title: "Card information"
|
||||
});
|
||||
autoOpen: false,
|
||||
closeOnEscape: true,
|
||||
resizable: false,
|
||||
title: "Card information"
|
||||
});
|
||||
|
||||
$("body").click(
|
||||
function (event) {
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
<pre style="font-size:80%">
|
||||
<b>2 Jun. 2012</b>
|
||||
- The drop-downs for deck and format in Game Hall no longer reset periodically.
|
||||
- The formats for each week in League tab are now clickable to show the details for the format.
|
||||
|
||||
<b>30 May 2012</b>
|
||||
- "Pippin, Friend to Frodo" now prevents only Shadow player from discarding Tales, not the FP player, if a Shadow card
|
||||
makes FP player to discard it.
|
||||
|
||||
@@ -470,6 +470,18 @@ var GempLotrCommunication = Class.extend({
|
||||
dataType: "xml"
|
||||
});
|
||||
},
|
||||
getFormat: function(formatCode, callback, errorMap) {
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: this.url + "/hall/format/" + formatCode,
|
||||
cache: false,
|
||||
data: {
|
||||
participantId: getUrlParam("participantId")},
|
||||
success: this.deliveryCheck(callback),
|
||||
error: this.errorCheck(errorMap),
|
||||
dataType: "html"
|
||||
});
|
||||
},
|
||||
getStatus: function(callback, errorMap) {
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
var LeagueResultsUI = Class.extend({
|
||||
communication: null,
|
||||
questionDialog: null,
|
||||
formatDialog: null,
|
||||
|
||||
init: function(url) {
|
||||
this.communication = new GempLotrCommunication(url,
|
||||
@@ -16,6 +17,15 @@ var LeagueResultsUI = Class.extend({
|
||||
title: "League operation"
|
||||
});
|
||||
|
||||
this.formatDialog = $("<div></div>")
|
||||
.dialog({
|
||||
autoOpen: false,
|
||||
closeOnEscape: true,
|
||||
resizable: false,
|
||||
modal: true,
|
||||
title: "Format description"
|
||||
});
|
||||
|
||||
this.loadResults();
|
||||
},
|
||||
|
||||
@@ -99,6 +109,7 @@ var LeagueResultsUI = Class.extend({
|
||||
var serieStart = serie.getAttribute("start");
|
||||
var serieEnd = serie.getAttribute("end");
|
||||
var maxMatches = serie.getAttribute("maxMatches");
|
||||
var formatType = serie.getAttribute("formatType");
|
||||
var format = serie.getAttribute("format");
|
||||
var collection = serie.getAttribute("collection");
|
||||
var limited = serie.getAttribute("limited");
|
||||
@@ -106,7 +117,21 @@ var LeagueResultsUI = Class.extend({
|
||||
var serieText = serieName + " - " + getDateString(serieStart) + " to " + getDateString(serieEnd);
|
||||
$("#leagueExtraInfo").append("<div class='serieName'>" + serieText + "</div>");
|
||||
|
||||
$("#leagueExtraInfo").append("<div><b>Format:</b> " + ((limited == "true") ? "Limited" : "Constructed") + " " + format + "</div>");
|
||||
var formatName = $("<span class='clickableFormat'>" + ((limited == "true") ? "" : "Constructed ") + format + "</span>");
|
||||
var formatDiv = $("<div><b>Format:</b> </div>");
|
||||
formatDiv.append(formatName);
|
||||
formatName.click(
|
||||
(function(ft) {
|
||||
return function() {
|
||||
that.formatDialog.html("");
|
||||
that.formatDialog.dialog("open");
|
||||
that.communication.getFormat(ft,
|
||||
function(html) {
|
||||
that.formatDialog.html(html);
|
||||
});
|
||||
};
|
||||
})(formatType));
|
||||
$("#leagueExtraInfo").append(formatDiv);
|
||||
$("#leagueExtraInfo").append("<div><b>Collection:</b> " + collection + "</div>");
|
||||
|
||||
tabContent.append("<div>Maximum ranked matches in serie: " + maxMatches + "</div>");
|
||||
|
||||
Reference in New Issue
Block a user