Delete::many with TableRef

This commit is contained in:
Billy Chan 2021-12-08 15:56:37 +08:00
parent 871a5e8de6
commit 1aea3f6c6c
No known key found for this signature in database
GPG Key ID: A2D690CAC7DF3CC7

View File

@ -3,7 +3,7 @@ use crate::{
QueryFilter, QueryTrait, QueryFilter, QueryTrait,
}; };
use core::marker::PhantomData; use core::marker::PhantomData;
use sea_query::{DeleteStatement, IntoIden}; use sea_query::DeleteStatement;
/// Defines the structure for a delete operation /// Defines the structure for a delete operation
#[derive(Clone, Debug)] #[derive(Clone, Debug)]
@ -94,7 +94,7 @@ impl Delete {
{ {
DeleteMany { DeleteMany {
query: DeleteStatement::new() query: DeleteStatement::new()
.from_table(entity.into_iden()) .from_table(entity.table_ref())
.to_owned(), .to_owned(),
entity: PhantomData, entity: PhantomData,
} }