Seems like easy solution is make it a loan. If they make it work, they can keep the money for free, if not, they pay back with interest.
Payment upon delivery is how most business-to-business purchases work. You agree a cost, deliver the item, then get paid. Being paid before delivery gives no incentive to deliver what was requested.