node--materiau.tpl.php 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <?php //dsm($content); ?>
  2. <article class="<?php print $classes; ?>">
  3. <?php
  4. hide($content['comments']);
  5. hide($content['links']);
  6. hide($content['print_links']);
  7. hide($content['flaglistslinks']);
  8. hide($content['personalnotelink']);
  9. print render($content);
  10. ?>
  11. <?php
  12. global $user;
  13. // dsm($user);
  14. $vm = array('cardmedium', 'cardbig'); //, upgrade with 'cardfull' needs more design works, postponed
  15. // if( isset($user->roles[1]) && in_array($view_mode, $vm)):
  16. if( !isset($user->roles[10]) // student
  17. && !isset($user->roles[11]) // alphatesteur
  18. && !isset($user->roles[6]) // adherent
  19. && !isset($user->roles[8]) // premium
  20. && !isset($user->roles[12]) // translator
  21. && !isset($user->roles[13]) // admin showroom
  22. && !isset($user->roles[3]) // admin
  23. && !isset($user->roles[4]) // root
  24. && in_array($view_mode, $vm)):
  25. ?>
  26. <div class="side oops">
  27. <p>
  28. <?php print t("<strong>Oops!</strong></br> In order to access information matériO collected about thousands of manufacturers of emerging materials, you need to be part of materiO... ") . l(t('Join us!'), 'node/11187'); ?>
  29. </p>
  30. </div>
  31. <?php endif; ?>
  32. <?php
  33. /* if( (isset($user->roles[7]) || isset($user->roles[9])) && in_array($view_mode, $vm) ):
  34. ?>
  35. <div class="upgrade">
  36. <p>
  37. <?php print t("In order to access information about manufacturers and more, you need to upgrade your account.") . l(t('Pricing'), 'node/11187'); ?>
  38. </p>
  39. </div>
  40. <?php endif; */ ?>
  41. <?php if($workflow == 5): ?>
  42. <div class="workflow"> <i class="icon-warning-sign"></i><span><?php print t("in progress"); ?></span></div>
  43. <?php endif; ?>
  44. <nav class="nav">
  45. <?php if ($links = render($content['links'])): ?>
  46. <section class="links">
  47. <i class="fi-download"></i>
  48. <?php print $links; ?>
  49. </section>
  50. <?php endif; ?>
  51. <?php if ($flags = render($content['flaglistslinks'])): ?>
  52. <section class="flags">
  53. <i class="fi-folder"></i>
  54. <?php print $flags; ?>
  55. </section>
  56. <?php endif; ?>
  57. <?php if ($notelink = render($content['personalnotelink'])): ?>
  58. <?php //dsm($content['personalnotelink']); ?>
  59. <section class="note">
  60. <?php print $notelink; ?>
  61. </section>
  62. <?php endif; ?>
  63. <?php if (FALSE && $print_links = render($content['print_links'])): ?>
  64. <section class="print-links">
  65. <i class="icon-file"></i>
  66. <?php print $print_links; ?>
  67. </section>
  68. <?php endif; ?>
  69. </nav>
  70. </article>