mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-03 16:24:28 +08:00
25 lines
329 B
PHP
25 lines
329 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace app\model;
|
|
|
|
use think\Model;
|
|
|
|
/**
|
|
* @mixin 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');
|
|
}
|
|
}
|