登录注册功能
This commit is contained in:
26
app/Models/FrameworkModel.php
Normal file
26
app/Models/FrameworkModel.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use App\BaseApp\BaseModel;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
|
||||
|
||||
/**
|
||||
* 框架表
|
||||
*/
|
||||
class FrameworkModel extends BaseModel
|
||||
{
|
||||
//
|
||||
protected $table = 'frameworks';
|
||||
|
||||
protected $guarded = [];
|
||||
|
||||
/**
|
||||
* 项目关联
|
||||
* @return BelongsToMany
|
||||
*/
|
||||
public function projects()
|
||||
{
|
||||
return $this->belongsToMany(ProjectModel::class, 'project_frameworks_relations', 'framework_id', 'project_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user