123456789101112131415161718 |
- <?php
- namespace app\admin\model;
- use think\Model;
- use think\model\concern\SoftDelete;
- class Borrow extends Model
- {
- use SoftDelete;
- protected $deleteTime = 'delete_time';
- public function Admin()
- {
- // 指定关联Admin模型的数据库连接
- return $this->hasOne(Admin::class, 'id','user_id');
- }
- }
|