Created
February 20, 2023 20:50
-
-
Save hivepress/1c5c0931ccd9b646f5b28d89d9b7181e to your computer and use it in GitHub Desktop.
Restrict decimals in the payout request amount #hivepress #marketplace
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( | |
'hivepress/v1/forms/payout_request', | |
function( $form ) { | |
$form['fields']['amount']['type'] = 'number'; | |
$form['fields']['amount']['decimals'] = 0; | |
$form['fields']['amount']['min_value'] = 0; | |
return $form; | |
}, | |
1000 | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment