Updated the 'QuerySelect' trait to expose 'lock_with_behavior' (#1867)
This commit is contained in:
parent
3b0896b527
commit
7eb3e12294
@ -3,8 +3,8 @@ use crate::{
|
|||||||
PrimaryKeyToColumn, RelationDef,
|
PrimaryKeyToColumn, RelationDef,
|
||||||
};
|
};
|
||||||
use sea_query::{
|
use sea_query::{
|
||||||
Alias, ConditionType, Expr, Iden, IntoCondition, IntoIden, LockType, SeaRc, SelectExpr,
|
Alias, ConditionType, Expr, Iden, IntoCondition, IntoIden, LockBehavior, LockType, SeaRc,
|
||||||
SelectStatement, SimpleExpr, TableRef,
|
SelectExpr, SelectStatement, SimpleExpr, TableRef,
|
||||||
};
|
};
|
||||||
pub use sea_query::{Condition, ConditionalStatement, DynIden, JoinType, Order, OrderedStatement};
|
pub use sea_query::{Condition, ConditionalStatement, DynIden, JoinType, Order, OrderedStatement};
|
||||||
|
|
||||||
@ -447,6 +447,14 @@ pub trait QuerySelect: Sized {
|
|||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Row locking with behavior (if supported).
|
||||||
|
///
|
||||||
|
/// See [`SelectStatement::lock_with_behavior`].
|
||||||
|
fn lock_with_behavior(mut self, r#type: LockType, behavior: LockBehavior) -> Self {
|
||||||
|
self.query().lock_with_behavior(r#type, behavior);
|
||||||
|
self
|
||||||
|
}
|
||||||
|
|
||||||
/// Add an expression to the select expression list.
|
/// Add an expression to the select expression list.
|
||||||
/// ```
|
/// ```
|
||||||
/// use sea_orm::sea_query::Expr;
|
/// use sea_orm::sea_query::Expr;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user