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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text.Json; | |
using System.Text.Json.Nodes; | |
namespace CajunCoding | |
{ | |
public static class SystemTextJsonMergeExtensions | |
{ |
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/listing_search', | |
function( $form ) { | |
if ( isset( $form['fields']['location'] ) ) { | |
$form['fields']['location']['required'] = true; | |
} | |
return $form; | |
}, |
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; | |
}, |
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
class WFACP_ReCaptcha_For_WC { | |
private $instance = null; | |
public function __construct() { | |
add_action( 'wfacp_template_load', [ $this, 'actions' ] ); | |
} | |
public function is_enable() { | |
return class_exists( 'I13_Woo_Recpatcha' ); | |
} |
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/order_deliver', | |
function( $form ) { | |
$form['fields']['note']['description'] = 'custom text here'; | |
return $form; | |
}, | |
1000 | |
); |
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/user_register', | |
function( $form ) { | |
$form['description'] = 'custom text here'; | |
return $form; | |
}, | |
1000 | |
); |
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/listing_submit/errors', | |
function( $errors, $form ) { | |
$listing = $form->get_model(); | |
if ( $listing && $listing->get_user__id() ) { | |
$listing_count = \HivePress\Models\Listing::query()->filter( | |
[ | |
'status__in' => [ 'publish', 'pending', 'draft' ], |
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/listing_update', | |
function( $form ) { | |
unset($form['fields']['images']); | |
return $form; | |
}, | |
1000 | |
); |
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']['details']['description'] = 'custom text here'; | |
return $form; | |
}, | |
1000 | |
); |
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/templates/vendor_view_page', | |
function( $template ) { | |
return hivepress()->helper->merge_trees( | |
$template, | |
[ | |
'blocks' => [ | |
'listings' => [ | |
'columns' => 3, |
NewerOlder