Links
Comment on page

Customizing models

You can customize any of the existing models using hooks. For example, the code below changes the maximum allowed listing title length and makes the description optional:
add_filter(
'hivepress/v1/models/listing',
function( $model ) {
$model['fields']['title']['max_length'] = 123;
$model['fields']['description']['required'] = false;
return $model;
}
);
Similarly, you can customize any model in HivePress or its extensions.