您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

StaffDetail.php 450B

123456789101112131415161718192021
  1. <?php
  2. namespace App\Model;
  3. use Jenssegers\Mongodb\Eloquent\SoftDeletes;
  4. use Jenssegers\Mongodb\Eloquent\Model as Eloquent;
  5. class StaffDetail extends Eloquent {
  6. //
  7. use SoftDeletes;
  8. protected $connection = 'mongodb';
  9. protected $collection = 'staff_detail';
  10. // protected $guarded = ['_id'];
  11. protected $fillable = ['_id'];
  12. public function staff() {
  13. return $this->belongsTo('App\Staff','_id','_id')->withTrashed();
  14. }
  15. }