calculate total cost and deposit as well as clear new input on save