NutzCN Logo
问答 存入bean对象时出现报错
发布于 2131天前 作者 木易 2151 次浏览 复制 上一个帖子 下一个帖子
标签:

我存入bean对象时出现错误
下面是代码

    @At
    @Ok("json")
    @POST
    public Object regDo(@Param("..") Cai_com_manager_view in, HttpSession session) {
        /**  字段过滤器  **/
        Cai_com_manager_view fifterResult = managerUtils.fieldFifter(in, CompanyManagerUtils.Event.REG);
        System.err.println("[类名:ManagerUserController]\t-->[方法名:regDo]\t-->[代码行数:96]-->打印值:" + fifterResult);
        if (fifterResult == null) {
            return Result.error(3, "请求错误");
        }

        Cai_company regCompany = managerUtils.getEntity(Cai_company.class, fifterResult);
        Cai_company_info regCompanyInfo = managerUtils.getEntity(Cai_company_info.class, fifterResult);
        Sys_user regUser = managerUtils.getEntity(Sys_user.class, fifterResult);
        System.err.println("[类名:ManagerUserController]\t-->[方法名:regDo]\t-->[代码行数:104]-->打印值:" + regUser);
        sysUserService.insert(regUser);

下面是打印信息

[类名:ManagerUserController]	-->[方法名:regDo]	-->[代码行数:96]-->打印值:Cai_com_manager_view(companyId=null, companyName=布布子的酷酷屋, companyLogo=null, managerId=null, userName=yzw_caibao, contact=yzw, mobile=16765963216, mainBusiness=null, email=12365498497, address=null, pwd=123456a, legalPerson=yzw, license=1231213131, aptitude=null, honor=null, regAddress=null, partner=null, num=12326565566456465)
[类名:ManagerUserController]	-->[方法名:regDo]	-->[代码行数:104]-->打印值:Sys_user(id=null, loginname=yzw_caibao, password=d76df8000000, salt=null, username=null, avatar=null, sex=null, location=null, wechat=null, weibo=null, qq=null, wechatStr=null, weiboStr=null, qqStr=null, type=10, userOnline=false, disabled=false, email=null, mobile=null, loginAt=null, loginIp=null, loginCount=-1, loginSessionId=null, customMenu=null, loginTheme=null, loginSidebar=false, loginBoxed=false, loginScroll=false, loginPjax=false, unitid=null, unit=null, roles=null, units=null, addresses=null, collections=null, samples=null, storages=null, card=null, menus=null, firstMenus=null, secondMenus=null, customMenus=null)
[DEBUG] 15:17:35.432 cn.wizzer.app.web.commons.processor.LogTimeProcessor.process(LogTimeProcessor.java:26) - [POST]URI=/manager/regDo 14002ms
[WARN ] 15:17:35.433 cn.wizzer.app.web.commons.processor.WkFailProcessor.process(WkFailProcessor.java:28) - Error@/manager/regDo :
com.alibaba.dubbo.rpc.RpcException: Failed to invoke the method insert in the service cn.wizzer.app.sys.modules.services.SysUserService. Tried 1 times of the providers [192.168.10.34:20880] (1/1) from the registry 127.0.0.1:2181 on the consumer 192.168.10.34 using the dubbo version 2.6.5. Last error is: Failed to invoke remote method: insert, provider: dubbo://192.168.10.34:20880/cn.wizzer.app.sys.modules.services.SysUserService?anyhost=true&application=wk-nb-web-platform&check=false&default.retries=0&default.timeout=300000&dubbo=2.0.2&generic=false&interface=cn.wizzer.app.sys.modules.services.SysUserService&methods=updateWithVersion,data,insertRelation,hasChildren,insertWith,fillMenu,insertOrUpdate,dao,getRoleMenus,getDatas,getMaxId,getSubPath,query,count,getField,vDelete,list,execute,fetchx,getMenusAndButtons,getMap,updateAndIncrIfMatch,updateLinks,getEntityClass,fetchLinks,updateRelation,fastInsert,deleteById,update,insert,insertLinks,getParentPath,delete,loginUser,updateIgnoreNull,listPageLinks,clear,getEntity,fieldUpdate,updateWith,fetch,exists,getRoleCodeList,deleteByIds,listPage&pid=112380&register.ip=192.168.10.34&remote.timestamp=1550731283800&side=consumer&timestamp=1550733427155, cause: Failed to send message Request [id=4, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=insert, parameterTypes=[class java.lang.Object], arguments=[Sys_user(id=null, loginname=yzw_caibao, password=d76df8000000, salt=null, username=null, avatar=null, sex=null, location=null, wechat=null, weibo=null, qq=null, wechatStr=null, weiboStr=null, qqStr=null, type=10, userOnline=false, disabled=false, email=null, mobile=null, loginAt=null, loginIp=null, loginCount=-1, loginSessionId=null, customMenu=null, loginTheme=null, loginSidebar=false, loginBoxed=false, loginScroll=false, loginPjax=false, unitid=null, unit=null, roles=null, units=null, addresses=null, collections=null, samples=null, storages=null, card=null, menus=null, firstMenus=null, secondMenus=null, customMenus=null)], attachments={path=cn.wizzer.app.sys.modules.services.SysUserService, interface=cn.wizzer.app.sys.modules.services.SysUserService, version=0.0.0, timeout=300000}]] to /192.168.10.34:20880, cause: Serialized class java.lang.reflect.Method must implement java.io.Serializable
 Java field: private final java.util.Map cn.wizzer.app.web.commons.utils.CompanyManagerUtils.methodMap
 Java field: final cn.wizzer.app.web.commons.utils.CompanyManagerUtils cn.wizzer.app.web.commons.utils.CompanyManagerUtils$3.this$0
	at com.alibaba.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:109)
	at com.alibaba.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:244)
	at com.alibaba.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:75)
	at com.alibaba.dubbo.rpc.proxy.InvokerInvocationHandler.invoke(InvokerInvocationHandler.java:52)
	at com.alibaba.dubbo.common.bytecode.proxy0.insert(proxy0.java)
	at cn.wizzer.app.web.modules.controllers.platform.cai.CompanyManager.ManagerUserController.regDo(ManagerUserController.java:105)
	at cn.wizzer.app.web.modules.controllers.platform.cai.CompanyManager.ManagerUserController$FM$regDo$29ede8678888a77136e08f24ffdc7f9f.invoke(ManagerUserController.java)
	at org.nutz.mvc.impl.processor.MethodInvokeProcessor.process(MethodInvokeProcessor.java:31)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at org.nutz.mvc.impl.processor.AdaptorProcessor.process(AdaptorProcessor.java:38)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at org.nutz.mvc.impl.processor.ActionFiltersProcessor.process(ActionFiltersProcessor.java:58)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at cn.wizzer.app.web.commons.processor.XssSqlFilterProcessor.process(XssSqlFilterProcessor.java:35)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at cn.wizzer.app.web.commons.processor.NutShiroProcessor.process(NutShiroProcessor.java:52)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at org.nutz.mvc.impl.processor.ModuleProcessor.process(ModuleProcessor.java:123)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at org.nutz.mvc.impl.processor.EncodingProcessor.process(EncodingProcessor.java:27)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at org.nutz.mvc.impl.processor.UpdateRequestAttributesProcessor.process(UpdateRequestAttributesProcessor.java:15)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at cn.wizzer.app.web.commons.processor.GlobalsSettingProcessor.process(GlobalsSettingProcessor.java:49)
	at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcessor.java:44)
	at cn.wizzer.app.web.commons.processor.LogTimeProcessor.process(LogTimeProcessor.java:21)
	at org.nutz.mvc.impl.NutActionChain.doChain(NutActionChain.java:44)
	at org.nutz.mvc.impl.ActionInvoker.invoke(ActionInvoker.java:67)
	at org.nutz.mvc.ActionHandler.handle(ActionHandler.java:31)
	at org.nutz.mvc.NutFilter.doFilter(NutFilter.java:202)
	at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1610)
	at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61)
	at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)
	at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)
	at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)
	at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)
	at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449)
	at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365)
	at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)
	at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)
	at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:383)
	at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362)
	at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)
	at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1610)
	at cn.wizzer.app.web.commons.filter.RouteFilter.doFilter(RouteFilter.java:31)
	at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1610)
	at org.nutz.mvc.WhaleFilter.doFilter(WhaleFilter.java:171)
	at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1602)
	at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:214)
	at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1610)
	at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:540)
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:146)
	at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548)
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)
	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:257)
	at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1588)
	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255)
	at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1345)
	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203)
	at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:480)
	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1557)
	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201)
	at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1247)
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144)
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)
	at org.eclipse.jetty.server.Server.handle(Server.java:502)
	at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:364)
	at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:260)
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:305)
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
	at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:765)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:683)
	at java.lang.Thread.run(Thread.java:748)
Caused by: com.alibaba.dubbo.remoting.RemotingException: Failed to send message Request [id=4, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=insert, parameterTypes=[class java.lang.Object], arguments=[Sys_user(id=null, loginname=yzw_caibao, password=d76df8000000, salt=null, username=null, avatar=null, sex=null, location=null, wechat=null, weibo=null, qq=null, wechatStr=null, weiboStr=null, qqStr=null, type=10, userOnline=false, disabled=false, email=null, mobile=null, loginAt=null, loginIp=null, loginCount=-1, loginSessionId=null, customMenu=null, loginTheme=null, loginSidebar=false, loginBoxed=false, loginScroll=false, loginPjax=false, unitid=null, unit=null, roles=null, units=null, addresses=null, collections=null, samples=null, storages=null, card=null, menus=null, firstMenus=null, secondMenus=null, customMenus=null)], attachments={path=cn.wizzer.app.sys.modules.services.SysUserService, interface=cn.wizzer.app.sys.modules.services.SysUserService, version=0.0.0, timeout=300000}]] to /192.168.10.34:20880, cause: Serialized class java.lang.reflect.Method must implement java.io.Serializable
 Java field: private final java.util.Map cn.wizzer.app.web.commons.utils.CompanyManagerUtils.methodMap
 Java field: final cn.wizzer.app.web.commons.utils.CompanyManagerUtils cn.wizzer.app.web.commons.utils.CompanyManagerUtils$3.this$0
	at com.alibaba.dubbo.remoting.transport.netty.NettyChannel.send(NettyChannel.java:110)
	at com.alibaba.dubbo.remoting.transport.AbstractClient.send(AbstractClient.java:265)
	at com.alibaba.dubbo.remoting.transport.AbstractPeer.send(AbstractPeer.java:53)
	at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeChannel.request(HeaderExchangeChannel.java:116)
	at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeClient.request(HeaderExchangeClient.java:90)
	at com.alibaba.dubbo.rpc.protocol.dubbo.ReferenceCountExchangeClient.request(ReferenceCountExchangeClient.java:83)
	at com.alibaba.dubbo.rpc.protocol.dubbo.DubboInvoker.doInvoke(DubboInvoker.java:95)
	at com.alibaba.dubbo.rpc.protocol.AbstractInvoker.invoke(AbstractInvoker.java:155)
	at com.alibaba.dubbo.rpc.listener.ListenerInvokerWrapper.invoke(ListenerInvokerWrapper.java:77)
	at com.alibaba.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java:75)
	at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:72)
	at com.alibaba.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:54)
	at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:72)
	at com.alibaba.dubbo.rpc.filter.ConsumerContextFilter.invoke(ConsumerContextFilter.java:49)
	at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:72)
	at com.alibaba.dubbo.rpc.protocol.InvokerWrapper.invoke(InvokerWrapper.java:56)
	at com.alibaba.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:78)
	... 73 more
Caused by: java.lang.RuntimeException: Serialized class java.lang.reflect.Method must implement java.io.Serializable
 Java field: private final java.util.Map cn.wizzer.app.web.commons.utils.CompanyManagerUtils.methodMap
 Java field: final cn.wizzer.app.web.commons.utils.CompanyManagerUtils cn.wizzer.app.web.commons.utils.CompanyManagerUtils$3.this$0
	at com.alibaba.com.caucho.hessian.io.JavaSerializer$FieldSerializer.serialize(JavaSerializer.java:304)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer.writeInstance(JavaSerializer.java:284)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer.writeObject(JavaSerializer.java:251)
	at com.alibaba.com.caucho.hessian.io.Hessian2Output.writeObject(Hessian2Output.java:391)
	at com.alibaba.dubbo.common.serialize.hessian2.Hessian2ObjectOutput.writeObject(Hessian2ObjectOutput.java:88)
	at com.alibaba.dubbo.rpc.protocol.dubbo.DubboCodec.encodeRequestData(DubboCodec.java:183)
	at com.alibaba.dubbo.remoting.exchange.codec.ExchangeCodec.encodeRequest(ExchangeCodec.java:235)
	at com.alibaba.dubbo.remoting.exchange.codec.ExchangeCodec.encode(ExchangeCodec.java:72)
	at com.alibaba.dubbo.rpc.protocol.dubbo.DubboCountCodec.encode(DubboCountCodec.java:38)
	at com.alibaba.dubbo.remoting.transport.netty.NettyCodecAdapter$InternalEncoder.encode(NettyCodecAdapter.java:80)
	at org.jboss.netty.handler.codec.oneone.OneToOneEncoder.handleDownstream(OneToOneEncoder.java:66)
	at com.alibaba.dubbo.remoting.transport.netty.NettyHandler.writeRequested(NettyHandler.java:98)
	at org.jboss.netty.channel.Channels.write(Channels.java:611)
	at org.jboss.netty.channel.Channels.write(Channels.java:578)
	at org.jboss.netty.channel.AbstractChannel.write(AbstractChannel.java:251)
	at com.alibaba.dubbo.remoting.transport.netty.NettyChannel.send(NettyChannel.java:100)
	... 89 more
Caused by: java.lang.RuntimeException: Serialized class java.lang.reflect.Method must implement java.io.Serializable
 Java field: private final java.util.Map cn.wizzer.app.web.commons.utils.CompanyManagerUtils.methodMap
	at com.alibaba.com.caucho.hessian.io.JavaSerializer$FieldSerializer.serialize(JavaSerializer.java:304)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer.writeInstance(JavaSerializer.java:284)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer.writeObject(JavaSerializer.java:251)
	at com.alibaba.com.caucho.hessian.io.Hessian2Output.writeObject(Hessian2Output.java:391)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer$FieldSerializer.serialize(JavaSerializer.java:302)
	... 104 more
Caused by: java.lang.IllegalStateException: Serialized class java.lang.reflect.Method must implement java.io.Serializable
	at com.alibaba.com.caucho.hessian.io.SerializerFactory.getDefaultSerializer(SerializerFactory.java:395)
	at com.alibaba.com.caucho.hessian.io.SerializerFactory.getSerializer(SerializerFactory.java:369)
	at com.alibaba.com.caucho.hessian.io.Hessian2Output.writeObject(Hessian2Output.java:389)
	at com.alibaba.com.caucho.hessian.io.MapSerializer.writeObject(MapSerializer.java:98)
	at com.alibaba.com.caucho.hessian.io.Hessian2Output.writeObject(Hessian2Output.java:391)
	at com.alibaba.com.caucho.hessian.io.JavaSerializer$FieldSerializer.serialize(JavaSerializer.java:302)
	... 108 more
6 回复

那个对象实现下
implement java.io.Serializable

Sys_user里面有个map没转换好?

贴下缓存的那个类吧

我那个类没有map属性啊

package cn.wizzer.app.sys.modules.models;

import cn.wizzer.app.cai.modules.models.*;
import cn.wizzer.framework.base.model.BaseModel;
import lombok.Builder;
import lombok.Data;
import org.nutz.dao.entity.annotation.*;
import org.nutz.integration.json4excel.annotation.J4EIgnore;
import org.nutz.integration.json4excel.annotation.J4EName;

import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by wizzer on 2016/6/21.
 */
@Table("sys_user")
@J4EName("用户数据")
@TableIndexes({@Index(name = "INDEX_SYS_USER_LOGINNAMAE", fields = {"loginname"}, unique = true)})
@Data
public class Sys_user extends BaseModel implements Serializable {
    private static final long serialVersionUID = 1L;

    @Column
    @Name
    @Comment("ID")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    @Prev(els = {@EL("uuid()")})
    private String id;

    @Column
    @Comment("用户名")
    @J4EName("用户名")
    @ColDefine(type = ColType.VARCHAR, width = 120)
    private String loginname;

    @Column
    @Comment("密码")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 100)
    private String password;// transient 修饰符可让此字段不在对象里显示

    @Column
    @Comment("密码盐")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 50)
    private String salt;

    @Column
    @Comment("昵称")
    @J4EName("昵称")
    @ColDefine(type = ColType.VARCHAR, width = 100)
    private String username;

    @Column
    @Comment("头像")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 255)
    private String avatar;

    @Column
    @Comment("性别")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String sex;

    @Column
    @Comment("所在地")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 64)
    private String location;

    @Column
    @Comment("wechat")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String wechat;

    @Column
    @Comment("weibo")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String weibo;

    @Column
    @Comment("qq")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String qq;

    @Column
    @Comment("wechatStr")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String wechatStr;

    @Column
    @Comment("weiboStr")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String weiboStr;

    @Column
    @Comment("qqStr")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String qqStr;


    @Column
    @Comment("身份类别")//1:设计师 2:供应商 3:材料商 4:其他
    @J4EIgnore
    @ColDefine(type = ColType.INT)
//    @Builder.Default
    @Default("1")
    private int type;

    @Column
    @Comment("是否在线")
    @J4EIgnore
    @ColDefine(type = ColType.BOOLEAN)
    private boolean userOnline;

    @Column
    @Comment("是否禁用")
    @J4EIgnore
    @ColDefine(type = ColType.BOOLEAN)
    private boolean disabled;

    @Column
    @Comment("电子邮箱")
    @J4EName("电子邮箱")
    @ColDefine(type = ColType.VARCHAR, width = 255)
    private String email;

    @Column
    @Comment("手机号码")
    @J4EName("手机号码")
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String mobile;

    @Column
    @Comment("登陆时间")
    @J4EIgnore
    private Long loginAt;

    @Column
    @Comment("登陆IP")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 255)
    private String loginIp;

    @Column
    @Comment("登陆次数")
    @J4EIgnore
    @ColDefine(type = ColType.INT)
    private int loginCount = -1;

    @Column
    @Comment("登陆SessionId")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 50)
    private String loginSessionId;

    @Column
    @Comment("常用菜单")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 255)
    private String customMenu;

    @Column
    @Comment("皮肤样式")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 100)
    private String loginTheme;

    @Column
    @J4EIgnore
    private boolean loginSidebar;

    @Column
    @J4EIgnore
    private boolean loginBoxed;

    @Column
    @J4EIgnore
    private boolean loginScroll;

    @Column
    @J4EIgnore
    private boolean loginPjax;

    @Column
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String unitid;

    @One(field = "unitid")
    @J4EIgnore
    private Sys_unit unit;

    @ManyMany(from = "userId", relation = "sys_user_role", to = "roleId")
    @J4EIgnore
    private List<Sys_role> roles;

    @ManyMany(from = "userId", relation = "sys_user_unit", to = "unitId")
    @J4EIgnore
    protected List<Sys_unit> units;

    @Many(field = "userId")
    private List<Cai_address> addresses;

    @Many(field = "userId")
    private List<Cai_collection> collections;

    @Many(field = "userId")
    private List<Cai_sample> samples;

    @Many(field = "userId")
    private List<Cai_storage> storages;

    @One(field = "id")
    private Cai_card card;

    @J4EIgnore
    protected List<Sys_menu> menus;

    @J4EIgnore
    protected List<Sys_menu> firstMenus;

    @J4EIgnore
    protected Map<String, List<Sys_menu>> secondMenus;

    @J4EIgnore
    private List<Sys_menu> customMenus;

}

应该是secondMenus里面的对象并没转换,虽然泛型是这个,单但实际内容不是

添加回复
请先登陆
回到顶部