[chuni] minor API changes related to standard course

pull/1/head
Dom Eori 2021-05-14 20:22:38 +09:00
parent 6f1493ded1
commit 375823a21e
6 changed files with 24 additions and 10 deletions

View File

@ -39,13 +39,13 @@ public class GetUserFavoriteItemHandler implements BaseHandler {
Map<String, Object> resultMap = new LinkedHashMap<>(); Map<String, Object> resultMap = new LinkedHashMap<>();
resultMap.put("userId", userId); resultMap.put("userId", userId);
resultMap.put("kind", kind);
resultMap.put("length", 0); resultMap.put("length", 0);
resultMap.put("nextIndex", 0); resultMap.put("kind", kind);
resultMap.put("userFavoriteMusicList", List.of()); resultMap.put("nextIndex", -1);
resultMap.put("userFavoriteItemList", List.of());
String json = mapper.write(resultMap); String json = mapper.write(resultMap);
logger.debug("Response: " + json); logger.info("Response: " + json);
return json; return json;
} }
} }

View File

@ -43,7 +43,7 @@ public class GetUserFavoriteMusicHandler implements BaseHandler {
resultMap.put("userFavoriteMusicList", List.of()); resultMap.put("userFavoriteMusicList", List.of());
String json = mapper.write(resultMap); String json = mapper.write(resultMap);
logger.debug("Response: " + json); logger.info("Response: " + json);
return json; return json;
} }
} }

View File

@ -37,7 +37,7 @@ public class GetUserLoginBonusHandler implements BaseHandler {
resultMap.put("userLoginBonusList", List.of()); resultMap.put("userLoginBonusList", List.of());
String json = mapper.write(resultMap); String json = mapper.write(resultMap);
logger.debug("Response: " + json); logger.info("Response: " + json);
return json; return json;
} }
} }

View File

@ -103,6 +103,9 @@ public class GetUserPreviewHandler implements BaseHandler {
resp.setHeadphone(userGameOption.getHeadphone()); resp.setHeadphone(userGameOption.getHeadphone());
}); });
resp.setChargeState(0);
resp.setUserNameEx(user.getUserName());
String json = mapper.write(resp); String json = mapper.write(resp);
logger.info("Response: " + json); logger.info("Response: " + json);
return json; return json;

View File

@ -25,13 +25,22 @@ public class GetUserTeamHandler implements BaseHandler {
@Override @Override
public String handle(Map<String, Object> request) throws JsonProcessingException { public String handle(Map<String, Object> request) throws JsonProcessingException {
String userId = (String) request.get("userId"); String userId = (String) request.get("userId");
String playDate = (String) request.get("playDate");
Map<String, Object> resultMap = new LinkedHashMap<>(); Map<String, Object> resultMap = new LinkedHashMap<>();
resultMap.put("userId", userId); resultMap.put("userId", userId);
resultMap.put("teamId", 1); resultMap.put("teamId", 0);
resultMap.put("teamRank", 1); resultMap.put("teamRank", 0);
resultMap.put("teamName", "ParadiseLeakWhen"); resultMap.put("teamName", "");
resultMap.put("userTeamPoint", 114514);
Map<String, Object> userTeamMap = new LinkedHashMap<>();
userTeamMap.put("userId", userId);
userTeamMap.put("teamId", 0);
userTeamMap.put("orderId", 0);
userTeamMap.put("teamPoint", 0);
userTeamMap.put("aggrDate", playDate);
resultMap.put("userTeamPoint", userTeamMap);
String json = mapper.write(resultMap); String json = mapper.write(resultMap);
logger.info("Response: " + json); logger.info("Response: " + json);

View File

@ -34,5 +34,7 @@ public class GetUserPreviewResp {
private int playerLevel; private int playerLevel;
private int rating; private int rating;
private int headphone; private int headphone;
private int chargeState;
private String userNameEx;
} }