mirror of
https://gitee.com/ulthon/ulthon_admin.git
synced 2026-07-08 02:52:49 +08:00
开始官网模板
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
<?php
|
||||
declare (strict_types = 1);
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace app\model;
|
||||
|
||||
@@ -10,5 +11,14 @@ use think\Model;
|
||||
*/
|
||||
class PostCategory extends Model
|
||||
{
|
||||
//
|
||||
//
|
||||
public function post()
|
||||
{
|
||||
return $this->belongsTo(Post::class, 'post_id');
|
||||
}
|
||||
|
||||
public function category()
|
||||
{
|
||||
return $this->belongsTo(Category::class,'category_id');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user