-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsingle-organisations.php
58 lines (52 loc) · 2.68 KB
/
single-organisations.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?php
/**
* Created by PhpStorm.
* User: joris
* Date: 2017-04-21
* Time: 10:51 AM
*/
?>
TEST
<div class="profile-organisation-intro">
<?php the_content(); ?>
</div>
<section class="profile-members-badges">
<div class="profile-members-badges-heading"><span class="separator-prefix"></span>
<h3 class="profile-organisation-badges-heading-title">
Badges disponibles
<small class="profile-members-badges-available">
<?php echo $GLOBALS['badgefactor']->get_nb_badges_by_organisation($post->ID); ?> <?php _e('available', 'badgefactor'); ?>
</small>
</h3>
<ul class="profile-organisation-badges-cta">
<li class="profile-members-badges-cta-item">
<button type="button" class="profile-members-badges-cta-item-btn" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
<?php the_title(); ?>
<i class="profile-members-badges-cta-item-btn-caret"></i>
</button>
<ul class="profile-members-badges-cta-item-dropdown">
<li><a href="<?php echo get_permalink(1504);?>">Tous</a></li>
<?php foreach ($GLOBALS['badgefactor']->get_badge_organisations(true) as $organisation): ?>
<li><a href="<?php the_permalink($organisation->ID); ?>"><?php echo $organisation->post_title; ?></a></li>
<?php endforeach; ?>
</ul>
</li>
</ul>
</div>
<ul class="profile-members-badges-list">
<?php foreach ($GLOBALS['badgefactor']->get_products_by_organisation($post->ID) as $product): ?>
<li class="profile-members-badge">
<figure class="profile-members-badge-figure" style="min-height: 230px;">
<a href="<?php the_permalink($product->ID); ?>" class="profile-members-badge-link">
<img src="<?php echo wp_get_attachment_image_src( get_post_thumbnail_id($product->ID), 'single-post-thumbnail')[0]; ?>" srcset="<?php echo wp_get_attachment_image_src( get_post_thumbnail_id($product->ID), 'single-post-thumbnail')[0]; ?> 1x, <?php echo wp_get_attachment_image_src( get_post_thumbnail_id($product->ID), 'single-post-thumbnail')[0]; ?> 2x" class="profile-members-badge-image">
</a>
<figcaption class="profile-members-badge-details">
<span class="profile-members-badge-description">
Lorem ipsum dolor sit amet, consectetur adipisici
</span>
</figcaption>
</figure>
</li>
<?php endforeach; ?>
</ul>
</section>