use of com.example.asus.onlinecanteen.adapter.TransactionHistoryAdapter in project OnlineCanteen by josephgunawan97.
the class TransactionCurrentOrderFragment method onViewCreated.
@Override
public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
getActivity().setTitle("On-Progress");
ArrayList<Transaction> transactions = new ArrayList<>();
adapter = new TransactionHistoryAdapter(this);
adapter.setTransactionHistory(transactions);
recyclerView = view.findViewById(R.id.current_recycler_view);
layoutManager = new LinearLayoutManager(getContext());
recyclerView.addItemDecoration(new DividerItemDecoration(getContext(), DividerItemDecoration.VERTICAL));
recyclerView.setLayoutManager(layoutManager);
recyclerView.setAdapter(adapter);
}
use of com.example.asus.onlinecanteen.adapter.TransactionHistoryAdapter in project OnlineCanteen by josephgunawan97.
the class TransactionHistoryFragment method onViewCreated.
@Override
public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
getActivity().setTitle(R.string.history_title_item);
ArrayList<Transaction> transactions = new ArrayList<>();
adapter = new TransactionHistoryAdapter(this);
adapter.setTransactionHistory(transactions);
recyclerView = view.findViewById(R.id.history_recycler_view);
layoutManager = new LinearLayoutManager(getContext());
recyclerView.addItemDecoration(new DividerItemDecoration(getContext(), DividerItemDecoration.VERTICAL));
recyclerView.setLayoutManager(layoutManager);
recyclerView.setAdapter(adapter);
}
Aggregations