@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_team_detail); Intent intent = getIntent(); teamId = intent.getIntExtra("teamId", -1); Search search = new Search(); search.searchId = teamId; backGroundRest( "team/detail", "POST", search, Team.class, new CallBack<Team>() { @Override public void success(Team team) { TeamDetailActivity.this.team = team; if (team == null) return; if (team.init == 0) { team.init = 1; rest("team", "PUT", team); Intent inviteIntent = new Intent(TeamDetailActivity.this, ChooseContactsActivity.class); // intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | // Intent.FLAG_ACTIVITY_NEW_TASK); inviteIntent.putExtra("type", "team"); inviteIntent.putExtra("team", team); startActivityForResult(inviteIntent, 0); if (menu != null) { MenuItem write = menu.findItem(R.id.action_write); if ("J".equals(team.joined)) { write.setVisible(true); } else { write.setVisible(false); } } } } }); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_billing); Intent intent = getIntent(); prayer = (Prayer) intent.getSerializableExtra("prayer"); int total = prayer.friends.size() + prayer.phone.size(); int ex = total - Global.FREE_FRIENDS_COUNT; TextView totalText = (TextView) findViewById(R.id.total); totalText.setText(total + "명"); TextView exText = (TextView) findViewById(R.id.ex); exText.setText(ex + "명"); TextView sum = (TextView) findViewById(R.id.sum); sum.setText("총 " + ex + "명"); calc.setText(" (" + ex + "명 X " + Global.DALANT_PER_PERSON + " 달란트)"); TextView price = (TextView) findViewById(R.id.price); price.setText((ex * Global.DALANT_PER_PERSON) + "달란트"); }