aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/NewMessage.java2
-rw-r--r--juick-www/src/main/webapp/WEB-INF/views/post.html2
2 files changed, 3 insertions, 1 deletions
diff --git a/juick-www/src/main/java/com/juick/www/controllers/NewMessage.java b/juick-www/src/main/java/com/juick/www/controllers/NewMessage.java
index ea81b5e0..5a73d983 100644
--- a/juick-www/src/main/java/com/juick/www/controllers/NewMessage.java
+++ b/juick-www/src/main/java/com/juick/www/controllers/NewMessage.java
@@ -392,7 +392,7 @@ public class NewMessage {
}
}
@PostMapping("/post2")
- public String doPostMessage(@RequestParam(name = "body") String bodyParam,
+ public String doPostMessage(@RequestParam(name = "body", required = false) String bodyParam,
@RequestParam(required = false) String img,
@RequestParam(required = false) String referer,
@RequestParam(required = false) MultipartFile attach) throws IOException {
diff --git a/juick-www/src/main/webapp/WEB-INF/views/post.html b/juick-www/src/main/webapp/WEB-INF/views/post.html
index ac179e92..e961329c 100644
--- a/juick-www/src/main/webapp/WEB-INF/views/post.html
+++ b/juick-www/src/main/webapp/WEB-INF/views/post.html
@@ -1,6 +1,7 @@
{% extends "layouts/content" %}
{% import "views/macros/tags" %}
{% block content %}
+<article>
<form action="/post2" method="post" id="postmsg" enctype="multipart/form-data">
<p style="text-align: left">
<b>Фото:</b> <span id="attachmentfile">
@@ -12,6 +13,7 @@
<input type="submit" class="subm" value=" {{ i18n("messages","postForm.submit") }} "/>
</p>
</form>
+</article>
<p style="text-align: left"><b>Теги:</b></p>
{{ tags(visitor.name, tags) }}
{% endblock %}