Ejemplo n.º 1
0
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.sale_tab);

    myDb = new InventoryDatabase(this);
    myDb.getWritableDatabase();
    SaleRecordDateDatabase DbSr = new SaleRecordDateDatabase(this);
    DbSr.getWritableDatabase();
    sCT = new StoreController(myDb, DbSr);
    productList = sCT.getProductList();
    basket = sCT.newBasket();

    initWidget();

    editText.setHint("search");
    cash.setHint("input cash");

    // adapter of list item.
    saleAdapter = new SaleItemAdapter();

    list_sale_item.setAdapter(saleAdapter);

    addButton();

    addFindByPartial();
  }
Ejemplo n.º 2
0
 @Override
 public void onResume() {
   productList = sCT.getProductList();
   adapter = new MyAdapter();
   list_item.setAdapter(adapter);
   super.onResume();
 }