update
This commit is contained in:
parent
e56dec3b9d
commit
229c902273
@ -100,15 +100,15 @@ public class MapTopActivity extends AppCompatActivity {
|
||||
intent.putExtra("chapterName", nodes.get(position));
|
||||
intent.putExtra("mapNode", com.alibaba.fastjson.JSONObject.toJSONString(mapNodes.get(position)));
|
||||
intent.putExtra("data", 1);
|
||||
} else {
|
||||
intent = new Intent(MapTopActivity.this, MapUserTeamActivity.class);
|
||||
intent.putExtra("data", teamData);
|
||||
}
|
||||
} else if (model == -1) {
|
||||
intent = new Intent(MapTopActivity.this, MapTopActivity.class);
|
||||
intent.putExtra("level_name", level_name);
|
||||
intent.putExtra("chapterName", nodes.get(position));
|
||||
intent.putExtra("data", 0);
|
||||
} else if (model == 1) {
|
||||
intent = new Intent(MapTopActivity.this, MapUserTeamActivity.class);
|
||||
intent.putExtra("data", JSON.toJSONString(logs.get(position)));
|
||||
}
|
||||
if (intent != null)
|
||||
startActivity(intent, ActivityOptions.makeSceneTransitionAnimation(MapTopActivity.this, name, "transitionTitle").toBundle());
|
||||
|
@ -9,6 +9,7 @@ import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.yutou.jianr_mg.Adapters.MapUserTeamRecyclierAdapter;
|
||||
import com.yutou.jianr_mg.Data.GameInfoLog;
|
||||
import com.yutou.jianr_mg.Data.MapNode;
|
||||
import com.yutou.jianr_mg.Interfaces.HttpInterface;
|
||||
import com.yutou.jianr_mg.Network.HttpApi;
|
||||
@ -24,7 +25,7 @@ import cn.lemon.view.RefreshRecyclerView;
|
||||
public class MapUserTeamActivity extends AppCompatActivity {
|
||||
private RefreshRecyclerView recyclerView;
|
||||
private MapUserTeamRecyclierAdapter adapter;
|
||||
private MapNode mapNode;
|
||||
private GameInfoLog mapNode;
|
||||
private int limit=0;
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
@ -32,15 +33,15 @@ public class MapUserTeamActivity extends AppCompatActivity {
|
||||
setContentView(R.layout.activity_favorite);
|
||||
recyclerView = findViewById(R.id.recyclerView);
|
||||
try {
|
||||
mapNode= JSON.parseObject(getIntent().getStringExtra("data"),MapNode.class);
|
||||
mapNode= JSON.parseObject(getIntent().getStringExtra("data"), GameInfoLog.class);
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
Utils.toast(this,"数据异常");
|
||||
finish();
|
||||
return;
|
||||
}
|
||||
System.out.println(mapNode.toString());
|
||||
|
||||
initView();
|
||||
initData();
|
||||
}
|
||||
|
||||
void initView() {
|
||||
@ -50,23 +51,6 @@ public class MapUserTeamActivity extends AppCompatActivity {
|
||||
recyclerView.setAdapter(adapter);
|
||||
}
|
||||
void initData(){
|
||||
try{
|
||||
JSONObject json=new JSONObject();
|
||||
json.put("node",mapNode.getId());
|
||||
json.put("limit",limit);
|
||||
HttpUtils.post(HttpApi.HOME_URL + HttpApi.MAPTOP_USER_TEAM, json, new HttpInterface() {
|
||||
@Override
|
||||
public void httpGetData(String string, int code) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void httpError(Exception e) {
|
||||
|
||||
}
|
||||
});
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user