예제 #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();
  }
예제 #2
0
 @Override
 public void onResume() {
   productList = sCT.getProductList();
   adapter = new MyAdapter();
   list_item.setAdapter(adapter);
   super.onResume();
 }