Using the shortcode i get a warning (but no output):
Warning: foreach() argument must be of type array|object, null given inC:\Users\Dee Ego\Local Sites\bricksbuilder\app\public\wp-content\themes\bricks-c\functions.phpon line172
I tries also with a code block (it’s an element like the Shortcode on bricks editor)
<?php echo do_shortcode( '[display_book_chapters id="'.$post_id.'"]' ); ?>
and in this case i get 2 warnings:
Warning: Undefined variable $post_id inC:\Users\Dee Ego\Local Sites\bricksbuilder\app\public\wp-content\themes\bricks\includes\elements\code.php(160) : eval()’d codeon line2
Warning: foreach() argument must be of type array|object, null given inC:\Users\Dee Ego\Local Sites\bricksbuilder\app\public\wp-content\themes\bricks-c\functions.phpon line172
In any case, these solutions would not be ideal, as they do not take advantage of bricks’ internal query system, that is, in making the Repeater appear as a post type in the indicated dropdown.