How to query posts by same meta values?

I just need one title or (Post ID) and then following I need the associated custom fields display. So basically I might have multiple posts with the same POST ID association, and the same custom field values but different post types.

See here what I’m trying to achieve:

Read More
    <ul>
    <?php
    global $post;
    $author_name = get_field('one');
    $args =  array( 'posts_per_page' => -1, 
            'post_type'=> 'design', 
            'post_id' => 1122,
            'author_name' => $author_name
                                );
    $myposts = get_posts( $args );
   foreach( $myposts as $post ) : setup_postdata($post); ?>

   <?php the_field('one'); ?>
   <?php the_field('designs'); ?>


   <?php endforeach; ?>
   </ul>

This currently displays like this :

Post 1122 
Hello 

Post 1122 
Hey there 

I want it to display like this:

Post 1122
Hello
Hey there

Post 1445
Hi Now 
Okay There

etc. etc.

Related posts