TLDR:当SoftDeletes特质包含在我的父模型中时,我不再将父模型的软删除实例作为子特性的动态特性。如何才能做到这一点? 我已经定义了几个基本款的,就像这样: <?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use
我有一个表后与模型简单的应用程序: <?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use SoftDeletes;
class Post extends Model
{
protected $table = 'post';
protected $dates = ['deleted_at'
我在我的应用程序中使用IsDeleted列实施软删除,并使用EF 6 Code First for ORM。我想用点运算符来访问懒加载导航性能(与许多关系)。例如,当自动过滤删除实体:一个用户有很多角色 public class User
{
private ICollection<Role> _roles;
public virtual ICollection<Role>