Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
solo
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
solo
Commits
af2a5828
Commit
af2a5828
authored
Jun 28, 2016
by
Liang Ding
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
EH - 历史评论数据 MD 解析
parent
ec511c6f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
src/main/java/org/b3log/solo/service/CommentQueryService.java
...main/java/org/b3log/solo/service/CommentQueryService.java
+4
-1
No files found.
src/main/java/org/b3log/solo/service/CommentQueryService.java
View file @
af2a5828
...
@@ -40,6 +40,7 @@ import org.b3log.solo.repository.ArticleRepository;
...
@@ -40,6 +40,7 @@ import org.b3log.solo.repository.ArticleRepository;
import
org.b3log.solo.repository.CommentRepository
;
import
org.b3log.solo.repository.CommentRepository
;
import
org.b3log.solo.repository.PageRepository
;
import
org.b3log.solo.repository.PageRepository
;
import
org.b3log.solo.util.Emotions
;
import
org.b3log.solo.util.Emotions
;
import
org.b3log.solo.util.Markdowns
;
import
org.b3log.solo.util.Thumbnails
;
import
org.b3log.solo.util.Thumbnails
;
import
org.json.JSONArray
;
import
org.json.JSONArray
;
import
org.json.JSONObject
;
import
org.json.JSONObject
;
...
@@ -48,7 +49,7 @@ import org.json.JSONObject;
...
@@ -48,7 +49,7 @@ import org.json.JSONObject;
* Comment query service.
* Comment query service.
*
*
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.
2.0.8, May 10
, 2016
* @version 1.
3.0.8, Jun 28
, 2016
* @since 0.3.5
* @since 0.3.5
*/
*/
@Service
@Service
...
@@ -193,6 +194,7 @@ public class CommentQueryService {
...
@@ -193,6 +194,7 @@ public class CommentQueryService {
String
commentContent
=
comment
.
optString
(
Comment
.
COMMENT_CONTENT
);
String
commentContent
=
comment
.
optString
(
Comment
.
COMMENT_CONTENT
);
commentContent
=
Emotions
.
convert
(
commentContent
);
commentContent
=
Emotions
.
convert
(
commentContent
);
commentContent
=
Markdowns
.
toHTML
(
commentContent
);
comment
.
put
(
Comment
.
COMMENT_CONTENT
,
commentContent
);
comment
.
put
(
Comment
.
COMMENT_CONTENT
,
commentContent
);
comment
.
put
(
Comment
.
COMMENT_TIME
,
((
Date
)
comment
.
get
(
Comment
.
COMMENT_DATE
)).
getTime
());
comment
.
put
(
Comment
.
COMMENT_TIME
,
((
Date
)
comment
.
get
(
Comment
.
COMMENT_DATE
)).
getTime
());
...
@@ -251,6 +253,7 @@ public class CommentQueryService {
...
@@ -251,6 +253,7 @@ public class CommentQueryService {
String
commentContent
=
comment
.
optString
(
Comment
.
COMMENT_CONTENT
);
String
commentContent
=
comment
.
optString
(
Comment
.
COMMENT_CONTENT
);
commentContent
=
Emotions
.
convert
(
commentContent
);
commentContent
=
Emotions
.
convert
(
commentContent
);
commentContent
=
Markdowns
.
toHTML
(
commentContent
);
comment
.
put
(
Comment
.
COMMENT_CONTENT
,
commentContent
);
comment
.
put
(
Comment
.
COMMENT_CONTENT
,
commentContent
);
ret
.
add
(
comment
);
ret
.
add
(
comment
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment