Fix migration bug

pull/146/head
johnniang 2019-04-27 00:19:51 +08:00
parent 5adeed87cb
commit b61d24d7bd
3 changed files with 2 additions and 3 deletions

View File

@ -92,7 +92,6 @@ public class Attachment extends BaseEntity {
@Override @Override
public void prePersist() { public void prePersist() {
super.prePersist(); super.prePersist();
id = null;
if (fileKey == null) { if (fileKey == null) {
fileKey = ""; fileKey = "";

View File

@ -440,7 +440,7 @@ public class RecoveryServiceImpl implements RecoveryService {
} }
// Set location // Set location
String attachLocation = attachmentMap.get("attachLocation").toString(); String attachLocation = attachmentMap.getOrDefault("attachLocation", "").toString();
if (StringUtils.equalsIgnoreCase(attachLocation, "qiniu")) { if (StringUtils.equalsIgnoreCase(attachLocation, "qiniu")) {
attachment.setType(AttachmentType.QNYUN); attachment.setType(AttachmentType.QNYUN);
} else if (StringUtils.equalsIgnoreCase(attachLocation, "upyun")) { } else if (StringUtils.equalsIgnoreCase(attachLocation, "upyun")) {

View File

@ -1,7 +1,7 @@
<div class="page-top animated fadeInDown"> <div class="page-top animated fadeInDown">
<div class="nav"> <div class="nav">
<@menuTag method="list"> <@menuTag method="list">
<#list menus?sort_by('sort') as menu> <#list menus?sort_by('priority') as menu>
<li> <li>
<a href="${menu.url}" target="${menu.target!}">${menu.name} </a> <a href="${menu.url}" target="${menu.target!}">${menu.name} </a>
</li> </li>