diff --git a/src/com/hellogithub/dao/UserDao.java b/src/com/hellogithub/dao/UserDao.java index 46aad93..3e8def8 100644 --- a/src/com/hellogithub/dao/UserDao.java +++ b/src/com/hellogithub/dao/UserDao.java @@ -131,18 +131,19 @@ public class UserDao { String sql = "select searchHistory from user where userName=? and isValid = 1"; userEntity = runner.query(conn, sql, new BeanHandler<>(userEntity.class),name); l = userEntity.getSearchHistory().split(";"); - - for(int i=0;i sss= new ArrayList<>(Arrays.asList(l)); + for(int i=0;i stringList = userService.selectLabel(name); if(stringList.get(0).equals("无搜索历史")){ - writer.println(jsonString); + writer.println("null"); } else{ jsonString = JSONObject.toJSONString(stringList);