ShowInAdmin.php in GiveWP – Donation Plugin and Fundraising Platform 4.16.8.1, at src/Framework/FieldsAPI/Concerns/ShowInAdmin.php
| 1 | <?php |
| 2 | |
| 3 | namespace Give\Framework\FieldsAPI\Concerns; |
| 4 | |
| 5 | /** |
| 6 | * @since 2.27.3 |
| 7 | */ |
| 8 | trait ShowInAdmin |
| 9 | { |
| 10 | |
| 11 | /** |
| 12 | * @since 2.27.3 |
| 13 | */ |
| 14 | protected $showInAdmin = false; |
| 15 | |
| 16 | /** |
| 17 | * @since 2.27.3 |
| 18 | */ |
| 19 | public function showInAdmin($showInAdmin = true): self |
| 20 | { |
| 21 | $this->showInAdmin = $showInAdmin; |
| 22 | |
| 23 | return $this; |
| 24 | } |
| 25 | |
| 26 | /** |
| 27 | * @since 2.27.3 |
| 28 | */ |
| 29 | public function shouldShowInAdmin(): bool |
| 30 | { |
| 31 | return $this->showInAdmin; |
| 32 | } |
| 33 | } |
| 34 |