由于javaBean中的属性是custFullName,所以在使用jsp的时候,通过el表达式获取属性的值<td>${m.CustFullName}</td>。但是加载页面的时候报【javax.el.PropertyNotFoundException: Property [custFullName] not readable on type [com.aiwei.tdjk.entity.SaleOrderHeader]】,最终通过对比svn的代码发现,应该使用<td>${m.custfullname}</td>,暂时不明白为什么会这样。查到如下结论:

EL表达式获取对象属性的原理是这样的:
以表达式${user.name}为例
EL表达式会根据name去User类里寻找这个name的get方法,此时会自动把name首字母大写并加上get前缀,一旦找到与之匹配的方法,El表达式就会认为这就是要访问的属性,并返回属性的值。
所以,想要通过EL表达式获取对象属性的值,那么这个属性就必须有与之对应的get方法。如果不写get/set方法,那EL表达式就拿不到值了。set方法是给后台设置值用的。
当el表达式首字母大写,会判断第二个字母大小写,小写,抛异常;大写,则直接拼接get,形成getter方法
el表达式首字母小写,会判断第二个字母大小写,大写,必须第一个字母大写;否则无法获取值
如果el首字母大写,至少第二个字母必须大写。

org.apache.jasper.JasperException: javax.el.PropertyNotFoundException: Property [xxx] not readable on type [xxx]的更多相关文章

  1. javax.el.PropertyNotFoundException: Property [name] not readable on type

    该错误为el表达式读取javaBean属性时报错. 如: {$user.name} 原因: javaBean Class访问权限不够 解决办法: 将javaBean Class设置为public即可 ...

  2. HTTP Status 500 - javax.el.PropertyNotFoundException: Property 'lkmId' not found on type cn.itcast.entity.LinkMan

    报错 type Exception report message javax.el.PropertyNotFoundException: Property 'lkmId' not found on t ...

  3. javax.el.PropertyNotFoundException: Property 'imgUrl' not found on type java.lang.String

    严重: Servlet.service() for servlet jsp threw exception javax.el.PropertyNotFoundException: Property ' ...

  4. javax.el.PropertyNotFoundException: Property 'name' not found on type java.lang.String

    javax.el.PropertyNotFoundException: Property 'name' not found on type java.lang.String javax.el.Bean ...

  5. javax.el.PropertyNotFoundException:Property 'statisDate' not found on type java.lang.String

    1.错误描述 javax.el.PropertyNotFoundException:Property 'statisDate' not found on type java.lang.String 2 ...

  6. JSP页面使用EL表达式出现的问题:javax.el.PropertyNotFoundException: Property 'ID' not found on type java.lang.Str

    问题描述: 1. 后台返回到JSP前台的的list,在jsp页面使用EL表达式遍历时出现如下问题:javax.el.PropertyNotFoundException: Property 'ID' n ...

  7. Caused by: javax.el.PropertyNotFoundException: Property 'title' not found on type java.lang.String

    问题:在JSP页面显示从后台传过来的list集合数据报错. 错误信息: Caused by: javax.el.PropertyNotFoundException: Property 'title' ...

  8. EL bug 之 javax.el.PropertyNotFoundException: Property 'Sub_Token' not found on type com.sunmo.stPhone.bean.User

    javax.el.PropertyNotFoundException: Property 'Sub_Token' not found on type com.sunmo.stPhone.bean.Us ...

  9. Caused by: javax.el.PropertyNotFoundException: Property 'product' not found on type java.lang.String

    今天在JSP利用EL表达式取值报了 "javax.el.PropertyNotFoundException”,经过debug和打印将问题定位到这段代码: HTML应该是没啥问题,看提示在ja ...

随机推荐

  1. golang 中可变参数的个数

    package main import "fmt" func Greeting(prefix string, who ... string) { fmt.Println(prefi ...

  2. 百度编辑器ueditor给上传的图片加入水印

    百度编辑器本身是没有为上传图片加入水印的功能,想要在上传的时候加入图片水印,也非常easy.以 ueditor 1.2.6 为例.打开php文件夹以下的imageUp.php文件,查找"$i ...

  3. antd 的 Table 遇到的 bug

    1.报错情况 /* autoprefixer: off */ filter: progid\:DXImageTransform\.Microsoft\.Blur(PixelRadius\=1, Mak ...

  4. ZOJ问题(2010浙江大学研究生复试上机题目[找规律] hdoj 3788)

    ZOJ问题 pid=3788">点击打开链接 Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K ...

  5. Delphi中处理URL编码解码

    Delphi中处理URL编码解码 一.URL简单介绍     URL是网页的地址,比方 http://www.shanhaiMy.com. Web 浏览器通过 URL 从 web server请求页面 ...

  6. 另存为Alt-F-A ©┗ 最近使用的文档/选项

    另存为Alt-F-A © ┗ 最近使用的文档/选项

  7. Netty In Action中文版 - 第四章:Transports(传输)

    本章内容 Transports(传输) NIO(non-blocking IO,New IO), OIO(Old IO,blocking IO), Local(本地), Embedded(嵌入式) U ...

  8. UVA10056 - What is the Probability ?(概率)

    UVA10056 - What is the Probability ? (概率) 题目链接 题目大意:有n个人玩游戏,一直到一个人胜出之后游戏就能够结束,要不然就一直从第1个到第n个循环进行,没人一 ...

  9. Swing的Look And Feel机制研究

    首先,参考了一下这篇文章 里面提到需要自己Override L&F的initClassDefaults方法,但是查看了一下NimbusLookAndFeel, 发现它为了没有实现initCla ...

  10. POJ2127 Greatest Common Increasing Subsequence

    POJ2127 给定两个 整数序列,求LCIS(最长公共上升子序列) dp[i][j]表示A的A[1.....i]与B[1.....j]的以B[j]为结尾的LCIS. 转移方程很简单 当A[i]!=B ...