updated charges controller
added purchase model and created database table for it
fixed the redirecting problem, everything should be good to go