OK, I did some more testing and it still works for me, so there must be something slightly awry with your set up.
As I already had my comedians test site available I persevered with that, if you'll bare with me.
So, my CPTs are Comedians, which have child CPTs of Shows and Gigs. Gigs is the intermediary post type to connect Comedians to a CPT of Venues in a many-to-many relationship.
(From my earlier test I just added Shows as a child post of Comedians to match your structure.)
I created some actual content: several comedians, venues, gigs, and I added shows for Ricky Gervais and Jerry Seinfeld only.
I created custom shortcodes as per your code, though I made one each for gigs and shows.
function child_posts_gig_func() {
$child_posts = types_child_posts("gig");
if ($child_posts) {
return 1;
} else {
return 0;
}
}
add_shortcode( 'has-child-posts-gig', 'child_posts_gig_func' );
function child_posts_show_func() {
$child_posts = types_child_posts("show");
if ($child_posts) {
return 1;
} else {
return 0;
}
}
add_shortcode( 'has-child-posts-show', 'child_posts_show_func' );
Now, I created a View to show comedian posts with no filters, so it is going to loop through each of my comedians.
My loop output section looks like this:
<wpv-loop>
<h2>[wpv-post-title]</h2>
<h3>gig check: [has-child-posts-gig]</h3>
[wpv-conditional if="( '[has-child-posts-gig]' = '0' )" evaluate="false"]
<h4>has gigs</h4>
[/wpv-conditional]
<h3>show check: [has-child-posts-show]</h3>
[wpv-conditional if="( '[has-child-posts-show]' = '0' )" evaluate="false"]
<h4>has shows</h4>
[/wpv-conditional]
</wpv-loop>
Add added this view to a page, and here are my results:
Chris Rock
gig check: 1
HAS GIGS
show check: 0
Ricky Gervais
gig check: 1
HAS GIGS
show check: 1
HAS SHOWS
Jerry Seinfeld
gig check: 1
HAS GIGS
show check: 1
HAS SHOWS
Louis CK
gig check: 1
HAS GIGS
show check: 0
That's exactly what I was expecting.
Can you spot the difference, and double-check for typos etc?
If you still can't identify the problem let me know.