diff --git a/conf/application.xml b/conf/application.xml index f3f05e0..fd6fff5 100644 --- a/conf/application.xml +++ b/conf/application.xml @@ -5,6 +5,9 @@ + + + diff --git a/lib/readme.md b/lib/readme.md deleted file mode 100644 index e69de29..0000000 diff --git a/lib/redkale-plugins.jar b/lib/redkale-plugins.jar index d4dc568..49cf84f 100644 Binary files a/lib/redkale-plugins.jar and b/lib/redkale-plugins.jar differ diff --git a/lib/redkale.jar b/lib/redkale.jar index 4a0f535..d6ba695 100644 Binary files a/lib/redkale.jar and b/lib/redkale.jar differ diff --git a/libs/readme.md b/libs/readme.md deleted file mode 100644 index e69de29..0000000 diff --git a/root/article/index.html b/root/article/index.html new file mode 100644 index 0000000..9a138c9 --- /dev/null +++ b/root/article/index.html @@ -0,0 +1,96 @@ + + +#@layout() +#define css() + +#end + +#define main() +
+ +
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+
+

这里是一个标题这里是一个标题这里是一个标题

+
+ 这里是内容摘要,这里是内容摘要,这里是内容摘要,这里是内容摘要, +
+
+
+
+ +
+ 你的内容 3/12 +
+
+ +
+ +#end \ No newline at end of file diff --git a/root/res/css/global.css b/root/res/css/global.css index 465079b..00faef1 100644 --- a/root/res/css/global.css +++ b/root/res/css/global.css @@ -561,4 +561,5 @@ body .fly-user-main{position: relative; min-height: 600px;} .site-mobile .site-mobile-shade{content: ''; position: fixed; top: 0; bottom: 0; left: 0; right: 0; background-color: rgba(0,0,0,.9); z-index: 999;} } -.layui-form-select dl{z-index: 10002;} \ No newline at end of file +.layui-form-select dl{z-index: 10002;} +.at_user{color: #1e9fff;} \ No newline at end of file diff --git a/root/res/mods/jie.js b/root/res/mods/jie.js index ea95c40..46d5b06 100644 --- a/root/res/mods/jie.js +++ b/root/res/mods/jie.js @@ -156,12 +156,14 @@ layui.define(['fly','laypage'], function(exports){ }); } ,reply: function(li){ //回复 - var val = dom.content.val(); - var aite = '@'+ li.find('.fly-detail-user cite').text().replace(/\s/g, ''); - dom.content.focus() - if(val.indexOf(aite) !== -1) return; - dom.content.val(aite +' ' + val); + //var val = dom.content.val(); + var aite = '@'+ li.find('.fly-detail-user cite').text().replace(/\s/g, '') + ' '; + //dom.content.focus() + //if(val.indexOf(aite) !== -1) return; + //dom.content.val(aite +' ' + val); $("input[name='pid']").val(li.data('id')); + editor.cmd.do('insertHTML', "

"+aite+"

"); + //editor.txt.append(); } ,accept: function(li){ //采纳 var othis = $(this); diff --git a/src/com/lxyer/bbs/comment/CommentService.java b/src/com/lxyer/bbs/comment/CommentService.java index 1d689de..ca76b96 100644 --- a/src/com/lxyer/bbs/comment/CommentService.java +++ b/src/com/lxyer/bbs/comment/CommentService.java @@ -36,13 +36,20 @@ public class CommentService extends BaseService { public RetResult commentSave(@RestSessionid String sessionid, @RestParam(name = "bean") Comment comment){ int contentId = comment.getContentId(); - if (contentId < 1) return RetCodes.retResult(RET_COMMENT_PARA_ILLEGAL, "评论参数无效"); - if (comment.getContent() == null) return RetCodes.retResult(RET_COMMENT_CONTENT_ILLEGAL, "评论内容无效"); + //数据校验 + if (contentId < 1) + return RetCodes.retResult(RET_COMMENT_PARA_ILLEGAL, "评论参数无效"); + if (comment.getContent() == null) + return RetCodes.retResult(RET_COMMENT_CONTENT_ILLEGAL, "评论内容无效"); + String content = LxyKit.delHTMLTag(comment.getContent()); + if (content.isEmpty()) + return RetCodes.retResult(RET_COMMENT_CONTENT_ILLEGAL, "评论内容无效"); if (comment.getCommentId() < 1) { int userId = userService.currentUserId(sessionid); comment.setUserId(userId); comment.setCreateTime(System.currentTimeMillis()); + //todo:@用户处理 source.insert(comment); //update replyNum