Merge branch 'master_test_gn' of http://60.1.1.230/backend/jieling_server into master_test_gn
commit
b3df483ef8
|
@ -128,6 +128,14 @@ public class LjsdMongoTemplate implements MongoUpdateImp {
|
||||||
}
|
}
|
||||||
return otherMonogTemplate.findById(id,clazz,collectionName);
|
return otherMonogTemplate.findById(id,clazz,collectionName);
|
||||||
}
|
}
|
||||||
|
public <T> T findByIdMy(String collectionName, String id, Class<T> clazz) throws Exception {
|
||||||
|
//int serverIdByUid = AreaManager.getInstance().getServerIdByUid(Integer.parseInt(id), GameApplication.serverId);
|
||||||
|
MongoTemplate otherMonogTemplate = getMongoTemplate(GameApplication.serverId);
|
||||||
|
if(otherMonogTemplate==null){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return otherMonogTemplate.findById(id,clazz,collectionName);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public <T> T findById(String collectionName, int id, Class<T> clazz) throws Exception {
|
public <T> T findById(String collectionName, int id, Class<T> clazz) throws Exception {
|
||||||
|
|
|
@ -157,18 +157,15 @@ public class StartHardStageRequestHandler extends BaseHandler<PlayerInfoProto.Ha
|
||||||
//战斗回放
|
//战斗回放
|
||||||
int force = HeroLogic.getInstance().calTeamTotalForce(user, teamId, false);
|
int force = HeroLogic.getInstance().calTeamTotalForce(user, teamId, false);
|
||||||
// 首次通关记录
|
// 首次通关记录
|
||||||
/* Criteria criteria = new Criteria().andOperator(
|
ArenaRecord minForceRecord = RedisUtil.getInstence().get(RedisKey.HARD_STAGE_PASS_MIN_FORCE,String.valueOf(nodeId),ArenaRecord.class);
|
||||||
Criteria.where("id").is("1_"+nodeId)
|
if(minForceRecord!=null){
|
||||||
);
|
if(force< minForceRecord.getAttackForce()){
|
||||||
Query query = new Query(criteria);
|
RedisUtil.getInstence().remove(RedisUtil.getInstence().getKey(RedisKey.HARD_STAGE_PASS_MIN_FORCE,String.valueOf(nodeId),true));
|
||||||
|
}
|
||||||
Criteria criteria2 = new Criteria().andOperator(
|
}
|
||||||
Criteria.where("id").is("2_"+ nodeId)
|
|
||||||
);
|
|
||||||
Query query2 = new Query(criteria2);*/
|
|
||||||
LjsdMongoTemplate ljsdMongoTemplate = MongoUtil.getLjsdMongoTemplate();
|
LjsdMongoTemplate ljsdMongoTemplate = MongoUtil.getLjsdMongoTemplate();
|
||||||
com.ljsd.jieling.logic.dao.root.ArenaRecord firstPassRecord = ljsdMongoTemplate.findById(com.ljsd.jieling.logic.dao.root.ArenaRecord._COLLECTION_NAME,"1_"+nodeId, com.ljsd.jieling.logic.dao.root.ArenaRecord.class);
|
com.ljsd.jieling.logic.dao.root.ArenaRecord firstPassRecord = ljsdMongoTemplate.findByIdMy(com.ljsd.jieling.logic.dao.root.ArenaRecord._COLLECTION_NAME,"1_"+nodeId, com.ljsd.jieling.logic.dao.root.ArenaRecord.class);
|
||||||
com.ljsd.jieling.logic.dao.root.ArenaRecord minForcePassRecordList = ljsdMongoTemplate.findById(com.ljsd.jieling.logic.dao.root.ArenaRecord._COLLECTION_NAME,"2_"+nodeId, com.ljsd.jieling.logic.dao.root.ArenaRecord.class);
|
com.ljsd.jieling.logic.dao.root.ArenaRecord minForcePassRecordList = ljsdMongoTemplate.findByIdMy(com.ljsd.jieling.logic.dao.root.ArenaRecord._COLLECTION_NAME,"2_"+nodeId, com.ljsd.jieling.logic.dao.root.ArenaRecord.class);
|
||||||
if(firstPassRecord == null ){
|
if(firstPassRecord == null ){
|
||||||
com.ljsd.jieling.logic.dao.root.ArenaRecord arenaRecord = new com.ljsd.jieling.logic.dao.root.ArenaRecord();
|
com.ljsd.jieling.logic.dao.root.ArenaRecord arenaRecord = new com.ljsd.jieling.logic.dao.root.ArenaRecord();
|
||||||
arenaRecord.setId("1_"+ nodeId);
|
arenaRecord.setId("1_"+ nodeId);
|
||||||
|
|
Loading…
Reference in New Issue