FEATURE Handling synchronisation with carhop member

This commit is contained in:
Antoine M 2025-11-20 11:38:57 +01:00
parent 7727f3bb7e
commit 99d17aca85

View File

@ -53,6 +53,17 @@ $authors = get_posts(array(
$author_description = get_field('description', $author->ID);
$author_email = get_field('email', $author->ID);
$is_carhop_member = get_field('is_carhop_member', $author->ID);
$carhop_member_id = get_field('carhop_member', $author->ID);
if ($is_carhop_member && isset($carhop_member_id)) {
switch_to_blog(1);
$author_description = get_field('description', $carhop_member_id);
$author_email = get_field('email', $carhop_member_id);
$comity = get_field('comity', $carhop_member_id);
restore_current_blog();
}
$is_director = $author->ID === 476 ? true : false;
?>
@ -64,7 +75,7 @@ $authors = get_posts(array(
</a>
<?php else : ?>
<a href="<?php echo get_the_permalink($author->ID); ?>">
<div class="author-card__profile-picture-placeholder lol author-card__profile-picture-placeholder--<?php echo $placeholder_thumbnail_counter % 3 + 1; ?>n">
<div class="author-card__profile-picture-placeholder author-card__profile-picture-placeholder--<?php echo $placeholder_thumbnail_counter % 3 + 1; ?>n">
<!-- <img class="" src="<?php echo get_template_directory_uri(); ?>/assets/images/placeholder-author.png" alt="Placeholder author"> -->
</div>
</a>