Created
May 2, 2017 06:23
-
-
Save Mombuyish/2aaa45e4a25e114313bd6b38ce0d9fc9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Presenters; | |
class PostPresenter | |
{ | |
public function status($value) | |
{ | |
switch ($value) { | |
case 1: | |
return 'published'; | |
case 2: | |
return 'top'; | |
default: | |
return 'hidden'; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment