1.结论,xml中返回为string的话,在list中只会取出来第一个元素
//根据value查询
@GetMapping("getTest")
public List<HashMap> getTest() {
List<HashMap> list = dictService.getTest();
return list;
}
<select id="getTest" resultType="java.lang.String"> select * from t_test </select>
mybatis-plus.mapper-locations =classpath*:mapper/**/*Mapper.xml