Commit f562144c by donghu

更新代码

1 parent a0483d7e
Showing 27 changed files with 257 additions and 3 deletions
...@@ -23,6 +23,10 @@ ...@@ -23,6 +23,10 @@
<attribute name="maven.pomderived" value="true"/> <attribute name="maven.pomderived" value="true"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/> <classpathentry kind="output" path="target/classes"/>
</classpath> </classpath>
/target/
package com.pipi.qa.basic; package com.pipi.qa.basic;
public class BasicData { public class BasicData {
public final static String userName = "admin"; public final static String userName = "admin";
public final static String passWord = "ZnVsdTk5NjM1"; public final static String passWord = "ZnVsdTk5NjM1";
public final static String preTestUserName = "chengjie";
public final static String preTestPassWord = "MXFhejJ3c3gzZWRj";
} }
...@@ -3,8 +3,15 @@ package com.pipi.qa.bean; ...@@ -3,8 +3,15 @@ package com.pipi.qa.bean;
public class Player { public class Player {
private String env; private String env;
private String mobile; private String mobile;
private String techLevelId;
private String id;
private String categoryId;
public String getEnv() { public String getEnv() {
return env; return env;
} }
...@@ -18,5 +25,23 @@ public class Player { ...@@ -18,5 +25,23 @@ public class Player {
this.mobile = mobile; this.mobile = mobile;
} }
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getTechLevelId() {
return techLevelId;
}
public void setTechLevelId(String techLevelId) {
this.techLevelId = techLevelId;
}
public String getCategoryId() {
return categoryId;
}
public void setCategoryId(String categoryId) {
this.categoryId = categoryId;
}
} }
...@@ -6,8 +6,16 @@ public class Room { ...@@ -6,8 +6,16 @@ public class Room {
private String mobile; private String mobile;
private String guildCode;
private String roomNo; private String roomNo;
private String roomName;
private long roomType;
private long roomCategoryId;
private String activityId; private String activityId;
private String amount; private String amount;
...@@ -82,4 +90,37 @@ public class Room { ...@@ -82,4 +90,37 @@ public class Room {
this.times = times; this.times = times;
} }
public String getGuildCode() {
return guildCode;
}
public void setGuildCode(String guildCode) {
this.guildCode = guildCode;
}
public String getRoomName() {
return roomName;
}
public void setRoomName(String roomName) {
this.roomName = roomName;
}
public long getRoomType() {
return roomType;
}
public void setRoomType(long roomType) {
this.roomType = roomType;
}
public long getRoomCategoryId() {
return roomCategoryId;
}
public void setRoomCategoryId(long roomCategoryId) {
this.roomCategoryId = roomCategoryId;
}
} }
...@@ -16,6 +16,10 @@ public class User { ...@@ -16,6 +16,10 @@ public class User {
private long money; private long money;
private long openStatus;
private long guildBiz;
public String getEnv() { public String getEnv() {
return env; return env;
} }
...@@ -72,5 +76,21 @@ public class User { ...@@ -72,5 +76,21 @@ public class User {
this.money = money; this.money = money;
} }
public long getOpenStatus() {
return openStatus;
}
public void setOpenStatus(long openStatus) {
this.openStatus = openStatus;
}
public long getGuildBiz() {
return guildBiz;
}
public void setGuildBiz(long guildBiz) {
this.guildBiz = guildBiz;
}
} }
...@@ -57,6 +57,58 @@ public class CosPlayPlayerController { ...@@ -57,6 +57,58 @@ public class CosPlayPlayerController {
} }
/** /**
* 陪玩师申请入驻
* @param PlayerApply
* @return
*/
@ApiOperation(value = "陪玩师申请入驻", notes = "输入手机号")
@RequestMapping(value = "/saveInfoTech", method = RequestMethod.POST)
@ResponseBody
public JSONObject saveInfoTech(@RequestBody Player player) {
String mobile = player.getMobile();
String env = player.getEnv();
String techLevelId = player.getTechLevelId();
String id =player.getId();
String categoryId = player.getCategoryId();
//登录获取token、userId
JSONObject loginRes = cosPlayPlayerService.login(mobile, env);
token = loginRes.getJSONObject("data").getString("token");
userId = loginRes.getJSONObject("data").getString("id");
JSONObject jsonObj = cosPlayPlayerService.saveInfoTech(token, userId, categoryId, techLevelId, env);
logger.info("env:"+env+"mobile:"+mobile);
return jsonObj;
}
/**
* 申请陪玩师及入驻
* @param PlayerApply
* @return
*/
@ApiOperation(value = "申请陪玩师及入驻", notes = "输入手机号")
@RequestMapping(value = "/playerApplyAndSaveInfoTech", method = RequestMethod.POST)
@ResponseBody
public JSONObject playerApplyAndSaveInfoTech(@RequestBody Player player) {
String mobile = player.getMobile();
String env = player.getEnv();
String techLevelId = player.getTechLevelId();
String id =player.getId();
String categoryId = player.getCategoryId();
//登录获取token、userId
JSONObject loginRes = cosPlayPlayerService.login(mobile, env);
token = loginRes.getJSONObject("data").getString("token");
userId = loginRes.getJSONObject("data").getString("id");
//申请陪玩师
cosPlayPlayerService.SubmitAuthentication(token, userId, env);
//提交陪玩师资料
cosPlayPlayerService.saveUserInfo(token, userId, env);
//申请陪玩师技能
JSONObject jsonObj = cosPlayPlayerService.saveInfoTech(token, userId, categoryId, techLevelId, env);
logger.info("env:"+env+"mobile:"+mobile);
return jsonObj;
}
/**
*充钻石 *充钻石
* @param User * @param User
* @return * @return
...@@ -153,4 +205,88 @@ public class CosPlayPlayerController { ...@@ -153,4 +205,88 @@ public class CosPlayPlayerController {
return jsonObj; return jsonObj;
} }
/**
*创建公会
* @param PlayerApply
* @return
*/
@ApiOperation(value = "创建公会", notes = "是否开启自定义分成,1开启,0不开启,guildBiz语音1,游戏2,全部0")
@RequestMapping(value = "/guildCreate", method = RequestMethod.POST)
@ResponseBody
public JSONObject guildCreate(@RequestBody User user) {
String mobile = user.getMobile();
String env = user.getEnv();
long guildBiz = user.getGuildBiz();
long openStatus = user.getOpenStatus();
JSONObject jsonObj = cosPlayPlayerService.guildCreate(mobile, openStatus, guildBiz, env);
return jsonObj;
}
/**
*申请加入公会
* @param guildCenter
* @return
*/
@ApiOperation(value = "申请加入公会", notes = "支持按公会ID申请加入,需要审核")
@RequestMapping(value = "/guildCenter", method = RequestMethod.POST)
@ResponseBody
public JSONObject guildCenter(@RequestBody Room room) {
String mobile = room.getMobile();
String env = room.getEnv();
String guildCode = room.getGuildCode();
JSONObject jsonObj = cosPlayPlayerService.guildCenter(mobile, guildCode, env);
return jsonObj;
}
/**
*审核加入公会
* @param applyList
* @return
*/
@ApiOperation(value = "审核加入公会", notes = "审核人员")
@RequestMapping(value = "/applyList", method = RequestMethod.POST)
@ResponseBody
public JSONObject applyList(@RequestBody Room room) {
String mobile = room.getMobile();
String env = room.getEnv();
String guildCode = room.getGuildCode();
JSONObject jsonObj = cosPlayPlayerService.applyList(mobile, env);
return jsonObj;
}
/**
*加入公会及审核
* @param applyList
* @return
*/
@ApiOperation(value = "申请加入公会及审核", notes = "审核人员")
@RequestMapping(value = "/auditGuild", method = RequestMethod.POST)
@ResponseBody
public JSONObject auditGuild(@RequestBody Room room) {
String mobile = room.getMobile();
String env = room.getEnv();
String guildCode = room.getGuildCode();
JSONObject jsonObj = cosPlayPlayerService.auditGuild(mobile, guildCode, env);
return jsonObj;
}
/**
*创建厅
* @param roomSave
* @return
*/
@ApiOperation(value = "创建厅", notes = "")
@RequestMapping(value = "/roomSave", method = RequestMethod.POST)
@ResponseBody
public JSONObject roomSave(@RequestBody Room room) {
String mobile = room.getMobile();
String env = room.getEnv();
long roomCategoryId = room.getRoomCategoryId();
long roomType = room.getRoomType();
String roomName = room.getRoomName();
JSONObject jsonObj = cosPlayPlayerService.roomSave(mobile, roomName, roomType, roomCategoryId, env);
return jsonObj;
}
} }
package com.pipi.qa.service; package com.pipi.qa.service;
import java.util.Map;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
...@@ -18,7 +20,7 @@ public interface CosPlayPlayerService { ...@@ -18,7 +20,7 @@ public interface CosPlayPlayerService {
public JSONObject SubmitAuthentication(String token,String userId,String env); public JSONObject SubmitAuthentication(String token,String userId,String env);
public String getAdminToken(String username, String password, String env); public String getAdminToken(String env);
public JSONObject saveUserInfo(String token, String userId, String env); public JSONObject saveUserInfo(String token, String userId, String env);
...@@ -34,4 +36,24 @@ public interface CosPlayPlayerService { ...@@ -34,4 +36,24 @@ public interface CosPlayPlayerService {
public JSONObject lotteryActivity(String mobile,String roomNo, String activityId, String times, String env); public JSONObject lotteryActivity(String mobile,String roomNo, String activityId, String times, String env);
public JSONObject saveInfoTech(String token, String userId, String categoryId, String techLevelId, String env);
public JSONObject guildCreate(String mobile, long openStatus, long guildBiz, String env);
public JSONObject guildList(Map<String, Object> adminHeaders, String guildCode, String env);
public JSONObject roomSave(String mobile, String roomName, long roomType, long roomCategoryId, String env);
public JSONObject userList(String mobile, String env);
public JSONObject guildCenter(String mobile,String queryStr, String env);
public long guildSearch(String mobile, String queryStr, String env);
public JSONObject applyList(String mobile, String env);
public JSONObject handleApply(String mobile, long applyId, String env);
public JSONObject auditGuild(String mobile, String queryStr, String env);
} }
#Generated by Apache Maven #Generated by Apache Maven
#Tue May 25 13:01:27 CST 2021 #Tue Jun 22 17:46:33 CST 2021
version=1.5.9.RELEASE version=1.5.9.RELEASE
groupId=com.pipi.qa groupId=com.pipi.qa
artifactId=pipi-data-center artifactId=pipi-data-center
This file is too large to display.
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!