为了账号安全,请及时绑定邮箱和手机立即绑定

添加员工,点击保存按钮后,直接跳转到登陆页面,报错

页面下拉框:

<td>
   <s:select name="department.did" list="list" listkey="did" listValue="dname" headerKey="" headerValue="--请选择--"/>
</td>

点击保存,后台报错

2016-11-18 16:23:00,318 [http-nio-8080-exec-9] WARN  [com.opensymphony.xwork2.ognl.OgnlValueStack] - Error setting expression 'department.did' with value '[Ljava.lang.String;@1587b9f'

ognl.MethodFailedException: Method "setDid" failed for object com.muke.employee.domain.Department@17c920c [java.lang.NoSuchMethodException: com.muke.employee.domain.Department.setDid([Ljava.lang.String;)]

at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1305)

at ognl.OgnlRuntime.setMethodValue(OgnlRuntime.java:1494)

at ognl.ObjectPropertyAccessor.setPossibleProperty(ObjectPropertyAccessor.java:85)

at ognl.ObjectPropertyAccessor.setProperty(ObjectPropertyAccessor.java:162)

at com.opensymphony.xwork2.ognl.accessor.ObjectAccessor.setProperty(ObjectAccessor.java:27)

at ognl.OgnlRuntime.setProperty(OgnlRuntime.java:2332)


正在回答

1 回答

问题找到了,原因是页面下拉框<s:select>标签中的属性listkey,应该写成:listKey  , k应是大写

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

添加员工,点击保存按钮后,直接跳转到登陆页面,报错

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信