- val()和value的区别
一个是属性,一个是函数,一个是js的,一个是jquery的。 - 一个奇怪的问题如下:
![](https://img.haomeiwen.com/i1881979/4236b36bdce88fb4.png)
![](https://img.haomeiwen.com/i1881979/86b36c9fcd930255.png)
两张图的
devMode
的位置不一样,第一张是正确的,第二张是错误的,结果是APPID总是取后面一个值,估计devMode
的值默认为FALSE
- 请求返回
<pre></pre>
的处理方法 http://doc.okbase.net/wenniuwuren/archive/124504.html
![](https://img.haomeiwen.com/i1881979/307ea0da3ecb5b48.png)
- spring boot 中json请求的名称要与后天命名相同如下
![](https://img.haomeiwen.com/i1881979/8a6982e3ec947956.png)
![](https://img.haomeiwen.com/i1881979/ffc0a2c80b4bd1c4.png)
- spring boot中nativequery,以List<HashMap<String,Object>>返回,必须要用HashMap
![](https://img.haomeiwen.com/i1881979/d09e2c95c63b31be.png)
- jquery中json的解析处理
![](https://img.haomeiwen.com/i1881979/8656fdf371a6fbd1.png)
- spring boot中返回一个自定义的视图
需要写一个接口
/**
* 这里为什么要定义接口
*/
public interface CourseView {
Long getId();
String getName();
Float getScore();
}
然后返回视图
@Query("select c.name as name, cs.score as score, cs.id as id from Course c, CourseStudent cs where c.id = cs.courseId and cs.studentId = ?1")
List<CourseView> findCourseAndScoreByStudentId(Long studentId);
- JSON字符串的问题
![](https://img.haomeiwen.com/i1881979/64b8f1c33911c302.png)
网友评论