dingd
This commit is contained in:
@@ -6,5 +6,5 @@ use think\Model;
|
||||
|
||||
class Order extends Model
|
||||
{
|
||||
|
||||
protected $autoWriteTimestamp = true;
|
||||
}
|
||||
15
app/model/Student.php
Normal file
15
app/model/Student.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
namespace app\model;
|
||||
|
||||
use think\Model;
|
||||
use think\model\relation\HasMany;
|
||||
|
||||
class Student extends Model
|
||||
{
|
||||
|
||||
public function orders(): HasMany
|
||||
{
|
||||
return $this->hasMany(Order::class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user