No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Pelaporan.php 581B

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. namespace App\Models;
  3. use Illuminate\Database\Eloquent\Factories\HasFactory;
  4. use Illuminate\Database\Eloquent\Model;
  5. class Pelaporan extends Model
  6. {
  7. use HasFactory;
  8. protected $fillable = [
  9. 'judul',
  10. 'keterangan',
  11. 'tanggal',
  12. 'lokasi',
  13. 'status',
  14. 'saran',
  15. 'foto',
  16. 'user_id',
  17. 'tindakan_id',
  18. ];
  19. public function tindakan(){
  20. return $this->belongsTo(Tindakan::class,'tindakan_id');
  21. }
  22. public function user(){
  23. return $this->belongsTo(User::class,'user_id');
  24. }
  25. }