优化 close #I5Q36R 登录接口的Long型属性没有转为string给前端,导致精度丢失,其他接口JacksonConfiguration都生效了

This commit is contained in:
lbw 2022-09-07 23:13:17 +08:00
parent 52dc1d18bf
commit ed5063d930

View File

@ -16,6 +16,8 @@
package com.pig4cloud.pig.common.security.service;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Getter;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.SpringSecurityCoreVersion;
@ -38,12 +40,14 @@ public class PigUser extends User implements OAuth2AuthenticatedPrincipal {
* 用户ID
*/
@Getter
@JsonSerialize(using = ToStringSerializer.class)
private final Long id;
/**
* 部门ID
*/
@Getter
@JsonSerialize(using = ToStringSerializer.class)
private final Long deptId;
/**