restructured some static functions
added sale controller and cashier functionalities