aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/java
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2016-11-30 16:49:11 +0300
committerGravatar Vitaly Takmazov2016-11-30 16:49:11 +0300
commit1a2830588131173d8fbfeb1fe03c466b4cf30e46 (patch)
tree53889640b356f22e6620acffed0bda1e56babcf6 /juick-www/src/main/java
parentf5fd9c7bea380eb4c0c2d58f2167ad3f07c45c33 (diff)
juick-core: fix attachment serialization
Diffstat (limited to 'juick-www/src/main/java')
-rw-r--r--juick-www/src/main/java/com/juick/www/PageTemplates.java6
-rw-r--r--juick-www/src/main/java/com/juick/www/UserThread.java12
2 files changed, 9 insertions, 9 deletions
diff --git a/juick-www/src/main/java/com/juick/www/PageTemplates.java b/juick-www/src/main/java/com/juick/www/PageTemplates.java
index 74b8b543..180e852f 100644
--- a/juick-www/src/main/java/com/juick/www/PageTemplates.java
+++ b/juick-www/src/main/java/com/juick/www/PageTemplates.java
@@ -329,12 +329,12 @@ public class PageTemplates {
out.println(" <div class=\"msg-tags\">" + tagsStr + "</div>");
out.println(" </header>");
- if (msg.AttachmentType != null) {
- String fname = msg.getMid() + "." + msg.AttachmentType;
+ if (msg.getAttachmentType() != null) {
+ String fname = msg.getMid() + "." + msg.getAttachmentType();
out.println(" <p class=\"ir\"><a href=\"//i.juick.com/photos-512/" + fname + "\" data-fname=\"" + fname + "\"><img src=\"//i.juick.com/photos-512/" + fname + "\" alt=\"\"/></a></p>");
}
out.println(" <p>" + txt + "</p>");
- if (msg.AttachmentType != null) {
+ if (msg.getAttachmentType() != null) {
out.println(" <div class=\"irbr\"></div>");
}
out.print(" <nav class=\"l\">");
diff --git a/juick-www/src/main/java/com/juick/www/UserThread.java b/juick-www/src/main/java/com/juick/www/UserThread.java
index 6355e87e..d94f2156 100644
--- a/juick-www/src/main/java/com/juick/www/UserThread.java
+++ b/juick-www/src/main/java/com/juick/www/UserThread.java
@@ -125,8 +125,8 @@ public class UserThread {
out.println(" <div class=\"msg-header\">@<a href=\"/" + msg.getUser().getName() + "/\">" + msg.getUser().getName() + "</a>:" + tagsStr + "</div>");
out.println(" <div class=\"msg-txt\">" + txt + "</div>");
- if (msg.AttachmentType != null) {
- out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "." + msg.AttachmentType + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "." + msg.AttachmentType + "\" alt=\"\"/></a></div>");
+ if (msg.getAttachmentType() != null) {
+ out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "." + msg.getAttachmentType() + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "." + msg.getAttachmentType() + "\" alt=\"\"/></a></div>");
}
boolean visitorInBL = false;
@@ -292,8 +292,8 @@ public class UserThread {
out.println(" <div class=\"msg-ts\"><a href=\"/" + msg.getMid() + "#" + msg.getRid() + "\" title=\"" + PageTemplates.sdfSQL.format(msg.getDate()) + " GMT\">" + PageTemplates.formatDate(msg.TimeAgo, msg.getDate()) + "</a></div>");
out.println(" </div>");
out.println(" <div class=\"msg-txt\">" + MessageUtils.formatMessage(msg.getText()) + "</div>");
- if (msg.AttachmentType != null) {
- out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "-" + msg.getRid() + "." + msg.AttachmentType + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "-" + msg.getRid() + "." + msg.AttachmentType + "\" alt=\"\"/></a></div>");
+ if (msg.getAttachmentType() != null) {
+ out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "-" + msg.getRid() + "." + msg.getAttachmentType() + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "-" + msg.getRid() + "." + msg.getAttachmentType() + "\" alt=\"\"/></a></div>");
}
out.print(" <div class=\"msg-links\">/" + msg.getRid());
if (msg.getReplyto() > 0) {
@@ -338,8 +338,8 @@ public class UserThread {
out.println(" <div class=\"msg-ts\"><a href=\"/" + msg.getMid() + "#" + msg.getRid() + "\" title=\"" + PageTemplates.sdfSQL.format(msg.getDate()) + " GMT\">" + PageTemplates.formatDate(msg.TimeAgo, msg.getDate()) + "</a></div>");
out.println(" </div>");
out.println(" <div class=\"msg-txt\">" + MessageUtils.formatMessage(msg.getText()) + "</div>");
- if (msg.AttachmentType != null) {
- out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "-" + msg.getRid() + "." + msg.AttachmentType + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "-" + msg.getRid() + "." + msg.AttachmentType + "\" alt=\"\"/></a></div>");
+ if (msg.getAttachmentType() != null) {
+ out.println(" <div class=\"msg-media\"><a href=\"//i.juick.com/p/" + msg.getMid() + "-" + msg.getRid() + "." + msg.getAttachmentType() + "\"><img src=\"//i.juick.com/photos-512/" + msg.getMid() + "-" + msg.getRid() + "." + msg.getAttachmentType() + "\" alt=\"\"/></a></div>");
}
out.print(" <div class=\"msg-links\">/" + msg.getRid());
if (msg.getReplyto() > 0) {