Information.php 479 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace App\Repositories\Models\Info;
  3. use App\Repositories\Models\Model;
  4. class Information extends Model
  5. {
  6. /**
  7. * @var string
  8. */
  9. protected $table = 'info_Information';
  10. protected $guarded = [];
  11. /**
  12. * The attributes excluded from the model's JSON form.
  13. *
  14. * @var array
  15. */
  16. protected $hidden = [];
  17. public function type()
  18. {
  19. return $this->belongsTo(InformationType::class)->select(['id', 'name']);
  20. }
  21. }