@@ -0,0 +1,34 @@ | |||||
package com.ningdatech.pmapi.common.config; | |||||
import com.fasterxml.jackson.databind.ObjectMapper; | |||||
import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule; | |||||
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer; | |||||
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer; | |||||
import org.springframework.beans.factory.annotation.Value; | |||||
import org.springframework.context.annotation.Bean; | |||||
import org.springframework.context.annotation.Configuration; | |||||
import java.time.LocalDateTime; | |||||
import java.time.format.DateTimeFormatter; | |||||
/** | |||||
* @author liuxinxin | |||||
* @date 2023/3/9 下午1:50 | |||||
*/ | |||||
@Configuration | |||||
public class JacksonConfig { | |||||
@Value("${spring.jackson.local-date-time-format:yyyy-MM-dd HH:mm:ss}") | |||||
String localDateTimeFormat; | |||||
@Bean | |||||
public ObjectMapper objectMapper() { | |||||
ObjectMapper om = new ObjectMapper(); | |||||
JavaTimeModule javaTimeModule = new JavaTimeModule(); | |||||
javaTimeModule.addSerializer(LocalDateTime.class, | |||||
new LocalDateTimeSerializer(DateTimeFormatter.ofPattern(localDateTimeFormat))); | |||||
javaTimeModule.addDeserializer(LocalDateTime.class, | |||||
new LocalDateTimeDeserializer(DateTimeFormatter.ofPattern(localDateTimeFormat))); | |||||
return om; | |||||
} | |||||
} |
@@ -85,10 +85,11 @@ public class ExpertManage { | |||||
expertInfoService.saveExpertInfo(expertFullInfoSaveCmd); | expertInfoService.saveExpertInfo(expertFullInfoSaveCmd); | ||||
} | } | ||||
ExpertRecommendInfo recommendInfo = request.getRecommendInfo(); | |||||
// 推荐证明材料 | // 推荐证明材料 | ||||
List<DictionaryFieldInfo> recommendedWay = request.getRecommendedWay(); | |||||
List<DictionaryFieldInfo> recommendedWay = recommendInfo.getRecommendedWay(); | |||||
// 推荐方式 | // 推荐方式 | ||||
List<FileBasicInfo> recommendProofFile = request.getRecommendProofFile(); | |||||
List<FileBasicInfo> recommendProofFile = recommendInfo.getRecommendationProofFile(); | |||||
expertRecommendProofSubmit(recommendedWay, recommendProofFile); | expertRecommendProofSubmit(recommendedWay, recommendProofFile); | ||||
} | } | ||||
@@ -1,14 +1,11 @@ | |||||
package com.ningdatech.pmapi.expert.model.req; | package com.ningdatech.pmapi.expert.model.req; | ||||
import com.ningdatech.pmapi.common.model.FileBasicInfo; | |||||
import com.ningdatech.pmapi.expert.model.*; | import com.ningdatech.pmapi.expert.model.*; | ||||
import io.swagger.annotations.ApiModel; | import io.swagger.annotations.ApiModel; | ||||
import io.swagger.annotations.ApiModelProperty; | import io.swagger.annotations.ApiModelProperty; | ||||
import lombok.Data; | import lombok.Data; | ||||
import javax.validation.constraints.NotEmpty; | |||||
import javax.validation.constraints.NotNull; | import javax.validation.constraints.NotNull; | ||||
import java.util.List; | |||||
/** | /** | ||||
* @author liuxinxin | * @author liuxinxin | ||||
@@ -37,15 +34,8 @@ public class ExpertUserBasicInfoSubmitRequest { | |||||
/** | /** | ||||
* 补充推荐方式 | * 补充推荐方式 | ||||
*/ | */ | ||||
@NotEmpty | |||||
@ApiModelProperty("推荐方式") | |||||
private List<DictionaryFieldInfo> recommendedWay; | |||||
@ApiModelProperty("推荐证明材料") | |||||
private List<FileBasicInfo> recommendProofFile; | |||||
/** | |||||
* 其他信息 | |||||
*/ | |||||
@NotNull | |||||
@ApiModelProperty("推荐信息") | |||||
private ExpertRecommendInfo recommendInfo; | |||||
} | } |
@@ -192,4 +192,4 @@ provincial: | |||||
pushUrl: /api/v1/foreign/importantPro | pushUrl: /api/v1/foreign/importantPro | ||||
detailUrl: /api/v1/foreign/importantProView | detailUrl: /api/v1/foreign/importantProView | ||||
key: 7196317343a64e67895dc0375c098fe7 | key: 7196317343a64e67895dc0375c098fe7 | ||||
secret: 75152a97f20e4c4c854dc6301cf72ad4 | |||||
secret: 75152a97f20e4c4c854dc6301cf72ad4 |