tachybase_todo/docs/zh-CN/api/database/shared/destroy-options.md
ChengLei Shao 4d6363b47a
Doc/db repository (#896)
* docs: update database repository docs

* docs: single relation repository docs

* docs: has many relation repository docs

* docs: belongs to many  relation repository docs

* docs: acl

* docs: actions

Co-authored-by: chenos <chenlinxh@gmail.com>
2022-10-16 19:16:14 +08:00

604 B
Raw Blame History

类型

interface DestroyOptions extends SequelizeDestroyOptions {
  filter?: Filter;
  filterByTk?: TargetKey | TargetKey[];
  truncate?: boolean;
  context?: any;
}

详细信息

  • filter指定要删除的记录的过滤条件。Filter 详细用法可参考 find() 方法。
  • filterByTk:按 TargetKey 指定要删除的记录的过滤条件。
  • truncate: 是否清空表数据,在没有传入 filterfilterByTk 参数时有效。
  • transaction: 事务对象。如果没有传入事务参数,该方法会自动创建一个内部事务。