|
@@ -1,6 +1,7 @@
|
|
|
package com.persagy.proxy.object.controller;
|
|
|
|
|
|
import cn.hutool.core.collection.CollUtil;
|
|
|
+import cn.hutool.core.date.DateUtil;
|
|
|
import cn.hutool.core.util.StrUtil;
|
|
|
import com.persagy.dmp.common.model.entity.BaseEntity;
|
|
|
import com.persagy.proxy.adm.request.AdmCreateRequest;
|
|
@@ -54,6 +55,11 @@ public class AdmBuildingController {
|
|
|
if (StrUtil.isEmpty(admBuilding.getName())){
|
|
|
admBuilding.setName(ObjectNameUtil.objectName("建筑-"));
|
|
|
}
|
|
|
+ if(CollUtil.isNotEmpty(admBuilding.getInfos())){
|
|
|
+ if(admBuilding.getInfos().get("buildAge") != null){
|
|
|
+ admBuilding.getInfos().put("buildAge", DateUtil.format(DateUtil.parseDate(admBuilding.getInfos().get("buildAge").toString()),"yyyy"));
|
|
|
+ }
|
|
|
+ }
|
|
|
});
|
|
|
vos = service.doInsert(AdmContextUtil.toDmpContext(), AdmBuilding.class, vos);
|
|
|
return AdmResponse.success(vos);
|