suiyuantian
suiyuantian
2015-12-16 04:12

springmvc 对象属性参数接收不到

  • spring

user.getSysManager()获取到的是空的?
部分代码如下:
bean类:

 public class SysUser extends BaseForm implements Serializable {

    private static final long serialVersionUID = 8217046986932721581L;

    private Long USERID; // 用户ID

    private String LOGINNAME; // 用户帐号

    private String PASSWD; // 密码

    private Integer STATUSID; // 状态

    private Long ORDERBY; // 排序

    private Integer USERTYPE; // 用户类型

    private String REMARK; // 备注

    private String BEGINTIME;

    private String ENDTIME;

    private SysManager sysManager;

    private String OLDPASSWD;

    private String CONFIRMPASSWD;

action类

 /**
     * 列表分页
     */
    @RequestMapping(value = "/getTabList")
    @ResponseBody
    public PageData getTabList(SysUser user) {
        System.out.println(user.getSysManager());
        SysUser sysUser = this.getSessionUser();
        if (sysUser.getUSERTYPE() != 1) {
            user.setUSERID(sysUser.getUSERID());
        }
        List<SysUser> varList = userService.list(user);
        return new PageData(user.getTotal(), varList);
    }

前台

 <td>姓名:</td>
                    <td><input type="text" name="sysManager.USERNAME"
                        class="easyui-textbox" style="width: 150px;" />
                    </td>
                    <td>手机:</td>
                    <td><input type="text" name="sysManager.MOBILE"
                        class="easyui-textbox" style="width: 150px;" />
                    </td>
  • 点赞
  • 回答
  • 收藏
  • 复制链接分享

2条回答