* The Integration Status Badge */
(
$integration_status
)
| 91 | * The Integration Status Badge |
| 92 | */ |
| 93 | function the_integration_status_badge( |
| 94 | $integration_status |
| 95 | ){ |
| 96 | |
| 97 | // Set badge doesn't include 'planned' |
| 98 | // 'cuz the button says that. |
| 99 | if($integration_status == 'Disabled'){ |
| 100 | $badge_class = 'bg-secondary'; |
| 101 | $badge_text = 'Disabled'; |
| 102 | echo ' |
| 103 | <span class="badge '.$badge_class.'">' |
| 104 | .$badge_text.'<span class="visually-hidden"> |
| 105 | Integration Status</span></span>'; |
| 106 | }elseif($integration_status == 'Active'){ |
| 107 | $badge_class = 'bg-success'; |
| 108 | $badge_text = 'Active'; |
| 109 | echo '<span class="badge '.$badge_class.'">' |
| 110 | .$badge_text.'<span class="visually-hidden"> |
| 111 | Integration Status</span></span>'; |
| 112 | }else{ |
| 113 | return false; |
| 114 | } |
| 115 | |
| 116 | } |
| 117 | |
| 118 | /** |
| 119 | * The Integration Activation Button |