mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 20:58:03 +00:00
Proxy generator creates cardlist. Still needs work.
This commit is contained in:
@@ -658,13 +658,20 @@ public class DeckManager {
|
||||
root.put("title", d.getName());
|
||||
List<String> list = new ArrayList<String>();
|
||||
for (Card card : d.getMain().toForgeCardList().toArray()) {
|
||||
//System.out.println(card.getSets().get(0).URL);
|
||||
list.add(card.getSets().get(0).URL);
|
||||
//System.out.println(card.getSets().get(card.getSets().size() - 1).URL);
|
||||
list.add(card.getSets().get(card.getSets().size() - 1).URL);
|
||||
}
|
||||
List<String> nameList = new ArrayList<String>();
|
||||
for (Card card : d.getMain().toForgeCardList().toArray()) {
|
||||
//System.out.println(card.getSets().get(card.getSets().size() - 1).URL);
|
||||
nameList.add(card.getName());
|
||||
}
|
||||
root.put("urls", list);
|
||||
root.put("cardBorder", cardBorder);
|
||||
root.put("height", height);
|
||||
root.put("width", width);
|
||||
root.put("cardlistWidth", width - 11);
|
||||
root.put("nameList", nameList);
|
||||
|
||||
/* Merge data-model with template */
|
||||
//StringWriter sw = new StringWriter();
|
||||
|
||||
@@ -18,13 +18,14 @@
|
||||
<img src="${url}" height="${height}" width="${width}" style="margin: 0 ${cardBorder}px ${cardBorder}px 0;">
|
||||
</#list>
|
||||
<br>
|
||||
<table title="Spirited Away" style="font-size:10px;" border=1 cellpadding="5" cellspacing="1">
|
||||
<table style="font-size:10px;" border=1 cellpadding="5" cellspacing="1">
|
||||
<tr>
|
||||
<td width="211">
|
||||
</td>
|
||||
<td width="211">
|
||||
<td width="${cardlistWidth}">
|
||||
<#list nameList as name>
|
||||
${name}<br>
|
||||
</#list>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user