コード例 #1
0
 public void productPopulate(int pos) {
   modelProductsDataList =
       dalProductDetail.getProductsByFlavId(db, flavourDataList.get(pos).get_categoryID());
   productName = new String[modelProductsDataList.size()];
   for (int j = 0; j < modelProductsDataList.size(); j++) {
     productName[j] = modelProductsDataList.get(j).get_productName();
   }
   setListAdapter(new MyListAdapter(ACTListProdByBranch.this));
 }
コード例 #2
0
  public void flavourPopulate() {

    flavourDataList = dalProductDetail.getflavour(db, storeBranchIdsecond);
    flavourName = new String[flavourDataList.size()];
    for (int i = 0; i < flavourDataList.size(); i++) {
      flavourName[i] = flavourDataList.get(i).get_categoryName();
    }
    flavour = (Spinner) findViewById(R.id.spinner1);
    flavour.setAdapter(
        new ArrayAdapter(
            getBaseContext(), android.R.layout.simple_dropdown_item_1line, flavourName));
  }