buy functionality to modal forms