Exemple #1
0
 private void initData() {
   if (!TextUtils.isEmpty(parser.getPhoto())) {
     ImageLoader.getInstance().displayImage(parser.getPhoto(), iv_expert);
   }
   tv_expert_name.setText(parser.getTruename());
   tv_expert_price.setText(parser.getPrice());
   tv_expert_intro.setText(parser.getTitle());
 }
Exemple #2
0
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   Bundle args = getActivity().getIntent().getExtras();
   if (null != args) {
     mJson = args.getString(Constant.EXTRA_JSON);
     if (!TextUtils.isEmpty(mJson)) {
       try {
         parser = new TopicParser();
         parser.parseData(new JSONObject(mJson).optJSONObject("data"));
       } catch (JSONException e) {
         e.printStackTrace();
       }
     }
   }
 }