123456789101112131415161718192021222324252627282930313233 |
- <?php
- namespace App\Models;
- use Illuminate\Database\Eloquent\Model;
- class InteractionInfo extends Model
- {
- protected $table = 'interaction_info';
- protected $fillable = [
- 'dream_id',
- 'title',
- 'pic1',
- 'pic2',
- 'pic3',
- 'pic4',
- 'pic5',
- 'pic6',
- 'pic7',
- 'pic8',
- 'pic9',
- 'video',
- ];
- public function comments()
- {
- return $this->hasMany('App\Models\CommentInfoModel','interaction_id','id');
- }
- public function dream()
- {
- return $this->belongsTo('App\Models\DreamInfoModel','dream_id','id');
- }
- }
|