Exemplo n.º 1
0
  @Override
  public void onReceiveResponse(Response response, Request request, Object tag) {
    super.onReceiveResponse(response, request, tag);
    if (response instanceof GetInquiryFromOtherItemsResponse) {
      dismissProgress();
      ArrayList<GoodsListData> goodListDatas =
          ((GetInquiryFromOtherItemsResponse) response).getGoodListDatas();
      if (nowIndex == 1) {
        adapterLeft.setDatas(goodListDatas);
        mRlvAskPrice.stopRefresh();
        mRlvAskPrice.setAdapter(adapterLeft);

      } else {
        adapterLeft.addDatas(goodListDatas);
        mRlvAskPrice.stopLoadMore();
      }
      nowIndex++;
      isLoading = false;
    } else if (response instanceof GetInquiryFromMeItemResponse) {
      ArrayList<GoodsListDataForAskMe> goodListDatas =
          ((GetInquiryFromMeItemResponse) response).getDataForAskMes();
      if (nowIndex == 1) {
        adapterRight.setDatas(goodListDatas);
        mRlvAskPrice.stopRefresh();

      } else {
        adapterRight.addDatas(goodListDatas);
        mRlvAskPrice.stopLoadMore();
      }
      nowIndex++;
      isLoading = false;
    }
  }
Exemplo n.º 2
0
  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    addContentView(R.layout.change_bind_first);
    setTitle("修改绑定手机");
    btnNext = (Button) findViewById(R.id.change_bind_btn_next);
    edtUid = (EditText) findViewById(R.id.change_bind_edt_uid);
    edtPwd = (EditText) findViewById(R.id.change_bind_edt_pwd);

    btnNext.setOnClickListener(
        new OnClickListener() {

          @Override
          public void onClick(View v) {
            // startActivity(new
            // Intent(ChangeBindActivityFirst.this,ChangeBindActivitySecond.class));
            if (check()) {
              CheckPassWordRequest checkPassWordRequest = new CheckPassWordRequest();
              checkPassWordRequest.setUserId(edtUid.getText().toString().trim());
              checkPassWordRequest.setPassWord(edtPwd.getText().toString());
              sendRequest(checkPassWordRequest);
            }
          }
        });
  }
Exemplo n.º 3
0
 @Override
 protected void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   addContentView(R.layout.home_evaluate_view);
   context = this;
   setTitle("评价");
   init();
   initListener();
 }
Exemplo n.º 4
0
 @Override
 protected void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   addContentView(R.layout.home_order_view);
   setTitle("订单列表");
   context = this;
   init();
   registerLinstener();
   initViewPager();
   sendSellRequest(pageIndexSell, pageSize, "dd");
   sendBuyRequest(pageIndexBuy, pageSize, "dd");
   showProgress();
 }
Exemplo n.º 5
0
 @Override
 protected void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   context = this;
   addContentView(R.layout.ask_price_view);
   setTitle("询价");
   init();
   initViewPager();
   registerLinstener();
   sendAskOtherReq();
   ImageSizeUtils.myScale = 1;
   showProgress();
 }
Exemplo n.º 6
0
 @Override
 public void onReceiveResponse(Response response, Request request, Object tag) {
   super.onReceiveResponse(response, request, tag);
   if (response instanceof CheckPassWordResponse) {
     CheckPassWordResponse checkPassWordResponse = (CheckPassWordResponse) response;
     if (checkPassWordResponse.getUpdateState().equals("1")) {
       finish();
       startActivity(new Intent(ChangeBindActivityFirst.this, ChangeBindActivitySecond.class));
     } else {
       showToast(checkPassWordResponse.getUpdateInfo());
     }
   }
 }
  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setTitle("修改价格");
    addContentView(R.layout.change_price_detail_view);
    lv = (ListView) findViewById(R.id.change_price_detail_lv_list);
    btnDetail = (Button) findViewById(R.id.change_price_detail_view_btn_detail);
    adapter = new Adapter();
    lv.setAdapter(adapter);

    btnDetail.setOnClickListener(
        new OnClickListener() {

          @Override
          public void onClick(View v) {
            startActivity(
                new Intent(ChangePriceDetailActivity.this, CarSourceDetailActivity.class));
          }
        });
  }
Exemplo n.º 8
0
 @Override
 protected void onResume() {
   super.onResume();
   freshBuyList();
 }
Exemplo n.º 9
0
  @Override
  public void onReceiveResponse(Response response, Request request, Object tag) {
    // TODO Auto-generated method stub
    super.onReceiveResponse(response, request, tag);
    isLoading = false;
    int index = 0;
    try {
      index = Integer.parseInt(tag.toString());
    } catch (Exception e) {

    }

    if (response instanceof GetOrderListSellResponse) {
      dismissProgress();
      List<Order> list = ((GetOrderListSellResponse) response).getListOrder();
      if (tag.toString().equals(MORE)) {

      } else {
        sellList.clear();
      }
      for (int i = 0; i < list.size(); i++) {
        sellList.add(list.get(i));
      }
      if (list.size() < pageSize) {
        sellOrderListView.setPullLoadEnable(false);
      } else {
        sellOrderListView.setPullLoadEnable(true);
      }
      sellOrderListAdapter.notifyDataSetChanged();
      onLoadBuy();
    } else if (response instanceof GetOrderListBuyResponse) {
      List<Order> list = ((GetOrderListBuyResponse) response).getListOrder();
      if (tag.toString().equals(MORE)) {

      } else {
        buyList.clear();
      }
      for (int i = 0; i < list.size(); i++) {
        buyList.add(list.get(i));
      }
      if (list.size() < pageSize) {
        buyOrderListView.setPullLoadEnable(false);
      } else {
        buyOrderListView.setPullLoadEnable(true);
      }
      buyOrderListAdapter.notifyDataSetChanged();
      onLoadSell();
    } else if (response instanceof FailResponse) {
      onLoadBuy();
      onLoadSell();
    } else if (response instanceof CarArriveResponse) {
      CarArriveResponse r = (CarArriveResponse) response;
      if (r.isResult()) {
        sellList.get(index).setExecuteState(0);
        Log.i("json", "ssssssss");
      }
      sellOrderListAdapter.notifyDataSetChanged();
    } else if (response instanceof CarDepartureResponse) {
      CarDepartureResponse r = (CarDepartureResponse) response;
      if (r.isResult()) {
        sellList.get(index).setExecuteState(2);
      }
      sellOrderListAdapter.notifyDataSetChanged();
    } else if (response instanceof CarDepartureAllowResponse) {
      CarDepartureAllowResponse r = (CarDepartureAllowResponse) response;
      if (r.isResult()) {
        buyList.get(index).setExecuteState(2);
      }
      buyOrderListAdapter.notifyDataSetChanged();
    } else if (response instanceof TransportArriveResponse) {
      TransportArriveResponse r = (TransportArriveResponse) response;
      if (r.isResult()) {
        sellList.get(index).setExecuteState(4);
      }
      sellOrderListAdapter.notifyDataSetChanged();
    } else if (response instanceof SettlementResponse) {
      SettlementResponse r = (SettlementResponse) response;
      if (r.isResult()) {
        sellList.get(index).setExecuteState(6);
        sellOrderListAdapter.notifyDataSetChanged();
      }
    }
  }