@At("/query")
@Ok("jsp:jsp.H_manage.sql_mapping-list")
@RequiresPermissions("sql_mapping:quey")
public Object query(@Param("name") String name){
List<SQL_Mapping> list =new ArrayList<>();
NutMap map = new NutMap();
Cnd cnd =Cnd.NEW();
if (!StringUtils.isEmpty(name)){
cnd.where().andEquals("name",name);
}
list= dao.query(SQL_Mapping.class,cnd);
map.put("obj",list);
return map;
}
jsp代码
<c:forEach var="ob" items="${obj}" varStatus="state">
<c:if test="${!ob.token}">
${obj.name};
${obj}
</c:if>
</c:forEach>