mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
ALF-11844 WikiService needs to set the mimetype of html on the content property created through it
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@32869 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -33,6 +33,7 @@ import org.alfresco.query.CannedQuerySortDetails;
|
||||
import org.alfresco.query.EmptyPagingResults;
|
||||
import org.alfresco.query.PagingRequest;
|
||||
import org.alfresco.query.PagingResults;
|
||||
import org.alfresco.repo.content.MimetypeMap;
|
||||
import org.alfresco.repo.domain.node.NodeDAO;
|
||||
import org.alfresco.repo.node.getchildren.GetChildrenAuditableCannedQuery;
|
||||
import org.alfresco.repo.node.getchildren.GetChildrenAuditableCannedQueryFactory;
|
||||
@@ -224,6 +225,7 @@ public class WikiServiceImpl implements WikiService
|
||||
|
||||
// Store the content
|
||||
ContentWriter writer = contentService.getWriter(nodeRef, ContentModel.PROP_CONTENT, true);
|
||||
writer.setMimetype(MimetypeMap.MIMETYPE_HTML);
|
||||
writer.setEncoding("UTF-8");
|
||||
writer.putContent(content);
|
||||
|
||||
@@ -263,6 +265,7 @@ public class WikiServiceImpl implements WikiService
|
||||
|
||||
// Change the content
|
||||
ContentWriter writer = contentService.getWriter(nodeRef, ContentModel.PROP_CONTENT, true);
|
||||
writer.setMimetype(MimetypeMap.MIMETYPE_HTML);
|
||||
writer.setEncoding("UTF-8");
|
||||
writer.putContent(page.getContents());
|
||||
|
||||
|
Reference in New Issue
Block a user