提交article
This commit is contained in:
parent
cb35f53414
commit
1a7c7f2225
@ -59,7 +59,7 @@ public class ArticleTag implements IParse {
|
||||
}
|
||||
cc.iteachyou.cms.entity.System system = systemService.getSystem();
|
||||
String newHtml = html;
|
||||
|
||||
Archives archives = archivesService.selectByPrimaryKey(id);
|
||||
Attribute[] attributes = annotations.attributes();
|
||||
for (String string : all) {
|
||||
Map<String, Object> entity = new HashMap<String, Object>();
|
||||
@ -75,7 +75,7 @@ public class ArticleTag implements IParse {
|
||||
entity.put(key, value);
|
||||
}
|
||||
|
||||
Archives archives = archivesService.selectByPrimaryKey(id);
|
||||
|
||||
String formId = formService.queryDefaultForm().getId();
|
||||
Category category = null;
|
||||
if (!"-1".equals(archives.getCategoryId())) {
|
||||
@ -146,32 +146,35 @@ public class ArticleTag implements IParse {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("createUserName")) ? "" : archivesVo.get("createUserName").toString());
|
||||
} else if (FieldEnum.FIELD_CREATEREALNAME.getField().equalsIgnoreCase(name)) {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("createRealName")) ? "" : archivesVo.get("createRealName").toString());
|
||||
} else if (FieldEnum.FIELD_CREATETIME.getField().equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("createTime")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("createTime")) ? "" : archivesVo.get("createTime").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_UPDATEBY.getField().equalsIgnoreCase(name)) {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("updateBy")) ? "" : archivesVo.get("updateBy").toString());
|
||||
} else if (FieldEnum.FIELD_UPDATETIME.getField().equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("updateTime")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("updateTime")) ? "" : archivesVo.get("updateTime").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_SHOWTIME.getField().equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("show_time")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("show_time")) ? "" : archivesVo.get("show_time").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_ARCURL.getField().equalsIgnoreCase(name)) {
|
||||
newHtml = newHtml.replace(string, "/article/" + archivesVo.get("aid").toString());
|
||||
} else {
|
||||
//处理附加字段
|
||||
if (archivesVo.containsKey(name))
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get(name)) ? "" : archivesVo.get(name).toString());
|
||||
String field = FieldEnum.FIELD_CREATETIME.getField();
|
||||
if (field.equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("createTime")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("createTime")) ? "" : archivesVo.get("createTime").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_UPDATEBY.getField().equalsIgnoreCase(name)) {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("updateBy")) ? "" : archivesVo.get("updateBy").toString());
|
||||
} else if (FieldEnum.FIELD_UPDATETIME.getField().equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("updateTime")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("updateTime")) ? "" : archivesVo.get("updateTime").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_SHOWTIME.getField().equalsIgnoreCase(name)) {
|
||||
if (StringUtil.isNotBlank(function)) {
|
||||
newHtml = newHtml.replace(string, FunctionUtil.replaceByFunction(function, archivesVo.get("show_time")));
|
||||
} else {
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get("show_time")) ? "" : archivesVo.get("show_time").toString());
|
||||
}
|
||||
} else if (FieldEnum.FIELD_ARCURL.getField().equalsIgnoreCase(name)) {
|
||||
newHtml = newHtml.replace(string, "/article/" + archivesVo.get("aid").toString());
|
||||
} else {
|
||||
//处理附加字段
|
||||
if (archivesVo.containsKey(name))
|
||||
newHtml = newHtml.replace(string, StringUtil.isBlank(archivesVo.get(name)) ? "" : archivesVo.get(name).toString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user