-
-
Save hivepress/c25a48d50dfeac2ba01512e680aebcf3 to your computer and use it in GitHub Desktop.
| <?php | |
| add_filter( | |
| 'hivepress/v1/models/request/attributes', | |
| function( $attributes ) { | |
| if ( isset( $attributes['budget'] ) ) { | |
| $attributes['budget']['edit_field']['required'] = false; | |
| } | |
| return $attributes; | |
| }, | |
| 1000 | |
| ); |
Sorry for the late reply, for some reason I didn't receive the comment notification, the snippet is fixed now.
Hi
I can't understand, it turns out that I can't change the offer form if I only have the Request plugin installed?
This snippet is for the Budget field of the request (not offer), the Budget field is available only if you have Marketplace because the budget defines the base price paid by customer when they accept an offer (by paying for it). If you don't have Marketplace you can still add a custom Budget attribute just for the price indication purposes.
This throws an error (something went wrong) when the vendor makes an offer and it's accepted by the client, even though the vendor has set a price.
Please describe the steps to reproduce this issue, we tested the snippet with a test request and accepted the offer (creating an order via checkout), no errors were logged
https://community.hivepress.io/t/commission-rate-set-to-0-throws-an-error/14688/6
(throws an error when a request with not set price, a vendor does an offer, and the customer accepts it).
This doesnt work. Could you fix it?