Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Options extends Model {
- public static function getOption($option, $field = ""){
- if(!empty($field)){
- $getOption = Option::where('option', $option)->get()->pluck($field)->toArray();
- }else{
- $getOption = Option::where('option', $option)->get()->toArray();
- }
- return $getOption;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement